1
0
Fork 0
mirror of https://github.com/Luzifer/s3sync.git synced 2024-10-18 06:24:20 +00:00

Fix: Do not exit before every sync is done

This commit is contained in:
Knut Ahlers 2015-08-01 23:45:12 +02:00
parent 418257e9cd
commit 32116ec009

View file

@ -8,6 +8,7 @@ import (
"os" "os"
"path" "path"
"strings" "strings"
"time"
"github.com/Luzifer/s3sync/logger" "github.com/Luzifer/s3sync/logger"
"github.com/spf13/cobra" "github.com/spf13/cobra"
@ -150,6 +151,13 @@ func execSync(cmd *cobra.Command, args []string) {
}(remoteFile) }(remoteFile)
} }
} }
for {
if len(syncChannel) == 0 {
break
}
<-time.After(time.Second)
}
} }
func errExit(err error) { func errExit(err error) {