linux - I have directories named pack1 - pack255. What command could I use to remove pack1-55? -
something >rm pack*{1,2,3,4,??} , remove last 5 in list format? new this, still getting grips syntax!
try this:
$ echo rm -rf pack{1..55} rm -rf pack1 pack2 pack3 pack4...
if works, can remove echo
:
$ rm -rf pack{1..55}
if doesn't, may have set braceexpand:
$ set -o braceexpand
then try again.
don't forget, if you're removing directories, need -r
recurse parameter of rm
command.
Comments
Post a Comment