The Seven Year Itch.

MENU

Linux 删除某文件夹下包括某关键字的所有文件

March 28, 2017 • Read: 268 • Linux

find  /home/data -type f  | xargs -n1 -I "zz" grep -l "GoogleExchage" "zz" | xargs -n1 -I "xx" rm -f "xx"

其中"zz"和"xx"都是变量。

Tags: None
Archives QR Code
QR Code for this page
Tipping QR Code