From the course: Unix Essential Training
Unlock the full course today
Join today to access over 24,800 courses taught by industry experts.
Searching for files and directories - Unix Tutorial
From the course: Unix Essential Training
Searching for files and directories
- [Instructor] Let's talk about how you can search for files and directories that you created on Unix. The way that we search for files and directories is with the find command. The format is the find command, followed by the path that we want to search. So, we're going to search all files and directories inside that path. And then last the expression that we want to use for searching. And there's a variety of expressions we can use. We're going to just be using the most common and most basic one which is the name expression. So here I have the find command, I'm telling it to search in the root of the hard drive. That's what that forward slash is, in the directory home, and in there, look for things where the name is equal to vacation_photo.jpg. And it'll look throughout that directory to see if it can find a file that has that matching name. The double quotes are optional, but I think they're a good idea. This type…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
- (Locked)File system basics7m 24s
- (Locked)Creating files4m 4s
- (Locked)Reading files5m 7s
- Creating directories3m 10s
- (Locked)Moving and renaming files and directories5m 43s
- (Locked)Copying files and directories5m 10s
- (Locked)Deleting files and directories2m 53s
- (Locked)Creating symbolic links5m 21s
- (Locked)Searching for files and directories4m 11s
- (Locked)