属狗与什么属相相合| prog是什么意思| 手指关节肿大是什么原因| 吃东西没有味道是什么原因| 割包皮有什么好处和坏处| 清补凉是什么| dha孕妇什么时候吃| 为什么吃完饭就想拉屎| 拔罐的原理是什么| vin是什么意思| 帆布是什么材质| 吃什么补血补气效果好| 一个口一个巴念什么字| 肺纤维化有什么症状| 肚子长痘痘是什么原因| 58年属什么今年多大| 手指关节肿大是什么原因| 胎心胎芽最晚什么时候出现| 心脏积液吃什么药最好| 灵魂是什么| 安之若素是什么意思| 1800年是什么朝代| 指甲上白色月牙代表什么| 脚后跟疼是什么原因引起的| 肚子左边是什么部位| 什么叫腱鞘炎| 犹太人是什么人| 自己做生意叫什么职业| 牙龈发炎是什么原因引起的| 甲状腺素低吃什么能补| 姨妈期可以做什么运动| 威胁是什么意思| 一个火一个同念什么| 阿佛洛狄忒是什么神| 冗长是什么意思| 荔枝不能跟什么一起吃| 燊什么意思| sjb什么意思| 富贵竹开花什么预兆| 心力衰竭吃什么药| 脚筋疼是什么原因| 没有料酒可以用什么代替| 糖类抗原125高是什么意思| 77年的蛇是什么命| lot是什么| 小孩尿不出来尿是什么原因| 月经多是什么原因| 备孕为什么要吃叶酸| 性格缺陷是什么意思| 吃什么可以快速美白| 真丝棉是什么面料| 条索灶是什么意思| 黑胡椒和白胡椒有什么区别| 领导谈话自己该说什么| 低血压食补吃什么最快| a和ab型生的孩子是什么血型| 豆五行属什么| 男人吃海参有什么好处| 吃什么可以化掉息肉| 为什么全麻手术后不能睡觉| 吸土是什么意思| 处女座是什么星象| 跃然纸什么| 肠胃感冒什么症状| 九浅一深是什么意思| 中期唐氏筛查查什么| 动土破土是什么意思| 果酸是什么| saa是什么意思| 梦见大水是什么意思| 查抗体是做什么检查| 月经期头疼是什么原因| 孩子半夜咳嗽是什么原因| 什么叫社保| 羊肉不能和什么一起吃| 什么血型不招蚊子| 牙痛吃什么| 玄关挂什么装饰画好| 女孩子学什么专业比较好| 龙虾和什么不能一起吃| 山药有什么功效和作用| 天天喝绿茶有什么好处和坏处| 做狐臭手术挂什么科| 一直发低烧是什么原因| 中医四诊是什么| bi是什么| trendiano什么牌子| 釉是什么| 熳是什么意思| 情何以堪是什么意思| 客观原因是什么意思| 壶嘴为什么不能对着人| 嘴唇轻微发麻什么病兆| pcr医学上是什么意思| 什么病不能吃绿豆| 生完孩子吃什么补身体| 仔细的什么| scarves什么意思| 见利忘义是什么生肖| 为什么男人| 门可罗雀是什么意思| 缺蛋白质吃什么补得快| 有鳞状细胞是什么意思| 疤痕增生挂什么科| 猫薄荷是什么| 陈皮泡水喝有什么好处| 嗔什么意思| 传度是什么意思| 什么是蚕豆病| 彻夜难眠什么意思| 丹青指什么| 什么相关四字成语| sr是什么意思| 什么是因果| 检查血液挂什么科| 唾液腺是什么组织| et什么意思| 自投罗网是什么意思| 特需病房是什么意思| gsp全称是什么| 吃什么去肝火见效快| 茬是什么意思| 歼31为什么没消息了| kerry英文名什么意思| 前列腺吃什么食物调理| 子宫后倾位是什么意思| 肾结石什么不可以吃| 胚胎是什么| 维生素e的功效与作用是什么| 胆囊疼是什么原因| 喝咖啡不能吃什么食物| 吃什么会放屁| puma是什么品牌| 西瓜不能跟什么一起吃| 便秘吃什么润肠通便| mm是什么单位| uu是什么意思| 赛能是什么药| 男人阳萎吃什么药最好| 铲子是什么意思| 7月13号是什么星座| 才高八斗什么生肖| 炮烙之刑是什么意思| 超市是什么意思| 动脉硬化有什么危害| 回盲部憩室是什么意思| 跳楼是什么感觉| 麻油跟香油什么区别| 21三体综合征是指什么| 羊和什么生肖最配| 左腹部疼是什么原因| 榴莲不能与什么食物一起吃| 5月3日什么星座| 鹿茸和什么泡酒壮阳| 77属什么生肖| 抗核抗体谱检测查什么的| 星辰大海什么意思| 二月十号是什么星座| 什么不及什么| 为什么会感染幽门螺杆菌| 苦荞茶喝了有什么好处| 眼睛飞蚊症吃什么药| 壮阳吃什么药| 左前支阻滞吃什么药| 1953属什么生肖| 澳门是什么时候被葡萄牙占领的| 八0年属什么生肖| 关心则乱是什么意思| 下海的意思是什么| 江字五行属什么| 雾化器是干什么用的| 吃完香蕉不能吃什么| superstar是什么意思| 理想型是什么意思| 失眠吃什么中药调理效果快| 鸭子什么时候下蛋| 夏天有什么花开| 胸口中间疼挂什么科| 胃寒是什么原因引起的| 今年的属相是什么生肖| 工伤是什么意思| 梦见杀鸡是什么意思| 蓝莓和什么不能一起吃| 什么是富氢水| 嘴唇上火起泡是什么原因| 圆脸适合剪什么发型| 总打喷嚏是什么原因| 心颤是什么症状| 右肩膀疼痛是什么原因| 月经一直不干净是什么原因引起的| 一饿就胃疼什么原因| 浙江属于什么方向| 拉红尿是什么原因| 名媛什么意思| 肠绞痛什么原因引起的| 酉是什么生肖| 什么的歌| 甜菜碱是什么东西| 泌尿系感染吃什么药| ella是什么意思| 4月12号是什么星座| 什么是外包| 过敏打什么针| 大学生村官是什么编制| 老是拉肚子什么原因| 骨密度z值是什么意思| 后背刺痛什么原因引起的| 将军是什么生肖| 长期抽烟清肺喝什么茶| 倍感欣慰是什么意思| 淋巴炎吃什么药| 糯米粉做什么好吃| 茶颜悦色什么好喝| 小孩流鼻血什么原因| 一什么羊| 肾小球有什么作用| 什么叫三观不正| 沙门氏菌用什么药最好| 硬伤是什么意思| 梦见过生日是什么意思| 腰酸是什么病的前兆| 阴虱是什么原因引起的| 为什么会肾虚| 知青为什么要下乡| 丹毒用什么药膏| 甲状腺结节吃什么药| 肿大淋巴结是什么意思| 咽炎有什么症状| molly什么意思| 脑白质脱髓鞘吃什么药| 护照办理需要什么材料| 香精是什么东西| 面面俱到是什么意思| 男人说冷静一段时间是什么意思| 天文是什么意思| 查血脂挂什么科| 感冒挂号挂什么科| 水瓶座的幸运色是什么| 唾液臭是什么原因| 太阳是什么星| 茱萸是什么东西| 脾肾两虚吃什么中成药最好| 什么叫青光眼| 中性粒细胞是指什么| 神经性头痛吃什么药| 什么是精神出轨| 张什么舞什么| 阴阳两虚吃什么药最好| 高血压和高血脂有什么区别| co是什么气体| 118是什么星座| in77是什么意思| 满月针最晚什么时候打| 什么什么有味| 干眼症是什么原因引起的| 肋骨下面是什么器官| 尿检能查出什么| 病毒疣是什么| 聘书是什么| 钾高是什么原因引起的| 湿气重吃什么好| 非洲割礼是什么| 王维是诗什么| 大悲咒什么意思| 百度

