Delete multiple files through awk command in linux
ls -lrth|egrep -v "Jul 27"|awk {'print $9'}|xargs rm -rfv
ls -lrth -----list file
egrep ---for exclude
awk {'print $9'} ---print value
xargs rm -rfv --- remove file
ls -lrth|egrep -v "Jul 27"|awk {'print $9'}|xargs rm -rfv
ls -lrth -----list file
egrep ---for exclude
awk {'print $9'} ---print value
xargs rm -rfv --- remove file
No comments:
Post a Comment