小编Ren*_*nto的帖子

需要删除前N行grep结果文件

我试图在我的一些wordpress安装上摆脱黑客问题.

这家伙在我服务器上的多个文件的头部放了9行代码......我正在尝试使用grep和sed来解决这个问题.

我尝试着:

grep -r -l  "//360cdn.win/c.css" | xargs -0 sed -e '1,9d' < {}
Run Code Online (Sandbox Code Playgroud)

但是没有任何事情发生,如果我删除-0 fromxargs , the result of the files found are clean, but they are not overwriting the origin file with thesed`结果,任何人都可以帮助我吗?

非常感谢!

linux wordpress bash grep sed

6
推荐指数
1
解决办法
121
查看次数

标签 统计

bash ×1

grep ×1

linux ×1

sed ×1

wordpress ×1