![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| If statement - How to write a null statement | april | Shell Programming and Scripting | 3 | 04-16-2008 01:14 PM |
| AWK - conditional cause | Rafael.Buria | Shell Programming and Scripting | 2 | 01-28-2008 01:24 PM |
| quoting in conditional statement | 3Gmobile | Shell Programming and Scripting | 2 | 08-14-2006 03:14 AM |
| awk conditional statement | 3Gmobile | Shell Programming and Scripting | 10 | 08-09-2006 10:01 AM |
| more elegant way for conditional statement needed | candyflip2000 | Shell Programming and Scripting | 3 | 05-18-2006 07:52 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Sorry I meant shell script.
Basically, I want to do: [ `echo "abcd" | cut -c1` = "a" ] && echo "a" ? echo "b" Normally, it is a good idea or not to put a command in a test operation. For instance, [ `echo "abcd" | cut -c1` = "a" ] If not what else I can do. Thank you |
|
||||
|
[ `echo "abcd" | cut -c1` = "a" ] && echo "a" || echo "b"
|
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|