I'm on Linux, using Bash.
I need to remove all files without a certain suffix, for example "dist". I know there are some tricks to do it, rather than removing all the unwanted files one by one.
|
|
|
Use the following to list all the files that would be removed (just to be sure):
Add Run the command with additional |
||||
|
|
If you have extended globbing enabled, you can try:
Note: if you have directories without the .dist extension, this will will try and delete them too, but will fail. To turn on extended globbing use: |
|||
|
|