The Command Line Notes
The Command Line
- the command line is structured by: Command-command argument-options
- Previously used commands are stored in a history and can be refenced by using the up and down keys
Basic Navigation
- Commands
- PWD- Print Working Directory
- LS- List
- CD- Change Directory
- mkdir- Make Directory
- touch- creates a file
- cp copys a file path
- mv moves a file or directory
- Paths:
- absolute- absolute path specify a location in relation to the root directory
- reletive- reletive path specify based on where you currently are in the directory
- ~ is reference to the home directory
- . is reference to the current directory (ex. “code .”)
- .. is reference to the parent directory
More About Files
- Everything is a file. keyboard is a read only file, monitor is a write only file, all text is also a file
- Linux is case sensetive
- to use spaces in names you can use ‘’ around the name and treat it like a string or use a / in between the words
- files that start with a ‘.’ are hidden (ex. .env)
Manual Pages
- manual pages are pages you can reach with “man < command to look up >” that give you info on all the commands you can do.
- you can search keywords if youre not sure exactly what youre looking for.
File Manipulaion
- setting up a well thought out file storage system is important
- you can make a directory with mkdir and remove one with rmdir.