basic commands Flashcards
how do you move through the directories
by using cd
how do you list everything in the current directory?
ls
How do you find out where you are in the directory hierarchy?
pwd
how do you delete(remove) a file?
rm
how do you remove a directory?
rm -r <directory></directory>
How do you include spaces in the name of a directory?
you enclose in ” “
how do you move out of a directory?
cd ..
how do you make a new folder?
mkdir <“name of folder”>
how do you clear the terminal?
clear
How do you duplicate a document?
you use cp
julio$ cp bayram.png bayramCopy.png
how do you put a copy of a doc in a directory?
you also use cp but the destination must be the new path to the target folder
juliohud:desktop julio$ cp bayram.png ~/documents
How do you move a file or folder to another directory?
using mv
julio$ mv “test folder” ~/documents
how do you make a new text document?
you use nano
julio$ nano“test file”
how do you open a text document?
you also use nano
julio$ nano “dave was here”
how do you open/read any file?
that is the first line of the text
use cat
juliohud:desktop julio$ cat“dave was here”
hey this is so cool!