ch1+2. Intro and Basic Tasks Flashcards
What shell does the course focus on?
Bash Shell
What does Bash stand for?
Bourne Again Shell
What are the parts of a Bash shell command?
Command, Options, Argument
Is the linux CLI case sensitive?
Yes
VIM
Linux pre-installed text editor
VIM insert command
-i
VIM command to exit ‘insert’
esc
VIM command to save and exit
‘:wq’
What key to auto-complete commands?
tab
What does bold text in a command manual signify?
Type exactly as shown
What does italic text in a command manual signify?
Replace with appropriate argument.
What are ’-abc’ ?
Options
What are ‘-a|-b’ ?
Either/Or options
What does ‘man -a [command]’ do?
Finds matching queries inside the manual of the command.
What does ‘man -D command’ do?
Prints debugging information on the command.
What does ‘man -f [command]’ do?
Short command description.
What does ‘man -h [command]’ do?
Prints help options.
What does:
man -k .
do?
Prints all manual pages where ‘.’ is a regex for any character. You could also search for other strings.
Key to reach the top of a man page?
Home key
Key to reach the bottom of a man page?
End key
Keys to move up or down on a man page?
Page up - Page down
In a man page, what key can begin a search?
/ or a forward slash
In a search of a man page, what key can move to the next occurrence of the search?
n
In a search of a man page, what key can navigate to the previous occurrence of the search string?
‘p’
In a man page, what key can quit out of the man page?
‘q’
In what directory can you find documentation on all libraries, sys utilities, and software packages?
/usr/share/doc
What is the grep command used for?
Search a file for a string
What does ‘grep -i dingo’ do?
Searches the opened file for ‘dingo’ without regard for case.
What does the ‘echo’ command do?
It repeats a string as output.
What does the ‘ls’ command do?
It prints the contents of the present working directory.
What does the ‘cp’ command do?
Copies a file, and can save the copy to a new location.
What does the ‘cd’ command do?
It stands for ‘change directory’ and it can accept both relative and absolute file paths as arguments.
What does the ‘clear’ command do?
Clears the output of the terminal.
What does the ‘cat’ command do?
Prints the contents of a file.
What does the ‘less’ command do?
Prints the file, page by page. Exit the file with the ‘q’ key.
What does the ‘sudo’ command do?
‘super user do’ forces the terminal to execute the rest of the command as root. Depending on your user profile and privileges, the terminal may prompt you for the root password.
What does the ‘history’ command do?
Prints a list of the previous commands run.
What does the ‘ls -al’ command do?
‘-a’ shows hidden files
‘-l’ stands for ‘long’ and prints more information.
What does the ‘touch’ command do?
Creates a file of any type.
What does the ‘su - root’ or ‘su - ‘ command do?
Changes user to root after prompting for root password.
What does the ‘apropos compress’ command do?
It returns all commands where ‘compress’ appears in the manual for the command.
What does the command ‘whatis [command]’ do?
Prints a brief description of the given command.