server
This commit is contained in:
@@ -2,7 +2,6 @@ package sync
|
||||
|
||||
import (
|
||||
"cloudsave/pkg/remote"
|
||||
"cloudsave/pkg/sync/ssh"
|
||||
"context"
|
||||
"flag"
|
||||
"fmt"
|
||||
@@ -28,15 +27,15 @@ func (p *SyncCmd) SetFlags(f *flag.FlagSet) {
|
||||
}
|
||||
|
||||
func (p *SyncCmd) Execute(_ context.Context, f *flag.FlagSet, _ ...interface{}) subcommands.ExitStatus {
|
||||
remotes, err := remote.All()
|
||||
_, err := remote.All()
|
||||
if err != nil {
|
||||
fmt.Fprintln(os.Stderr, "error: failed to load datastore:", err)
|
||||
return subcommands.ExitFailure
|
||||
}
|
||||
|
||||
for _, remote := range remotes {
|
||||
ssh.SFTPSyncer{}.Sync(remote)
|
||||
}
|
||||
/*for _, remote := range remotes {
|
||||
|
||||
}*/
|
||||
|
||||
return subcommands.ExitSuccess
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user