하루의 대학원 도전기

Basic Linux Commands 본문

프로그래밍/리눅스

Basic Linux Commands

내가하루다 2021. 10. 27. 12:02
728x90

ls

cd [directory]

pwd

mkdir [directory name]

rmdir [directory]

rm [file or directory]

clear

vi ( editor )

ps

mv

cp

cat

echo

chmod

gcc [c file]

gdb [executable file]

man [linux command or c function] : open man page

 

[ useful options ]

ls -l

ls -a

you can combine two or more options together.

e.g.,) ls -al

rm -rf

ps -ef

gcc -o

gcc -Wall -Werror

when you compile c file with gcc, sometimes you need to link something like -lrt or -pthread.

gcc -o thread thread.c -Wall -Werror -pthread

gcc -g : used for debugging

 

need help? use --help option

e.g.,) ls --help

more details, use manual pags

728x90

'프로그래밍 > 리눅스' 카테고리의 다른 글

[Linux] Ctags 사용법  (0) 2021.12.02
리눅스 터미널 프롬프트 유용한 단축키들  (0) 2021.11.25