Skip to content

Added 'files mv' command to rename files#86

Merged
mschroering merged 5 commits intomasterfrom
file-mv
May 30, 2019
Merged

Added 'files mv' command to rename files#86
mschroering merged 5 commits intomasterfrom
file-mv

Conversation

@mschroering
Copy link
Copy Markdown
Contributor

No description provided.

Comment thread lib/cmds/files_cmds/mv.js Outdated
Comment thread lib/cmds/files_cmds/mv.js Outdated

const response = await list(argv, `/v1/files?${querystring.stringify(opts)}`);
for (const item of response.data.items) {
const newName = path.join(argv.dest, item.name.replace(prefix, ''));
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On windows path.join() is going to use \ rather than / which isn't what we want.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch. Fixed.

@mschroering mschroering merged commit b09bcdc into master May 30, 2019
@mschroering mschroering deleted the file-mv branch May 30, 2019 19:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants