FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Report forgotten errors from 'mv' by vgalka-sl · Pull Request #879 · shelljs/shelljs · GitHub

Report forgotten errors from 'mv' - #879

Open
vgalka-sl wants to merge 2 commits into
shelljs:mainfrom
vgalka-sl:mv-errors
Open

Report forgotten errors from 'mv'#879
vgalka-sl wants to merge 2 commits into
shelljs:mainfrom
vgalka-sl:mv-errors

Conversation

Copy link
Copy Markdown

Fix for issue #878.

codecov-io commented Jul 23, 2018
edited
Loading

Copy link
Copy Markdown

Codecov Report

Merging #879 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #879   +/-   ##
=======================================
  Coverage   95.81%   95.81%           
=======================================
  Files          34       34           
  Lines        1266     1266           
=======================================
  Hits         1213     1213           
  Misses         53       53
Impacted Files Coverage Δ
src/mv.js 97.77% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4113a72...898deb6. Read the comment docs.

nfischer left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Could you please add a test in test/mv.js? Your example in #878 with foo/a/file.js sounds perfect.

Comment thread src/mv.js
cp('-r', src, thisDest);
rm('-rf', src);
} else {
common.error(e.message, { continue: true });

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Could you catch a specific e.code and output a message like mv: cannot move 'foo/a/file.js' to 'bar/a/file.js': No such file or directory?

Also, could you add an else branch with throw e? The distinction is that we only want to use common.error() for expected error conditions, and would prefer to fail loudly with an exception for unexpected conditions (so that we can fix these as they're reported).

nfischer added fix Bug/defect, or a fix for such a problem bash compat Compatibility issues with bash or POSIX behavior labels Jul 23, 2018
nfischer added this to the v0.8.x milestone Jul 23, 2018

nfischer commented Aug 1, 2018

Copy link
Copy Markdown
Member

@vgalka-sl any update on this issue? Let me know if I can clarify anything.

nfischer removed this from the v0.8.x milestone Apr 6, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bash compat Compatibility issues with bash or POSIX behavior fix Bug/defect, or a fix for such a problem

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL