Basic Commands Flashcards
What is the command to see the current working directory?
pwd
What is the command to list items in current directory?
ls
What is the command to change directory?
cd
What symbol represents home?
~
tilda
What is the command to change directory outside the current one?
cd ..
What is the command to see all files and directories (including hidden)?
ls -a
What denotes a file or folder being hidden?
.
i.e .hiddenfolder
What is the command to create a file?
touch
i.e touch file.txt
How can you read the contents of a text file?
cat
i.e cat file.txt
What is the command to create a directory?
mkdir
i.e mkdir Folder1
What is the command to move a file?
mv
i.e mv file.txt ..
What is the command to remove an empty directory?
rmdir
i.e rmdir Folder1
What is the command to remove a directory containing items?
rm -r
i. e rm -r Directory1
* rm without parameter -r only removes files, r means recursively
What is the command to get help with a specific command?
man
i.e man mv
What is the shortcut to go to the beginning of the line in the shell?
ctrl + a