Deck 1 Flashcards

1
Q

What does the terminal do?

A

sends commands and receives outputs (displays stuff)

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

What language do we use in our terminal?

A

ZSH but bash is the most popular

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

Alternative names for the terminal?

A

Command line, shell and CMI (command line interface)

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

pwd

A

print working directory

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

cd

A

change directory

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

ls, ls -l, ls -lh, ls -a, ls -d

A

list, ls -l (list with details), ls -lh (list with human-readable details), ls -a (list hidden files), ls -d (show directory)

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

*

A

wildcard: like a catch all, looks for anything

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

How do you clear the screen?

A

2 ways: “control + L” or “clear”

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

What does history show you?

A

All your past inputs, and if you want to select a specific one then put “!#” where # is the actual number of the line you want to select

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

How do you make a new directory?

A

“mkdir name_of_directory”

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

How do you create a new file? A hidden new file?

A

“touch new_file_name”, “touch .new_file_name”

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

How do you open vs code?

A

“code”

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

What does “mv” do?

A

moves file to a new directory or renames a file

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

How do you remove a file and a directory and why should you be careful about this?

A

“rm” to remove file, “rm -r” to remove directory.

Must be careful because this action is implemented FOREVERRRRR, always do an ls beforehand!!

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

How do you view the contents of a file?

A

“less”

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

How do you print file contents out into the terminal where everything gets dumped out?

A

“cat”

17
Q

What does ~ mean?

A

Home directory

18
Q

cd .. does what?

A

Takes you one directory up (dot dot up)

19
Q

How do you copy a file?

A

“cp source_file destination_file”

where you can use abs or relative paths

20
Q

what does man do?

A

Shows you the manual for the input

21
Q

kilo

A

10^3

22
Q

mega

A

10^6

23
Q

giga

A

10^9

24
Q

tera

A

10^12

25
Q

Relative path:

A

relative to the current working directory that you are in

26
Q

Abs path:

A

relative to the root, where the root is: /

27
Q

How do you go to the beggining of an input?

A

“control + a”

28
Q

How do you go to the end of an input?

A

“control + e”

29
Q

What is binary?

A

The number system of zeros and ones which have a base of 2.

30
Q

What is a bit?

A

0 or 1

31
Q

How many bits in a byte?

A

One byte = 8 bits

32
Q

How do you name something with a space?

A

“star\ wars” (but we usually don’t want to do this)

33
Q

cd does what?

A

Takes you to the home directory

34
Q

cd - does what?

A

takes you to the last place you were