-
-
Notifications
You must be signed in to change notification settings - Fork 65
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
delete files from network share #35
Comments
@jzp74 Read documentation, please. New api uses promises instead of callback. |
@TrySound Thanks for your reply. You mean this documentation: https://github.com/gulpjs/gulp/blob/master/docs/API.md? |
@jzp74 This documentation |
@jzp74 Instead of passing callback as the last argument you can just return result of del function. gulp tasks accept streams and promises. |
@TrySound Thanks! So I tried this with a normal directory
Works perfectly. I then tried this (basically the same) with the shared location
Doesn't work and renders no errors or warning. This should work right? Then tried this to see if something is perhaps wrong wiith my shared location.
Works perfectly. It looks like del doesn't work with shared locations. Am I still doing something wrong? Is there something else you would like me to test? |
@jzp74 Do not use callback here. You call cb before del end. gulp.task('clean', function() {
return del(['dist/css/*.css'], { force: true });
}); |
@jzp74 I don't know about shared location. |
Removed the callback for both the local delete and the shared location delete. Same results: local delete works, shared location delete doesn't |
I am here too ..issues on shared drive requires the force option...here is my code gulp.task('clean',function(){
return gulp.src(DEST)
.pipe(vinylPaths(del(DEST, { force: true })));
}); I was using vinylPaths as I wanted to do this on a stream of ONLY changed files |
ATM, However there's a workaround:
Example:del('/dist/css/*.css', {
root: '//ComputerName/SharedFolder',
force: true,
}); Notes:
This should answer all questions. |
I was using grunt quite happely when I stumbled upon an issue in removing files from a network location with grunt-contrib-clean
So I just tried del in combination with gulp but ended having (at first glance) the same issue. I'm new to gulp so maybe i'm missing something. This is my extremely simple gulpfile.js
Running gulp gives me no errors but the files in //some/network/location are still there. Is this unsupported use, misuse or a bug?
I'm running gulp on a Windows 8 machine from within Git bash. Shared location is on my synology NAS.
The text was updated successfully, but these errors were encountered: