Getting Around Flashcards

0
Q

cd

A

Change to another directory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
1
Q

ls

A

List out the contents of the current directory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

./

A

Short for “here”

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

../

A

Short for “the folder right above here”

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

~/

A

Short for home folder of the currently logged in user

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

mv

A

Move a file from one place or another:

mv ~ /my_text.txt ~/Documents/
mv ~ /my_text.txt ~/my_doc.txt

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

cp

A

Copy a file or folder from one place to another.

cp ./my_text.txt ~/Documents/

Now there are two copies of my_text.txt. One in the home folder, and one in ~/Documents/

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

rm

A

Remove a file or folder.

rm ~/my_text

With great power comes great responsibility.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

ln

A

Create a shortcut to a file or folder.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

|

A

Pipe allows you to chain commands together

command 1 | command 2

Here command does something, and when it is finished, like an assembly line, it passes the completed work to the second line for further processing.

ls - a | grep.git

Search for all files and then filter them for files matching the .git pattern.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly