Dot in PATH?
Bob McGowen x4312 dept208
bob at wyse.wyse.com
Sat Feb 2 11:16:25 AEST 1991
In article <1991Jan28.003846.25111 at bradley.bradley.edu> data at buhub (Mark Hall) writes:
>In <5528 at auspex.auspex.com> guy at auspex.auspex.com (Guy Harris) writes:
>
deleted discussion of exec()...
>in my .profile is this path command:
>
>> PATH=:/usr/lbin:/usr/local/bin:/bin:/usr/bin:$HOME:$HOME/BIN:$HOME/USR:/usr/tmp:/tmp:/tmp/talk:
>
>if I run a program in the current directory (and it's not in my path command)
>my shell looks in the current directory FIRST. This is also the way MS-DOS
deleted discussion...
PATH=:/usr/lbin...<rest of path deleted>
^^
This is a null path entry which defautlt to dot. You can have null
entries anywhere by either placing two colons together (::) or placing
a single colon at the beginning (as you did) or at the end.
A path with no null entries WILL NOT search the current directory:
PATH=/usr/bin:/bin:/usr/ucb
This path will search the three directories named and nothing else.
Bob McGowan (standard disclaimer, these are my own ...)
Product Support, Wyse Technology, San Jose, CA
..!uunet!wyse!bob
bob at wyse.com
More information about the Comp.unix.shell
mailing list