From: grosen@isc.cs.ndsu.nodak.edu (Johannes Grosen) Subject: Re: Questions about bash Date: Wed, 28 Apr 1993 12:47:50 GMT
In article <1rlna1INNbib@shelley.u.washington.edu> quantum@stein.u.washington.edu (Tsung-lung Li) writes:
>
>
>Hello,
>
>I am trying to port my .cshrc file on my mainframe account to linux.
>It seems to me that bash does not recognize \!* and \!:1 , for example
>
>alias ll 'ls -F \!*'
alias ll='ls -F'
>alias app 'cat \!:1 >> \!:2'
app()
{
cat $1 >> $2
}
>What are the equivalents in bash?
Bash (as well as other ksh and sh) don't allow aliases with arguements.
You have to use functions instead. There is no reason for an argument
with the first alias since the alias is expanded along with your arg.
For example 'ls *.c' expands to 'ls -F main.c foo.c bar.c ....'
>Tsung
>
>
-- Johannes Grosen grosen@isc.cs.ndsu.NoDak.edu ISC System Administrator North Dakota State University (701)237-8282