I really can't understand why pattern test**/*.ext matches test23/file.ext, but doesn't match test23/test/file.ext and test23/test/test/file.ext.
Globstar should match all of this, shouldn't it?
Here's man bash:
When the globstar shell option is enabled, and * is used in a pathname expansion context, two adjacent *s used as a single pattern will match all files and zero or more directories and subdirectories. If followed by a /, two adjacent *s will match only directories and subdirectories.
Since your ** is not a single pattern but rather a part of test**, it does not get the globstar treatment.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With