linux怎么删除奇怪的文件

图片描述

如图所示,这种文件如何删除.

阅读 3.8k
4 个回答

使用rm -fr -- 文件名

rm -fr -- --exclude=xxx
rm -f ./--exclude*

没毛病

我也是首次遇到这个问题. 而我的方法是man rm, 然后看到了下面这写内容:

To  remove  a file whose name starts with a '-', for example '-foo', use one of these com‐
       mands:

              rm -- -foo

              rm ./-foo

       Note that if you use rm to remove a file, it might be possible to recover some of its con‐
       tents,  given  sufficient  expertise and/or time.  For greater assurance that the contents
       are truly unrecoverable, consider using shred.

希望对您有用.

PS: 学习获取知识的方法比学知识要重要.

rm命令,参数,-r:递归,主要用于删除文件夹及文件,-f,强制删除;
P.S.删除之前可以三思啊,Linux可是没有回收站的...

撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
推荐问题