AUTHOR

this is the kind of shit you have to type with

linux:
ls -l | grep srv | awk ' {print $9}' | sudo xargs rm
that cat looks sick
foxide quote:
that cat looks sick
i'm gonna be sick
Why use -l in this case? Without it you could remove the awk statement.
Louis2rich quote:
Why use -l in this case? Without it you could remove the awk statement.
true, wasn't thinking
Im all confuzzled right now... guess I just dont what youre doing exactly
sudo rm *srv*

Or

For i in 'ls *srv*'; do echo $i; sudo rm $i; done
i forgot that the output of ls was an array and i could get each item out of it, i'm deleting everything that has a specific string in it.
Well thats the great thing about *nix, multiple ways to skin the same cat!
Louis2rich quote:
sudo rm *srv*

Or

For i in 'ls *srv*'; do echo $i; sudo rm $i; done
For auditing purposes id change the echo $i to echo $i >> removed.txt

Quick reply

Sign in to post a message.
Smileys

Times shown in Eastern Time (ET).