Aharpo.335 net.general utzoo!decvax!duke!chico!harpo!jea Fri Feb 19 12:08:07 1982 csh prompt In reference to an item jgy sent some time back regarding a Berkley csh prompt that indicates levels of csh nesting; I have made some simple changes that I feel improve the beauty if not the usefulness of the command. Thanks also to mpt, my co-author. The result gives prompts of the following form: 1: command 2: csh <1> 1: csh <2> 1: csh <3> 1: csh <4> 1: ^D <3> 2: ^D <2> 2: li <2> 3: etc. (where the number in "<>"s is the nesting level). In .login enter the following lines: _______________________________________________________ # Makes initial prompt be the current command number set prompt = '\!: ' # Identifies first login setenv LOGGEDON yes # Counts the levels of CSH nesting setenv CSHno "0" In .cshrc add these lines: _______________________________________________________ # Give a prompt of the form: <#> %: where # is the nested depth # of the current shell and % is the current command number if ( `printenv LOGGEDON` == "yes" ) then setenv CSHno "`expr $CSHno + 1`" set prompt = "<$CSHno> \!: " endif