Changes

Jump to: navigation, search

Tutorial5: Redirection

691 bytes added, 11:12, 14 October 2020
INVESTIGATION 3: ISSUING MULTIPLE UNIX/LINUX COMMANDS
# Confirm you are located in your '''home''' directory.<br><br>
# Issue the following Linux commands (using semicolon to separate each command): <span style="color:blue;font-weight:bold;font-family:courier;">cal;pwd;date</span><br><br>Note the from the output the order of how each of those commands were processed.<br><br>
# Issue the following Linux commands: <span style="color:blue;font-weight:bold;font-family:courier;">(cal;pwd;date)</span><br><br>Was there any difference in the output of this command as opposed to the previous command?<br><br>Let's see how grouping affects working with redirection.<br><br># Issue the following Linux commands: <span style="color:blue;font-weight:bold;font-family:courier;">cal;pwd;date > output.txt</span># Issue a Linux command to view the contents of the file called '''output.txt'''<br><br>What do you notice?<br><br>Let's use grouping to make modification to the previous command<br><br># Issue the following Linux commands: <span style="color:blue;font-weight:bold;font-family:courier;">(cal;pwd;date) > output.txt</span><br><br># Issue a Linux command to view the contents of the file called '''output.txt'''<br><br>What do you notice? What did grouping the three Linux command do?<br><br>
# Issue the following Linux pipeline command (using \ at the end of most lines):<br><span style="color:blue;font-family:courier;font-weight:bold">echo "This will be split over multiple \<br>lines. Note that the shell will realize \<br>that a pipe requires another command, so \<br>it will automatically go to the next line" |tr '[a-z]' '[A-Z]'</span><br><br>Did the command work? What does this command do?<br><br>
# After you complete the Review Questions sections to get additional practice, then work on your '''online assignment 2'''<br>and complete '''section3''' labelled: '''Redirection and Pipes'''.
13,420
edits

Navigation menu