![]() |
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 |
| meaning of ${0%${0##*/}} | nyelavarthy | AIX | 7 | 09-23-2008 02:48 AM |
| if [ ! -r ${1} ] meaning in ksh | naveeng.81 | Shell Programming and Scripting | 1 | 04-09-2008 01:47 PM |
| OopenSSH not letting me in! | BG_JrAdmin | SUN Solaris | 2 | 09-12-2006 11:54 AM |
| what is the meaning here? | forevercalz | Shell Programming and Scripting | 2 | 09-29-2005 12:46 PM |
| client app not letting go of socket | fusion99 | UNIX for Dummies Questions & Answers | 1 | 02-20-2004 10:13 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
help me out in letting me know the meaning of sh, ksh, bash
Could you please help me out in letting me know the meaning of
Code:
#!/bin/sh #!/bin/ksh #!/bin/bash ....Also please view the below mention script, could you please explain whats this script doing Code:
#!/bin/bash
t=100
echo $t
echo $tea
echo ${t}ea
Last edited by Neo; 07-04-2009 at 11:30 AM.. Reason: added code tags and changed subject for user, cost 15000 bits |
| Bits Awarded / Charged to jojo123 for this Post | |||
| Date | User | Comment | Amount |
| 07-04-2009 | Neo | changed title, added code tags.... do it yourself per rules. | -15,000 |
|
|||||
|
Hello,
Per our forum rules, all threads must have a descriptive subject text. For example, do not post questions with subjects like "Help Me!", "Urgent!!" or "Doubt". Post subjects like "Execution Problems with Cron" or "Help with Backup Shell Script". The reason for this is that nearly 95% of all visitors to this site come here because they are referred by a search engine. In order for future searches on your post (with answers) to work well, the subject field must be something useful and related to the problem! In addition, current forum users who are kind enough to answer questions should be able to understand the essence of your query at first glance. So, as a benefit and courtesy to current and future knowledge seekers, please be careful with your subject text. You might receive a forum infraction if you don't pay attention to this. Thank you. The UNIX and Linux Forums |
|
||||
|
The first line of a script specifies what "language" the script is written in (and should be used to execute what follows).
Code:
#!/bin/sh - means Bourne shell #!/bin/ksh - means Korn shell #!/bin/bash - means Bourne Again shell #!/usr/bin/perl - means Perl Code:
#!/bin/bash
t=100 - sets a variable called t to 100
echo $t - prints the value of variable t
echo $tea - prints the value of variable tea
echo ${t}ea - prints the value of t followed by the literal characters ea
Last edited by scottn; 07-04-2009 at 12:43 PM.. |
|
||||
|
I missed out the word "not". But reading it back, the grammer is pretty rubbish too.
Simpler would be Quote:
I should use: #!/bin/english I know what I was trying to say, here, but just made a complete mess of it... Quote:
Last edited by scottn; 07-04-2009 at 12:47 PM.. |
| Sponsored Links | ||
|
|