meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />

Thursday, January 25, 2007

Unix Tip: Shells and search order

By Sandra Henry-Stocker

It's easy to take the Unix command line for granted. That is, it's easy to get used to typing in commands and getting responses without thinking very much about how the system determines what command to run. Some of the commands we type are binary files that are part of the OS, some are scripts, some are shell built-ins and some are aliases that are configured into our accounts. Still others may be shell routines. The order that Unix systems use in evaluating the commands we enter is not solely dependent on our PATH variables. Instead, the search order follows a predefined order. If you happen to have a script that has the same name as a Unix command, an alias and a shell routine or built-in, for example, how do you know which one you will end up executing when you press the return key?

Read the full article here.

0 Comments:

Post a Comment

<< Home