台當局擬整頓空氣污染 將提高汽柴油隨油徵...

百度 如果追溯此前一些新兴市场,比如视频行业、团购行业、网约车市场,都有过类似的现象。

A man page (short for manual page) is a form of software documentation found on Unix and Unix-like operating systems. Topics covered include programs, system libraries, system calls, and sometimes local system details. The local host administrators can create and install manual pages associated with the specific host. A manual end user may invoke a documentation page by issuing the man command followed by the name of the item for which they want the documentation. These manual pages are typically requested by end users, programmers and administrators doing real time work but can also be formatted for printing.

The man page for the sed utility, as seen in various Linux distributions.

By default, man typically uses a formatting program such as nroff with a macro package or mandoc, and also a terminal pager program such as more or less to display its output on the user's screen.

Man pages are often referred to as an online form of software documentation,[1] even though the man command does not require internet access. The environment variable MANPATH often specifies a list of directory paths to search for the various documentation pages. Manual pages date back to the times when printed documentation was the norm.

History

edit
 
xman, an early X11 application for viewing manual pages
 
OpenBSD section 8 intro man page, displaying in a text console

Before Unix (e.g., GCOS), documentation was printed pages, available on the premises to users (staff, students...), organized into steel binders, locked together in one monolithic steel reading rack, bolted to a table or counter, with pages organized for modular information updates, replacement, errata, and addenda. [citation needed]

