How to say this in Bash?

2009-05-25 Thread Unga
Dear all This may be slightly OT, but I'm using on a FreeBSD machine. How to convert following into bash style? echo ${X} ${Z} echo ${Y} ${Z} Best regards Unga ___ freebsd-questions@freebsd.org mailing list

Re: How to say this in Bash?

2009-05-25 Thread Matthew Seaman
Unga wrote: Dear all This may be slightly OT, but I'm using on a FreeBSD machine. How to convert following into bash style? echo ${X} ${Z} echo ${Y} ${Z} Exactly the same in posix standard /bin/sh or in bash. bash(1) should be capable of running any compliant /bin/sh script directly.

Re: How to say this in Bash?

2009-05-25 Thread Unga
--- On Mon, 5/25/09, Matthew Seaman m.sea...@infracaninophile.co.uk wrote: From: Matthew Seaman m.sea...@infracaninophile.co.uk Subject: Re: How to say this in Bash? To: Unga unga...@yahoo.com Cc: freebsd-questions@freebsd.org Date: Monday, May 25, 2009, 8:10 PM Unga wrote: Dear all

Re: How to say this in Bash?

2009-05-25 Thread Jerry
On Mon, 25 May 2009 07:36:45 -0700 (PDT) Unga unga...@yahoo.com wrote: Here is what happens in bash shell: $ echo ${X} ${Z} bash: ${Z}: ambiguous redirect Perhaps I am misinterpreting your question; however, if I define both ${X} and ${Z} in a script prior to running your snippet, I do not

Re: How to say this in Bash?

2009-05-25 Thread Unga
--- On Mon, 5/25/09, Jerry ges...@yahoo.com wrote: From: Jerry ges...@yahoo.com Subject: Re: How to say this in Bash? To: freebsd-questions@freebsd.org Date: Monday, May 25, 2009, 11:22 PM On Mon, 25 May 2009 07:36:45 -0700 (PDT) Unga unga...@yahoo.com wrote: Here is what happens

RE: How to say this in Bash?

2009-05-25 Thread Peter Steele
$ echo ${X} ${Z} bash: ${Z}: ambiguous redirect I want to append all variables in X and Y into Z so that echo $Z should be: XX1=YES XX2=YES YY1=YES YY2=YES Redirection is not the right way to do it. Just do this: $ Z=$X $Y $ echo $Z XX1=YES XX2=YES YY1=YES YY2=YES

Re: How to say this in Bash?

2009-05-25 Thread Matthew Seaman
Unga wrote: --- On Mon, 5/25/09, Matthew Seaman m.sea...@infracaninophile.co.uk wrote: Here is what happens in bash shell: $ echo ${X} ${Z} bash: ${Z}: ambiguous redirect So, what's the value of ${Z}? Unless that expands to something that could be a valid file name you'll get an error

Re: How to say this in Bash?

2009-05-25 Thread Matthew Seaman
Unga wrote: --- On Mon, 5/25/09, Jerry ges...@yahoo.com wrote: From: Jerry ges...@yahoo.com Subject: Re: How to say this in Bash? To: freebsd-questions@freebsd.org Date: Monday, May 25, 2009, 11:22 PM On Mon, 25 May 2009 07:36:45 -0700 (PDT) Unga unga...@yahoo.com wrote: Here is what happens

Re: How to say this in Bash?

2009-05-25 Thread Unga
--- On Tue, 5/26/09, Matthew Seaman m.sea...@infracaninophile.co.uk wrote: From: Matthew Seaman m.sea...@infracaninophile.co.uk Subject: Re: How to say this in Bash? To: Unga unga...@yahoo.com Cc: freebsd-questions@freebsd.org Date: Tuesday, May 26, 2009, 1:20 AM Unga wrote: --- On Mon