GCG unix - up-arrow in history function????

Francis Ouellette francis at monod.Biol.McGill.CA
Tue Dec 15 14:04:03 EST 1992


broe at aardvark.ucs.uoknor.edu (Bruce Roe) writes:

>In article <1992Dec14.090042.4792 at pollux.lu.se>, Bo.Servenius at wblag.lu.se (Bo Servenius) writes...
>>Dear Netters:
>> 
>>I am just in the process of moving my GCG package from a VMS system
>>to a SunOS UNIX one. Being used to use the up-arrow in VMS I was 
>>frustrated when I realised that I have to use the csh with GCG under unix.
>>And csh in contrast to tcsh can not support up-arrow in the history
>>function. Anyone out there who has come up with a solution to this
>>problem???????

>Hi,
>	The command !-1 on SunOS v1.1.1 is equivalant to the up arrow
>on a VMS system.  I have absolutely no idea where this is documented.

from the "man csh" command of SunOS 4.1.2:


Event Designators
     An event designator is a reference to a  command-line  entry
     in the history list.
       !    Start a history substitution, except when followed
	       by a SPACE character, TAB, NEWLINE, = or (.
       !!   Refer to the previous command.  By  itself, this
            substitution repeats the previous command.
       !n   Refer to command-line n.
       !-n  Refer to the current command-line minus n.
       !str Refer to the most recent command starting with str.
       !?str[?]
	    Refer to the most recent command containing str.
       !{...}
            Insulate a history reference from adjacent charac-
	    ters (if necessary).
								      

>If you type the word history, then you will see a listing of previous
>commands issued and say you want to type command number 5 on the list,
>then type !-5.  
>Just another one of those intuitive SunOS or Unix features ;-)

absolutely ...  Isn't Unix _great_!!!

As far as puting tcsh as a shell, if you are not root on your machine,
just ask your system administrator to do it ... it is very simple to do,
and if enough users ask, she or he will get arround to doing it ...
(I haven't yet, but only one user asked me so far ... ;)

regards,

francis


--
| B.F. Francis Ouellette  
| manager, yeast chromosome I project
| dept of biology, McGill university, Montreal, Qc, Canada
| francis at monod.biol.mcgill.ca




More information about the Bio-soft mailing list