UNIX COMMANDS Flashcards
cp -r arg1 arg2
copy content of arg1 directory to the arg2 directory.
man command
will print the manual for using a specific command.
cd
change directory.
cd /
go to root directory.
cd ~
go to home directory.
cd ..
navigate one directory up.
cd ./arg1/arg2
navigate into arg2 directory which is inside arg1 directory.
ls
allows us to see the contents of the current directory.
ls -a
allows you to see hidden items in a directory.
ls arg1
allows us to see the contents in the arg1 directory.
mkdir
allows us to create a new directory.
pwd
prints the directory you’re currently working in.
echo
command that will print a string or the result of a command to the console.
touch
creates a file but also allows you to modify the timestamp of a file. (Usually used to create empty files).
cat > filename
creates a new file
cat filename
Displays the file content