10 Terminal Commands Every User Should Know
1. Change Directory
Command: cd
What it does: Changes the directory of the command line path.
Example: cd “path/to/directory/”
2. Listing Directory
Command: ls
What it does: Lists the contents of a directory.
Example: ls “path/to/directory/”
3. Open files
Command: open
What it does: Opens a file.
Example: open “filename”
4. Copy a file to another directory
Command: cp
Example: cp “filename” “newfilename”
5. Move a file
Command: mv
Example: mv “filename” “path/to/new/file/location”
6. Renaming a file
Command: mv
Example: mv “path/to/filename” “path/to/newfilename”
7. Create a directory
Command: mkdir
Example: mkdir “path/to/new/directory”
8. Remove an empty directory
Command: rmdir
Example: rmdir “path/to/directory”
9. Remove nested directories
Command: rm -R
Example: rm -R “/path/to/root/directory”
10. Execute commands with superuser privileges
Command: sudo
Example: sudo “command”