Command Line Interface/Commands (I) Flashcards
which shell am I using?
echo $SHELL
send text to the CLI’s output
echo “hello, everyone”
change your current directory
cd _______
(name of/path to the directory you want to change
to)
open the manual to get info on a command
man ________
(name of command you want to look up)
send text to the CLI’s output AND have cursor appear on same line as the output
echo -n “Hello, everyone”
find out where you currently are in the file system (which directory you are in)
pwd
leave/close the manual
q
move a file from your current directory to another directory
mv _________ _______
(which file?) (destination)
mv jobs.txt ../..
create an empty file
touch _________
(name/extension of file)
create a new directory
mkdir ___________
(name of directory)
go to the home directory (three ways to do it)
cd
cd ~
cd $HOME
go to the root directory
cd /
list all the files and sub-directories in a folder
ls ___________
(name of folder)
list all the files and sub-directories in a folder AND have more info shown AND have everything in an easier-to-read format
ls -lah ____________
(name of directory)
rename a file
mv ________ __________
(old name) (new name)