Finding Yourself with pwdAs you begin using Unix and start moving around in directories and files, you're likely to get a bit lostthat is, forget which directory or subdirectory you're in. You can use the pwd command to get a reminder of where you are, as shown in Code Listing 1.5. Code Listing 1.5. pwd displays the name of the current directory, which is particularly handy if you've been exploring the system. By combining commands, you can request the directory's name and contents at one time.
You can request just the directory name, or you can get fancy and request the directory's name and its contents, courtesy of ls. To Find Out The Name of The Current Directory:
To Find Out The Name of The Current Directory and Its Contents:
Tips
|