What is the command to find a file in Linux?

Tâm Tây

New member
What is the command to find a file in Linux?
Answer
Basic Examples

Command

Description

find . -name testfile.txt

Find a file called testfile.txt in current and sub-directories.

find /home -name *.jpg

Find all .jpg files in the /home and sub-directories.

find . -type f -empty

Find an empty file within the current directory.
1 more row
 

Tìm kiếm

Back
Top