Browse Source

better error message if directory is not found

pull/2/head
Chris Lu 12 years ago
parent
commit
ddf4f27a56
  1. 4
      go/weed/upload.go

4
go/weed/upload.go

@ -125,6 +125,7 @@ func runUpload(cmd *Command, args []string) bool {
return false
}
filepath.Walk(*uploadDir, func(path string, info os.FileInfo, err error) error {
if err == nil {
if !info.IsDir() {
results, e := submit([]string{path})
bytes, _ := json.Marshal(results)
@ -133,6 +134,9 @@ func runUpload(cmd *Command, args []string) bool {
return e
}
}
} else {
fmt.Println(err)
}
return err
})
} else {

Loading…
Cancel
Save