-
-
Notifications
You must be signed in to change notification settings - Fork 66
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
del is an alias for a native Windows command #19
Comments
"scripts": {
"clean": "node_modules/.bin/del dist/*"
} |
@kevva That doesn't work. "node_modules/.bin/del" doesn't exist on a local del install. |
nvm, this doesn't have a CLI so no wonder it doesn't work for you. Use trash if you need CLI functionality. This module only works when required as seen in the usage instructions. |
@kevva I just created a new module. Ran: npm install del There is no |
As a matter of fact, it looks like even a global install of del (on Windows) doesn't attempt to alias del! Not sure why this issue was closed so quick. _global rimraf install:_
_global del install:_
|
Because it doesn't have a CLI.
Why would it? |
I don't really care that much about the lack of a global install (although rimraf does support one and this module appears to be a superset improvement of rimraf). What I originally wanted to do was just simply use this in a simple npm "clean" script task. I was previously using rm -rf in the task, but that's doesn't have cross platform support without something like cygwin or winbash or something. Not a huge deal, just inconvenient. |
Yeah, that's what trash is for. Your code would look like this instead: "scripts": {
"clean": "trash dist/*"
} |
trash is great, but the files I'm working with are inherently volatile (they are derived files from a build). I would never want to recover these, because they are all derived from a build; hence "putting them in the trash" is simply a waste of disk space in my scenario. |
Yeah, then |
I hesitate to even open this issue because I'm not even sure how you would go about addressing this, but it's a heads up, if anything. 'del' is an alias for the native Windows command for removing things. In essence, it kinda does what this module does, but natively. Unfortunately since the syntaxes differ, this node module throws errors when running on Windows....either when installed globally or, in my case, via an npm run script a la:
rimraf avoids these issues (because rimraf isn't an alias for anyting in Windows), but you've obviously made some improvements to rimraf functionality via the notes in your documentation.
The text was updated successfully, but these errors were encountered: