Help: Could you tell me why this plugin can not ignore the corresponding files
luckyjolly opened this issue · 2 comments
luckyjolly commented
new CopyWebpackPlugin({
patterns: [{
from: path.resolve(__dirname, '../static'),
to: 'static',
globOptions: {
ignore: ['.*']
}
}]
})
copy-webpack-plugin version: 9.0.1
At frist, I set the value of 'igore' option to ['.']. I just wanted to ignore the files start with dot. But failed. The result is shown in f ollowing image:
As the result, those files 'static/.gitkeep' and 'static/.html' was copyed to the directory 'dist/statc/'.
Then I changed the value of 'ingore' to ['.', '.gitkeep'], also failed.
Then I changed the value of 'ingore' to ['.', '**.gitkeep'], and I igored the file '.gitkeep' successfully.
At last, I also tried this values ['.'], ['.'], ['.'], ['.*'], all failed. And now, I can't understand the following rules.
alexander-akait commented
Ask this in globby
/fast-glob
package, we use it under the hood
zjjjjjjjjjjd commented
same problem in 9.0.1