File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -233,7 +233,7 @@ export async function globWithGitIgnore(
233233
234234 let hasNegatedPattern = false
235235 for ( const p of ignores ) {
236- if ( p . charCodeAt ( 0 ) === 33 ) {
236+ if ( p . charCodeAt ( 0 ) === 33 /*'!'*/ ) {
237237 hasNegatedPattern = true
238238 break
239239 }
@@ -252,8 +252,10 @@ export async function globWithGitIgnore(
252252 return await glob ( patterns as string [ ] , globOptions )
253253 }
254254
255- const ig = ignore ( ) . add ( [ ...ignores ] )
255+ // Add support for negated "ignore" patterns which many globbing libraries,
256+ // including 'fast-glob', 'globby', and 'tinyglobby', lack support for.
256257 const filtered : string [ ] = [ ]
258+ const ig = ignore ( ) . add ( [ ...ignores ] )
257259 const stream = globStream (
258260 patterns as string [ ] ,
259261 globOptions ,
You can’t perform that action at this time.
0 commit comments