gpt4 book ai didi

linux - Unix - ls 命令将一些 "outputted"文本显示为文件

转载 作者:太空宇宙 更新时间:2023-11-04 09:03:16 24 4
gpt4 key购买 nike

bash-3.2$ ls -ls
total 48
4 -rw-r--r-- 1 hdoostie etrade 1545 Aug 8 2012 ~
4 drwxr-xr-- 11 hdoostie etrade 4096 Dec 28 2011 det-us
4 drwxr-xr-- 6 hdoostie etrade 4096 Sep 18 2012 etaf
12 -rw-r--r-- 1 hdoostie etrade 11867 Jul 31 2012 l:template name="expanded_search">
4 drwxr-xr-- 8 hdoostie etrade 4096 Apr 22 11:31 neo
4 drwxr-xr-- 5 hdoostie etrade 4096 Jan 29 14:36 neo-apps-skins
4 drwxr-xr-- 5 hdoostie etrade 4096 Feb 16 2012 neo-webapp-prospect
4 drwxr-xr-- 3 hdoostie etrade 4096 Feb 22 2012 site_04_uat_in_here
4 drwxr-xr-- 3 hdoostie etrade 4096 Jun 20 2012 svntest
4 drwxr-xr-- 3 hdoostie etrade 4096 Feb 23 2012 xborder_in_here

"l:template name="expanded_search">"是一些以某种方式显示为文件的文件内容。我如何“删除”这个"file"?

最佳答案

删除任何文件的方法,无论文件名包含什么字符,都是使用它的 inode 号。您可以使用:

ls -i

这将向您展示旁边带有 inode 编号的文件。然后您可以使用以下方法删除该文件:

find -ium [inode_number] -exec rm {} \;

但在这种情况下,只引用文件名也应该足够了:

rm 'l:template name="expanded_search">'

关于linux - Unix - ls 命令将一些 "outputted"文本显示为文件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16243360/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com