mirror of
https://github.com/appleboy/drone-scp.git
synced 2026-06-04 18:23:59 +08:00
refactor: hide domain info if only single domain in drone setting. (#70)
This commit is contained in:
@@ -103,7 +103,11 @@ func globList(paths []string) []string {
|
||||
}
|
||||
|
||||
func (p Plugin) log(host string, message ...interface{}) {
|
||||
fmt.Printf("%s: %s", host, fmt.Sprintln(message...))
|
||||
if count := len(p.Config.Host); count == 1 {
|
||||
fmt.Printf("%s", fmt.Sprintln(message...))
|
||||
} else {
|
||||
fmt.Printf("%s: %s", host, fmt.Sprintln(message...))
|
||||
}
|
||||
}
|
||||
|
||||
func (p *Plugin) removeDestFile(ssh *easyssh.MakeConfig) error {
|
||||
@@ -294,7 +298,9 @@ func (p *Plugin) Exec() error {
|
||||
}
|
||||
}
|
||||
|
||||
fmt.Println("================================================")
|
||||
fmt.Println("Successfully executed transfer data to all host.")
|
||||
fmt.Println("================================================")
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user