Suppose under the current directory, there are multiple sub-directories, and one is called A.
How to delete all sub-directories except A with Bash?
bashlinux
Suppose under the current directory, there are multiple sub-directories, and one is called A.
How to delete all sub-directories except A with Bash?
Best Answer
Bash has extended globbing (first test, then remove the echo):