Changes

Jump to: navigation, search

Tutorial10: Shell Scripting - Part 1

9 bytes removed, 10:32, 5 March 2021
no edit summary
::In the next investigation, you will learn to create and run shell scripts that<br >use variables, positional and special parameters. You will also learn how to<br><u>add</u> a '''she-bang line''' at the top of a shell script to force it to run in a specified shell.<br><br>Proceed to the next investigation.<br><br>
'''Bold text'''=INVESTIGATION 2: USING VARIABLES IN SHELL SCRIPTS =
In this section, you will learn how to use variables, positional and special parameters to assist you in creating adaptable shell scripts.
# Run your renamed shell script for confirmation by issuing:<br><span style="color:blue;font-weight:bold;font-family:courier;">./hello.bash</span><br><br>Take time to view the output and the values of the environment variables.<br><br>
# Issue the following linux command to add your current directory to the '''PATH''' environment variable:<br><span style="color:blue;font-weight:bold;font-family:courier;">PATH=$PATH:.</span><br><br>
# Issue the following linux command to confirm that the current directory '''"." ''' has been added to the PATH environment variable:<br><span style="color:blue;font-weight:bold;font-family:courier;">echo $PATH</span><br><br>
# Issue the following to run your Bash shell script just by name:<br><span style="color:blue;font-weight:bold;font-family:courier;">hello.bash</span><br><br>Did your Bash shell script run?<br><br>
# Exit your Matrix session, and log back into your Matrix session.<br><br>
13,420
edits

Navigation menu