Terminal Flashcards

1
Q

ls

A

list all files

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

ls -a

A

shows ALL files even hidden

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

ls -l

A

gives you a long list of everything

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

ls -la

A

list a long list of everything

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

pwd

A

shows you where you are

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

How to go to a new directory then go back to previous

A

pushd

popd

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

How to know what your looking at

A

file

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

find files by name

A

locate

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

locate a command

A

which

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

create a directory/make directories

A

mkdir …

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

change file timestamps/create empty files

A

touch …

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

copy files and directories

A

cp

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

move (rename) files

A

mv

this can overwrite the file

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

remove a file

A

rm

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

remove a file to get rid of everything

A

rm *

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

remove a file that has a specific name

A

rm *

17
Q

remove a directory that has something in it

A

rm -r

18
Q

remove all directory that are empty

A

rmdir *

19
Q

How to print a file

A

cat

20
Q

Take input txt and push to a file

A

cat&raquo_space; file2

21
Q

download files found at specific urls

A

curl

22
Q

HOw to search for something in a file

A

grep

23
Q

search all files in a directory

A

grep *

24
Q

To find whole words only

A

gren -w phoenix *

25
Q

Ignore case sensitive words with grep

A

grep -i phoenix *

26
Q

search but include all subdirectory

A

grep -r phoenix *