Changes

Jump to: navigation, search

Tutorial10: Shell Scripting - Part 1

5 bytes added, 08:42, 16 March 2021
INVESTIGATION 2: SHE-BANG LINE / VARIABLES / PARAMETERS
# While in the ''Bourne shell'', issue the following Linux command:<br><span style="color:blue;font-weight:bold;font-family:courier;">./hello</span><br><br>You should notice that the shell name is running in the '''Bash shell''' (i.e. ''/bin/bash'').<br><br> It is a good idea to rename your shell script to include an '''extension''' to<br>indicate that it is a '''Bash Shell''' script. <br><br>
# Issue the following Linux command to rename your shell script file:<br><span style="color:blue;font-weight:bold;font-family:courier;">mv hello hello.bash</span><br><br>
# Confirm that the modification work by running your renamed Bash shell scriptworks by issuing the following:<br><span style="color:blue;font-weight:bold;font-family:courier;">./hello.bash</span><br><br>
# Enter the following Linux command to '''exit''' the ''Bourne shell'' and return to your ''Bash shell'':<br><span style="color:blue;font-weight:bold;font-family:courier;">exit</span><br><br>Let's use some '''ENVIRONMENT variables''' in our Bash Shell script.<br><br>
# Use a text editor to edit the shell script called '''hello.bash'''<br><br>
13,420
edits

Navigation menu