In the first two years of the history of Unix, no documentation existed.[2] The Unix Programmer's Manual was first published on November 3, 1971. The first actual man pages were written by Dennis Ritchie and Ken Thompson at the insistence[citation needed] of their manager Doug McIlroy in 1971. Aside from the man pages, the Programmer's Manual also accumulated a set of short papers, some of them tutorials (e.g. for general Unix usage, the C programming language, and tools such as Yacc), and others more detailed descriptions of operating system features. The printed version of the manual initially fit into a single binder, but as of PWB/UNIX and the 7th Edition of Research Unix, it was split into two volumes with the printed man pages forming Volume 1.[3]

Later versions of the documentation imitated the first man pages' terseness. Ritchie added a "How to get started" section to the Third Edition introduction, and Lorinda Cherry provided the "Purple Card" pocket reference for the Sixth and Seventh Editions.[2] Versions of the software were named after the revision of the manual; the seventh edition of the Unix Programmer's Manual, for example, came with the 7th Edition or Version 7 of Unix.[4]

For the Fourth Edition the man pages were formatted using the troff typesetting package[2] and its set of -man macros (which were completely revised between the Sixth and Seventh Editions of the Manual,[3] but have since not drastically changed). At the time, the availability of online documentation through the manual page system was regarded as a great advance. To this day, virtually every Unix command line application comes with a man page, and many Unix users perceive a program's lack of man pages as a sign of low quality or incompleteness. Indeed, some projects, such as Debian, go out of their way to write man pages for programs lacking one. The modern descendants of 4.4BSD also distribute man pages as one of the primary forms of system documentation (having replaced the old -man macros with the newer -mdoc).

