[英]Linux - finding hidden files that are executable by the owner using ls or find command
嗯,正如帖子標題所說,我需要(僅)查找由所有者使用ls
或find
命令可執行的隱藏文件。
我能夠得到這些。找到所有可執行文件的命令
find <dir> -executable -type f
而且,這是找到所有隱藏文件的方法
find . ".*" -ls
因此,我能夠找到隱藏文件和可執行文件,但無法僅過濾所有者可執行的隱藏文件。
您可以嘗試此find
,
find . -name '.*' -type f -perm /700
說明:
-perm /700
查找擁有者可執行的隱藏文件。
只需結合它們:
find . -name '.*' -executable -type f
找到-type f -executeable -name“。*”
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.