-- Original Message ---
From: "Todd A. Jacobs" <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Sent: Sat, 11 Jan 2003 16:34:40 -0800 (PST)
Subject: Re: Passing args
> On Sat, 11 Jan 2003, Mike Vanecek wrote:
>
> > I just did a default install which was
On Sat, 11 Jan 2003, Mike Vanecek wrote:
> I just did a default install which was bash. How and where would I
> change to bash2?
/usr/bin/chsh -s /bin/bash2
--
"Of course I'm in shape! Round's a shape, isn't it?"
--
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]?subject=unsu
-- Original Message ---
From: "Todd A. Jacobs" <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Sent: Sat, 11 Jan 2003 15:37:50 -0800 (PST)
Subject: Re: Passing args
> On Sat, 11 Jan 2003, Mike Vanecek wrote:
>
> > [root@www root]# type gedx
> > bash:
Thank you, thank you, thank you.
-- Original Message ---
From: "Todd A. Jacobs" <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Sent: Sat, 11 Jan 2003 15:36:06 -0800 (PST)
Subject: Re: Passing args
> On Sat, 11 Jan 2003, Mike Vanecek wrote:
>
> > ./d
On Sat, 11 Jan 2003 [EMAIL PROTECTED] wrote:
> should that be "gedit $1 && shift;" ?
No, the single "&" is tokenized by the shell as both the job backgrounder
and a command separator (e.g. ";"). The shell often compresses functions
like this, presumably to save RAM.
The double ampersand is th
On Sat, 11 Jan 2003, Mike Vanecek wrote:
> [root@www root]# ./getfun
> Profile executed
$ . ./getfun
rday
--
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]?subject=unsubscribe
https://listman.redhat.com/mailman/listinfo/redhat-list
On Sat, 11 Jan 2003, Mike Vanecek wrote:
> [root@www root]# type gedx
> bash: type: gedx: not found
See my previous post. Source the script, don't execute it. And use bash2
instead of bash; there's rarely a good reason not to do so.
--
"Of course I'm in shape! Round's a shape, isn't it?"
-
On Sat, 11 Jan 2003, Mike Vanecek wrote:
> ./dummy
Don't do this. Use "source dummy" instead. Bash (instead of bash2) isn't
putting the function into the current shell when you execute it.
Whatever the reason, why not just avoid all the fuss? Create ged
somewhere in your path as a script, chmo
Todd, here are the results of my run:
[root@www root]# cat getfun
# ed is a real program, so use something else to avoid confusion.
# Usage: ged
function gedx {
while [[ $1 ]]; do
gedit $1 &
shift
done
}
function gedz {
while [[ -n $1 ]]; do
gedit $1 &
shift
On Sat, 11 Jan 2003 17:08:40 -0600 Mike Vanecek <[EMAIL PROTECTED]>
wrote:
> > while [[ -n $1 ]]; do
> > gedit $1 & shift;
should that be "gedit $1 && shift;" ?
^^
rday
--
redhat-list mailing list
unsubscribe mailto:[EMAIL PROTECTED]?subject=unsubscrib
Thanks for the response, but ...
-- Original Message ---
From: "Todd A. Jacobs" <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Sent: Sat, 11 Jan 2003 14:03:31 -0800 (PST)
Subject: Re: Passing args
> This doesn't look right. The brackets are too close, and
On Fri, 10 Jan 2003, Mike Vanecek wrote:
> ged ()
> {
> while [[$1]]; do
> gedit $1 & shift;
> done
> }
This doesn't look right. The brackets are too close, and will not be
properly tokenized. On my system:
$ type ged
ged is a function
ged ()
{
while [[
Uhm, shouldn't you be in bed by now . Thank you for the response, but I
still cannot get it to work on a RH 8 machine.
-- Original Message ---
From: Mad Hatter <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Sent: Fri, 10 Jan 2003 22:06:48 -0800 (PST)
Subject: Re: Passing
hought that since it would
> not work.
>
>
> -- Original Message ---
> From: "Todd A. Jacobs" <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED]
> Sent: Fri, 10 Jan 2003 18:41:30 -0800 (PST)
> Subject: Re: Passing args
>
> > On Fri, 10 Jan 200
OK, no positional parameters in an alias; sorta thought that since it would
not work.
-- Original Message ---
From: "Todd A. Jacobs" <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Sent: Fri, 10 Jan 2003 18:41:30 -0800 (PST)
Subject: Re: Passing args
> On Fri
-- Original Message ---
From: j_post <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Sent: Fri, 10 Jan 2003 17:55:31 -0800
Subject: Re: Passing args
> On Friday 10 January 2003 05:37 pm, you wrote:
> > The answer to this is probably so easy ...
> >
> > I w
On Fri, 10 Jan 2003, Mike Vanecek wrote:
> I want to be in a terminal and type ed filename and have the editor open and
> start editing filename in the background.
You can't use positional parameters in an alias; you need to use a
function instead:
# ed is a real program, so use something
On Friday 10 January 2003 05:37 pm, you wrote:
> The answer to this is probably so easy ...
>
> I want to be in a terminal and type ed filename and have the editor open
> and start editing filename in the background.
>
> Easy, put an alias in /etc/profile
>
> alias ed="gedit $1 & " <--- this one
The answer to this is probably so easy ...
I want to be in a terminal and type ed filename and have the editor open and
start editing filename in the background.
Easy, put an alias in /etc/profile
alias ed="gedit $1 & "
alias ed="gedit $%1 & "
alias ed="gedit %$1 & "
alias ed="gedit %1 & "
W
19 matches
Mail list logo