MCPcopy
hub / github.com/rclone/rclone / NewFsDstFile

Function NewFsDstFile

cmd/cmd.go:215–228  ·  view source on GitHub ↗

NewFsDstFile creates a new dst fs with a destination file name from the arguments

(args []string)

Source from the content-addressed store, hash-verified

213
214// NewFsDstFile creates a new dst fs with a destination file name from the arguments
215func NewFsDstFile(args []string) (fdst fs.Fs, dstFileName string) {
216 dstRemote, dstFileName, err := fspath.Split(args[0])
217 if err != nil {
218 fs.Fatalf(nil, "Parsing %q failed: %v", args[0], err)
219 }
220 if dstRemote == "" {
221 dstRemote = "."
222 }
223 if dstFileName == "" {
224 fs.Fatalf(nil, "%q is a directory", args[0])
225 }
226 fdst = newFsDir(dstRemote)
227 return
228}
229
230// ShowStats returns true if the user added a `--stats` flag to the command line.
231//

Callers 3

rcat.goFile · 0.92
create.goFile · 0.92
runFunction · 0.92

Calls 3

SplitFunction · 0.92
FatalfFunction · 0.92
newFsDirFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…