There was a hidden Easter egg in the man-db version of the man command that would cause the command to return "gimme gimme gimme" when run at 00:30 (a reference to the ABBA song Gimme! Gimme! Gimme! (A Man After Midnight). It was introduced in 2011[5] but first restricted[6] and then removed in 2017[7] after finally being found.[8]

Formatting

edit
 
Part of the FreeBSD man(1) manual page, typeset into PDF format

The default format of man pages is troff, with either the macro package man (appearance oriented) or mdoc (semantic oriented). This makes it possible to typeset a man page into PostScript, PDF, and various other formats for viewing or printing.

Some Unix systems have a package for the man2html command, which enables users to browse their man pages using an HTML browser. Systems with groff and man-db should use the higher-quality native HTML output (man --html) instead. The GNU Emacs program WoMan (from "WithOut man") allows to browse man pages from the editor.[9]

In 2010, OpenBSD deprecated troff for formatting man pages in favour of mandoc, a specialised compiler/formatter for man pages with native support for output in PostScript, HTML, XHTML, and the terminal. It is meant to only support a subset of troff used in manual pages, specifically those using mdoc macros.

Online services

edit

Quite a few websites offer online access to manual pages from various Unix-like systems.

In February 2013, the BSD community saw a new open source mdoc.su service launched, which unified and shortened access to the man.cgi scripts of the major modern BSD projects through a unique nginx-based deterministic URL shortening service for the *BSD man pages.[10][11][12]

For Linux, a man7.org service has been set up to serve manuals specific to the system.[13] A ManKier service provides a wider selection, and integrates the TLDR pages too.[14]

Command usage

edit

To read a manual page for a Unix command, a user can type:

man <command_name>

Pages are traditionally referred to using the notation "name(section)": for example, ftp(1). The section refers to different ways the topic might be referenced - for example, as a system call, or a shell (command line) command or package, or a package's configuration file, or as a coding construct / header.

The same page name may appear in more than one section of the manual, such as when the names of system calls, user commands, or macro packages coincide. Examples are man(1) and man(7), or exit(2) and exit(3). The syntax for accessing the non-default manual section varies between different man implementations.

On Solaris and illumos, for example, the syntax for reading printf(3C) is:

man -s 3c printf

On Linux and BSD derivatives the same invocation would be:

man 3 printf

which searches for printf in section 3 of the man pages. The actual file name likely includes the section. Continuing this example, printf.3.gz would be a compressed manual page file in section 3 for printf.

Manual sections

edit

The manual is generally split into eight numbered sections. Most systems today (e.g. BSD,[15] macOS, Linux,[16] and Solaris 11.4) inherit the numbering scheme used by Research Unix.[17][18] While System V uses a different order:[19]

Common System V Description
1 1 General commands
2 2 System calls
3 3 Library functions, covering in particular the C standard library
4 7 Special files (usually devices, those found in /dev) and drivers
5 4 File formats and conventions
6 6 Games and screensavers
7 5 Miscellaneous
8 1M System administration commands and daemons

POSIX APIs are present in both sections 2 and 3, where section 2 contains APIs that are implemented as system calls and section 3 contains APIs that are implemented as library routines.

On some systems, additional sections may be included such as:

Section Description
0 C library header files (Unix v6)
9 Kernel routines (FreeBSD, SVR4, Linux)[18][15]
l LAPACK library functions[20]
n Tcl/Tk commands
x The X Window System

Some sections are further subdivided by means of a suffix; for example, in some systems, section 3C is for C library calls, 3M is for the math library, and so on. A consequence of this is that section 8 (system administration commands) is sometimes relegated to the 1M subsection of the main commands section. Some subsection suffixes have a general meaning across sections:

Subsection Description
p POSIX specifications
x X Window System documentation

(Section 3 tends to be the exception with the many suffixes for different languages.)

Some versions of man cache the formatted versions of the last several pages viewed. One form is the cat page, simply piped to the pager for display.

Layout

edit

All man pages follow a common layout that is optimized for presentation on a simple ASCII text display, possibly without any form of highlighting or font control. Sections present may include:[21]:?MANUAL STRUCTURE?

NAME
The name of the command or function, followed by a one-line description of what it does.
SYNOPSIS
In the case of a command, a formal description of how to run it and what command line options it takes. For program functions, a list of the parameters the function takes and which header file contains its declaration.
DESCRIPTION
A textual description of the functioning of the command or function. For programs, this section often includes explanations of available command line options.
EXAMPLES
Some examples of common usage.
SEE ALSO
A list of related commands or functions.

Other sections may be present, but these are not well standardized across man pages. Common examples include: OPTIONS, EXIT STATUS, RETURN VALUE, ENVIRONMENT, BUGS, FILES, AUTHOR, REPORTING BUGS, HISTORY and COPYRIGHT.

Authoring

edit

Manual pages can be written either in the old man macros or the new doc macros.[22] The man macro set provides minimal rich text functions, with directives for the title line, section headers, (bold, small or italic) fonts, paragraphs and adding/reducing indentation.[23] The newer mdoc language is more semantic in nature, and contains specialized macros for most standard sections such as program name, synopsis, function names, and the name of the authors. This information can be used to implement a semantic search for manuals by programs such as mandoc. Although it also includes directives to directly control the styling, it is expected that the specialized macros will cover most of the use-cases.[21] Both the mandoc and the groff projects consider mdoc the preferred format for new documents.[24]

Although man pages are, to troff, text laid out using 10-point Roman type, this distinction is usually moot because man pages are viewed in the terminal (TTY) instead of laid out on paper. As a result, the "small font" macro is seldom used.[25] On the other hand, bold and italic text is supported by the terminal via ECMA-48, and groff's grotty does emit them as requested when it detects a supporting terminal. The BSD mandoc however only supports bold and underlined (as a replacement for italics) text via the typewriter backspace-then-overstrike sequence, which needs to be translated into ECMA-48 by less.[26][27]

Some tools have been used to convert documents in a less contrived format to manual pages. Examples include GNU's help2man, which takes a --help output and some additional content to generate a manual page.[28] The manual would be barely more useful than the said output, but for GNU programs this is not an issue as texinfo is the main documentation system.[29] A number of tools, including pandoc, ronn, and md2man support conversion from Markdown to manual pages. All these tools emit the man format, as Markdown is not expressive enough to match the semantic content of mdoc. DocBook has an inbuilt man(7) converter – of appalling quality, according to mandoc's author[30] who wrote a separate mdoc(7) converter.

Man pages are usually written in English, but translations into other languages may be available on the system. The GNU man-db and the mandoc man is known to search for localized manual pages under subdirectories.[31][16]:?Overview?[15]

Alternatives

edit

Few alternatives to man have enjoyed much popularity, with the possible exception of GNU Project's "info" system, an early and simple hypertext system. There is also a third-party effort known as TLDR pages (tldr) that provides simple examples for common use cases, similar to a cheatsheet.[32]

In addition, some Unix GUI applications (particularly those built using the GNOME and KDE development environments) now provide end-user documentation in HTML and include embedded HTML viewers such as yelp for reading the help within the application. An HTML system in Emacs is also slated to replace texinfo.[33]

See also

edit

References

edit
  1. ^ "man(1)". FreeBSD General Commands Manual. Archived from the original on 2025-08-06. Retrieved 2025-08-06.
  2. ^ a b c McIlroy, M. D. (1987). A Research Unix reader: annotated excerpts from the Programmer's Manual, 1971–1986 (PDF) (Technical report). CSTR. Bell Labs. 139. Archived (PDF) from the original on 2025-08-06. Retrieved 2025-08-06.
  3. ^ a b Darwin, Ian; Collyer, Geoffrey. "UNIX Evolution: 1975-1984 Part I - Diversity". Archived from the original on 17 July 2012. Retrieved 22 December 2012. Originally published in Microsystems 5(11), November 1984.
  4. ^ Fiedler, Ryan (October 1983). "The Unix Tutorial / Part 3: Unix in the Microcomputer Marketplace". BYTE. p. 132. Retrieved 30 January 2015.
  5. ^ "GIT commit 002a6339b1fe8f83f4808022a17e1aa379756d99". Archived from the original on 4 December 2017. Retrieved 22 November 2017.
  6. ^ "GIT commit 84bde8d8a9a357bd372793d25746ac6b49480525". Archived from the original on 5 September 2018. Retrieved 22 November 2017.
  7. ^ "GIT commit b225d9e76fbb0a6a4539c0992fba88c83f0bd37e". Archived from the original on 9 November 2020. Retrieved 25 September 2018.
  8. ^ ""Why does man print "gimme gimme gimme" at 00:30?"". Archived from the original on 21 November 2017. Retrieved 22 November 2017.
  9. ^ Wright, Francis J. "WoMan: Browse Unix Manual Pages "W.O. (without) Man"". GNU. Archived from the original on 11 November 2020. Retrieved 3 August 2020.
  10. ^ Pali, Gabor, ed. (12 May 2013). "FreeBSD Quarterly Status Report, January-March 2013". FreeBSD. Archived from the original on 22 December 2014. Retrieved 25 December 2014.
  11. ^ Murenin, Constantine A. (19 February 2013). "announcing mdoc.su, short manual page URLs". freebsd-doc@freebsd.org (Mailing list). Archived from the original on 7 August 2014. Retrieved 25 December 2014.
  12. ^ Murenin, Constantine A. (23 February 2013). "mdoc.su — Short manual page URLs for FreeBSD, OpenBSD, NetBSD and DragonFly BSD". Archived from the original on 17 December 2014. Retrieved 25 December 2014.
  13. ^ "Linux man pages online". man7.org. Archived from the original on 2025-08-06. Retrieved 2025-08-06.
  14. ^ "About". ManKier. Archived from the original on 2025-08-06. Retrieved 2025-08-06.
  15. ^ a b c man(1) – FreeBSD General Commands Manual
  16. ^ a b man(1) – Linux General Commands Manual
  17. ^ "Manual Pages for Research Unix Eighth Edition". man.cat-v.org. Archived from the original on 2025-08-06. Retrieved 2025-08-06.
  18. ^ a b "Unix Programmer's Manual - Introduction". www.bell-labs.com. November 3, 1971. Archived from the original on June 1, 2020. Retrieved May 6, 2020.
  19. ^ "System V release 4 manuals". bitsavers.trailing-edge.com. Archived from the original on 2025-08-06. Retrieved 2025-08-06.
  20. ^ "lapack (l) - Linux Man Pages". www.systutorials.com. Archived from the original on 2025-08-06. Retrieved 2025-08-06.
  21. ^ a b mdoc(7) – FreeBSD Miscellaneous Information Manual
  22. ^ groff_tmac(5) – Linux File Formats Manual
  23. ^ man(7) – Linux Miscellanea Manual
  24. ^ "Groff Mission Statement - 2014". www.gnu.org. Archived from the original on 2025-08-06. Retrieved 2025-08-06. Concurrent with work on man(7), mdoc(7) will be actively supported and its use promoted.
  25. ^ "man". The GNU Troff Manual. Archived from the original on 24 December 2019. Retrieved 31 December 2019.
  26. ^ "Italics and colour in manual pages on a nosh user-space virtual terminal". jdebp.eu. Archived from the original on 2025-08-06. Retrieved 2025-08-06.
  27. ^ mandoc(1) – FreeBSD General Commands Manual. "Font styles are applied by using back-spaced encoding..."
  28. ^ "help2man Reference Manual". Archived from the original on 6 March 2023. Retrieved 5 March 2023.
  29. ^ "Man Pages (GNU Coding Standards)". www.gnu.org. Archived from the original on 2025-08-06. Retrieved 2025-08-06.
  30. ^ Ingo Schwarze. "New mandoc -mdoc -T markdown converter". undeadly.org. Archived from the original on 2025-08-06. Retrieved 2025-08-06. – for specific complaints by the author, see Ingo Schwarze (28 February 2014). "Re: Groff man pages (tangential to Future Redux)". Groff (Mailing list). Archived from the original on 2025-08-06.
  31. ^ "command line - Linux man pages in different languages". Ask Ubuntu. Archived from the original on 2025-08-06. Retrieved 2025-08-06.
  32. ^ "TLDR pages". tldr.sh. Archived from the original on 2025-08-06. Retrieved 2025-08-06.
  33. ^ Raymond, Eric S. "Re: [Groff] man pages (tangential to Future Redux)". groff (Mailing list). Archived from the original on 2025-08-06. Retrieved 2025-08-06 – via lists.gnu.org.
edit
香菜什么时候种植最好 妇科检查白细胞酯酶阳性是什么意思 心律不齐吃什么食物好 口腔溃疡挂什么科 农历三月是什么月
甲亢吃什么好 4月28日是什么星座 洧是什么意思 hpv68阳性是什么意思 一什么瀑布
做爱什么感觉 副部长是什么级别 什么是兼职 家里停电打什么电话 小样是什么意思
tspot检查阳性能说明什么 荸荠读音是什么 小孩手麻是什么原因 诸葛亮姓什么 血小板低吃什么好补
宣府是现在的什么地方hcv7jop9ns3r.cn 女人胆固醇高什么原因hcv7jop9ns4r.cn 紫涵女装属于什么档次hcv8jop6ns0r.cn 儿童说话晚去医院挂什么科hcv7jop9ns3r.cn 毛主席什么时候去世的hcv9jop6ns6r.cn
插队是什么意思hcv9jop7ns1r.cn 组cp是什么意思helloaicloud.com 景色奇异的异是什么意思hcv9jop4ns6r.cn 鸟飞到头上什么预兆hcv8jop0ns3r.cn 膝盖跪着疼是什么原因hcv8jop2ns4r.cn
大便弱阳性是什么意思520myf.com 颈椎病去医院挂什么科hcv9jop5ns8r.cn 精炼植物油是什么油hcv8jop8ns0r.cn 大便粘便池是什么原因hcv9jop5ns1r.cn 身上出汗多是什么原因kuyehao.com
喉咙干咳吃什么药hcv8jop1ns4r.cn 舌苔厚腻吃什么药hcv8jop3ns5r.cn 胃切除手术后吃什么好hcv8jop7ns7r.cn 直肠炎用什么药效果最好liaochangning.com 什么是繁体字hcv8jop4ns5r.cn
百度