![]() We can pick our way through the listing to see the file system locations that will be searched, and the order in which they will be searched: The shell searches from left to right through the path, checking each file system location for a matching executable to perform your command. The output is a list of colon ( :) delimited file system locations. Just type the following to use the echo command and print the value held in the $PATH variable: echo $PATH You might have more than one version of clear installed on your computer, but this is the one the shell will try to use. This tells us that clear is a binary file, and the first one found in the path is located at /usr/bin. If you want to see whether a command is a shell builtin, an alias, a function, or a standalone binary mv /work/unfile, you can use the type command as shown below: type clear type cd It holds a list of places the shell searches and the order in which they’ll be searched. Is it on your workbench or a wall hanger? That’s what the $PATH environment variable does. ![]() ![]() If you need one of your other tools, though, you have to go rummage in the workshop to find it.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |