Skip to content
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

Negated glob patterns ignored by clean #97

Open
djibarian opened this issue Oct 3, 2017 · 0 comments
Open

Negated glob patterns ignored by clean #97

djibarian opened this issue Oct 3, 2017 · 0 comments
Labels

Comments

@djibarian
Copy link

djibarian commented Oct 3, 2017

It seems that negated globs are ignored by clean. For example:

[ '/dev/**/{.,}*',
'!/dev/**/.DS_Store',
'!/dev/assets',
'!/dev/assets/**/{.,}*' ]

deletes any .DS_Store and assets from remote (and incidentally arises #79 when trying to delete assets contents).

nilsvu added a commit to nilsvu/vinyl-ftp that referenced this issue Jan 17, 2018
With the prepended slash, minimatch will never actually return an object with negate: true, so it's impossible to ignore files in clean operations. Please review this change and consider implications to the remaining codebase - perhaps even consider refactoring to use the glob processing implementation in vinyl-fs, that also gulp.src uses, if possible?
@morris morris added the bug label Jan 27, 2018
nilsvu added a commit to nilsvu/vinyl-ftp that referenced this issue Jan 28, 2018
With the prepended slash, minimatch will never actually return an object with negate: true, so it's impossible to ignore files in clean operations. Please review this change and consider implications to the remaining codebase - perhaps even consider refactoring to use the glob processing implementation in vinyl-fs, that also gulp.src uses, if possible?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants