Hi All,
Stumbled upon an interesting peculiarity in the Bash shell, which I would
like an explanation about. The issue goes hence:
On the shell when i type:
1.
select fname in *; do echo you picked $fname \($REPLY\) break; done;
i get a result that is expected.
2. when i type:
{select fname in *; do echo you picked $fname \($REPLY\) break; done;}
I get an error -> bash: syntax error nearunexpectedtoken 'do'
3. when i type:
(select fname in *; do echo you picked $fname \($REPLY\) break; done;)
(NOTICE NO BLANKS IN 2 & 3)
I get no error -> same execution as in 1.
4. when i type:
{ select fname in *; do echo you picked $fname \($REPLY\) break; done; }
I get no error -> same excution as in 1.
5. when i type:
{ select fname in *; do echo you picked $fname \($REPLY\) break; done;}
I get '>' & the shell waits for me to enter something??
(NOTICE THE SPACES IN 4 & 5)
I think there should be a reson for this behaviour. Can any one __HELP__ me?
thanx in advance
cheers
Anuj Sharma
DISCLAIMER: The information in this message is confidential and may be
legally privileged. It is intended solely for the addressee. Access to this
message by anyone else is unauthorised. If you are not the intended
recipient, any disclosure, copying, or distribution of the message, or any
action or omission taken by you in reliance on it, is prohibited and may be
unlawful. Please immediately contact the sender if you have received this
message in error. Thank you.
-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills. Sign up for IBM's
Free Linux Tutorials. Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
_______________________________________________
linux-india-help mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/linux-india-help