I want to ls files that doesn't have extension *.m2ts nor *.mp4.
Of course, I can get BOTH *.m2ts and *.mp4 files via ls *.(m2ts|mp4) . How can I negate this glob?
I want to ls files that doesn't have extension *.m2ts nor *.mp4.
Of course, I can get BOTH *.m2ts and *.mp4 files via ls *.(m2ts|mp4) . How can I negate this glob?
I found simple solution:
ls -d ^*.(mp4|m2ts)
This worked well. -d option seems to be mandatory.
-d, --directory
list directories themselves, not their contents