man (manual)
man 명령어 사용 시 주로 사용되는 옵션에 대해서 알아본다.
-f, --whatis, equivalent to whatis
whatis와 동일한 결과를 나타낸다. 대상 텍스트의 매뉴얼이 무엇이 있는지 나타난다.
muabow@muabow-workspace:~$ man -f sleep
sleep (1) - delay for a specified amount of time
sleep (3) - sleep for a specified number of seconds
-k, --apropos, equivalent to apropos
대상 텍스트가 포함된 모든 매뉴얼을 나타낸다.
e.g.) sleep 으로 검색 시 매뉴얼에 sleep 이라는 키워드가 있는 모든 문서를 나타낸다.
muabow@muabow-workspace:~$ man -k sleep
clock_nanosleep (2) - high-resolution sleep with specifiable clock
nanosleep (2) - high-resolution sleep
rtcwake (8) - enter a system sleep state until specified wakeup time
sleep (1) - delay for a specified amount of time
sleep (3) - sleep for a specified number of seconds
sleep.conf.d (5) - Suspend and hibernation configuration file
systemd-hibernate.service (8) - System sleep state logic
systemd-hybrid-sleep.service (8) - System sleep state logic
systemd-sleep (8) - System sleep state logic
systemd-sleep.conf (5) - Suspend and hibernation configuration file
systemd-suspend-then-hibernate.service (8) - System sleep state logic
systemd-suspend.service (8) - System sleep state logic
usleep (3) - suspend execution for microsecond intervals
-K, --global-apropos, search for text in all pages
모든 매뉴얼 페이지에서 해당 텍스트를 검색한다.
man -K sleep
--Man-- next: gpg-connect-agent(1) [ view (return) | skip (Ctrl-D) | quit (Ctrl-C) ]
--Man-- next: free(1) [ view (return) | skip (Ctrl-D) | quit (Ctrl-C) ]
-w, --where, --path, --location, print physical location of man page(s)
매뉴얼 페이지의 물리적 위치를 나타낸다.
muabow@muabow-workspace:~$ man -w sleep
/usr/share/man/man1/sleep.1.gz
# whereis 명령어로 man -w 와 비슷한 결과를 확인할 수 있다.
muabow@muabow-workspace:~$ whereis sleep
sleep: /usr/bin/sleep /usr/share/man/man1/sleep.1.gz /usr/share/man/man3/sleep.3.gz
'IT > linux' 카테고리의 다른 글
valgrind, linux memory leak detection (0) | 2023.03.21 |
---|---|
linux awk 예제 (0) | 2023.03.21 |
mplayer / slave mode, idle, standalone, pipe, command, cache (0) | 2022.09.09 |
Bogomips 개요, 측정 방법 (0) | 2022.09.09 |
바이너리 동적 라이브러리 링크 확인, Dynamic linker (1) | 2022.09.07 |
댓글