Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
ボリューム内のすべてのファイルを検索する次の検索コマンドがあります。
find ./ -type f
で始まるすべてのファイルを除外するにはどうすればよい.ですか? また、次のようなフォルダーを含めたいと思います.。
.
.Trashes/file.php
folder/.hidden_file.php
これに対する正しいfindコマンドは何でしょうか?
find
名前が で始まるすべてのファイルを除外するには.:
find ./ -type f ! -name '.*'
これは、現在のディレクトリから下にあるすべてのディレクトリ (名前がドットで始まる場合でも) で、名前がドット ( ! -name '.*') で始まらない通常のファイルを検索します。
! -name '.*'