Command line
Objectives
- Be able to open the command line on their computer;
- Be familiar with directory and file structure through the command line.
- Be able to manipulate files and directories through the command line.
Plan
- Demonstrate opening the command line. Explain that this might be different on
everyone’s machine.
- Identify current directory and open it in a GUI to see that you’re seeing the
same things. Possibly, draw file structure on the board.
- Demonstrate listing contents (also compare to GUI).
- Create the rsd-directory. (also compare to GUI)
- Move in to directories and specifically explain .. (also compare to GUI).
- Copy files.
- Move/rename (explain that these are essentially the same thing)
- Delete files.
- Manipulate directories: discuss recursive flag.
- Demonstrate tab completion and using history with up/down arrows.
FAQ
- Why does your terminal look different to mine?
- What does /s stand for in rmdir /s? Answer It stands for “sub
directories”.
- What does -r stand for in rm -r and cp -r? Answer It stands for
“recursive”.