tw@foobar.UUCP (Tom Walsh) (12/14/87)
In article <7@ritcv.UUCP> ccs6277@ritcv.UUCP (PUT YOUR NAME HERE) writes: > ...in Korn Shell ...lots of work to get cwd in PS1 using korn shell > Cliff Skolnick > ...rochester!ritcv!ccs6277 > ...rochester!ritcv!ritcsh!sabin!lazlo!{root|ccs} $PWD is maintained by korn shell. use it. it is cheaper than `pwd`... by a long shot. i use --/etc/profile--(FOR ALL USERS) mach=`uuname -l` # could use uname -s or -n ... --~user/.kshrc--(SALT TO TASTE) PS1='! $mach $PWD ' ; export PS1 all done.... the "'" causes ksh to delay evaluation until printing the prompt. there are certain versions extant that seem to have problems with maintaining PWD accurately, and symlinks are probably neat too...
aeusesef@csun.UUCP (sean fagan) (12/17/87)
In article <3@dropte.foobar.UUCP> tw@dropte.UUCP (Tom Walsh) writes: >In article <7@ritcv.UUCP> ccs6277@ritcv.UUCP (PUT YOUR NAME HERE) writes: >> ...in Korn Shell >...lots of work to get cwd in PS1 using korn shell >> ...rochester!ritcv!ritcsh!sabin!lazlo!{root|ccs} >$PWD is maintained by korn shell. use it. it is cheaper than >`pwd`... by a long shot. No, it's not. `pwd` get evaluated as the shell's pwd, which just returns $PWD. The overhead is relatively small on Korn Shell (and versions of Bourne shell that have pwd built in). ----- Sean Eric Fagan Office of Computing/Communications Resources (213) 852 5742 Suite 2600 1GTLSEF@CALSTATE.BITNET 5670 Wilshire Boulevard Los Angeles, CA 90036 {litvax, rdlvax, psivax, hplabs, ihnp4}!csun!aeusesef