Open martinvl opened 8 years ago
When globbing for files (e.g. "foo.*") only the first file gets a correct fname. The other files get .. prepended to their fname, which causes them to be put in the wrong remote location.
fname
..
Fixes #27
Imaging this:
Using path.basename you will get baz.txt, but bar/baz.txt is expected.
path.basename
baz.txt
bar/baz.txt
That is true.
Check whether files[0] is a directory using fs.stat and use path.dirname if it isn't then?
files[0]
fs.stat
path.dirname
When globbing for files (e.g. "foo.*") only the first file gets a correct
fname
. The other files get..
prepended to theirfname
, which causes them to be put in the wrong remote location.Fixes #27