1. Home
  2. Docs
  3. Beginning UNIX on Raven
  4. Answers
  5. Answers to file and navigation exercises

Answers to file and navigation exercises

1. Create a directory called outputs

mkdir outputs

2. Create blank files named blank.txt, blank2.txt, blank3.txt in that directory

cd outputs

touch blank1.txt touch blank2.txt touch blank3.txt

3. List the files in various formats (normal, detailed, chronological).


ls –l

ls -lt

4. Rename blank.txt blank1.txt

mv blank.txt blank1.txt

5. Rename the directory analysis_outputs

cd ..

mv outputs analysis_outputs

6. Delete the contents of the directory

rm ./outputs/*

7. Delete the analysis_ouputs directory

rmdir analysis_outputs

8. Display a list of the commands you have just entered.