Here is your chance to be creative. Craft your own shell script that has 6 different actions. For example, listing the current directory would be one, displaying the date to STDOUT would be a second. You do not get to use those examples, so make up your own.
Copy your script here and submit a screenshot of the executed script from a terminal window.
# mkdir for making new directory
mkdir newdir
# cd for changing directory
cd newdir
# pwd for printing current working directory
pwd
# touch for creating a newfile
touch newfile
# echo with redirection
echo This is a new file > newfile
# grep to search keyword 'new' in newfile
grep new newfile
The above script performs six of the most basic operations in shell. These are:
1. mkdir for making new directory
2. cd for changing directory
3. pwd for printing current working directory
4. touch for creating a newfile
5. echo with redirection
6. grep to search pattern in a file
Output screenshot:
Get Answers For Free
Most questions answered within 1 hours.