Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!osu-cis!dsacg1!ddtcg1!marst2!vwa0201 From: vwa0201@marst2.UUCP (Larry Baca) Newsgroups: comp.unix.questions Subject: Re: Getting UNIX prompt to display current directory (Answers) Summary: T-SHELL PROMPT Message-ID: <198@marst2.UUCP> Date: 24 Mar 89 16:51:23 GMT References: <2455@lindy.Stanford.EDU> <87@necbsd.NEC.COM> Organization: Defense Automatic Addressing Systems Office, Tracy, Ca. Lines: 18 In article <87@necbsd.NEC.COM>, gilbert@necbsd.NEC.COM (Russell Gilbert) writes: > From article <2455@lindy.Stanford.EDU>, by news@lindy.Stanford.EDU (News Service): > > ) In MS-DOS there is a very easy way to get the current directory displayed as > > ) part of the prompt (prompt $p). In UNIX, there is certainly no > > ) straightforward way to do this. Can anyone think of a tricky way? In T-SHELL, in my .cshrc, I use: set prompt="%S%M%s [%h] %" This gives me, on the first line, my current dir. On the next line, my machine name (we have 2), followed by the current command no. -- LARRY BACA, SYSTEM ADMINISTRATOR, [4m(MARST1 MARST2)[0m DAASO-VWA AIS, DEFENSE AUTOMATIC ADDRESSING OFFICE, WESTERN DIVISION DDTC TRACY, TRACY CA. 95376-5057 AUTOVON 462-9391, COMERCIAL 832-9391 EMAIL PATH - dsacg1!marst2!vwa0201