codes Flashcards

1
Q

displays file contents onscreen or provide file contents to standard output

A

cat FILENAME

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

display files 1 and 2

A

cat FILE1 FILE2

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

return to home directory

A

cd

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

move up one level in the directory tree

A

cd ..

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

move to the /etc directory relative to the system root

A

cd /etc

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

use a tilde as a shortcut to get to your home directory, this moves you to the subdirectory

A

cd ~/subdir

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

move to the Projects directory relative to the current directory

A

cd Projects

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

Filter backspaces and reverse line feeds out of input. Use to make man pages editable without odd formatting

A

col -b

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

Close your current process (often a shell) and your Unix session if you close the login shell

A

CTRL D

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

close your current shell and your Unix session if you are in login shell

A

exit

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

Use to view Filename screen by screen

A

less Filename

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

close your Unix session

A

logout

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

list files and directories

A

ls

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

list the files and directories in the root directory

A

ls /

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

list the files and directories in a directory

A

ls directoryname

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

list all files and directories, including hidden ones

A

ls -a

17
Q

list files and directories by modification date

A

ls -c or ls -t

18
Q

list files and directories in long format, with extra information

A

ls -l

19
Q

list files and directories in long format, with extra information and human readable sizes

A

ls -lh

20
Q

view the specified section (5) of the man pages for command. Sometimes used a man -s 5 Command

A

man 5 command

21
Q

view the manual (help) pages for command

A

man command

22
Q

find appropriate man pages for “keyword”

A

man -k keyword

23
Q

view filetoview screen by screen

A

more filetoview

24
Q

change your password

A

passwd

25
Q

display the path and name of the directory you are currently in

A

pwd

26
Q

reset the shell to fix display problems

A

reset

27
Q

try to fix unexpected, sudden and strange display problems

A

stty sane

28
Q

Re-log in without having to log out

A

su -yourid

29
Q

become the root user

A

su

30
Q

run a command with the authority of root user

A

sudo commandname

31
Q

copy existingfile to a file named newfile

A

cp existingfile newfile

32
Q

copy existingfile to a file named newfile, prompting you before overwriting existing file

A

cp -i existingfile newfile

33
Q

copy the directory /Projects to the new name /shared/Projects, specifying recursive copy

A

cp -r /Projects /shared/Projects