Date: Sat, 9 Jan 2021 17:06:32 GMT From: Fernando Apesteguía <fernape@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: df965a6829f0 - main - man(1): Add EXAMPLES section Message-ID: <202101091706.109H6Wks006946@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by fernape (ports committer): URL: https://cgit.FreeBSD.org/src/commit/?id=df965a6829f058b7a9999c39bc229616520645c2 commit df965a6829f058b7a9999c39bc229616520645c2 Author: Fernando Apesteguía <fernape@FreeBSD.org> AuthorDate: 2021-01-09 16:55:21 +0000 Commit: Fernando Apesteguía <fernape@FreeBSD.org> CommitDate: 2021-01-09 16:57:47 +0000 man(1): Add EXAMPLES section Add some examples showing the use of the flags: a, k, P, w Reviewed by: gbe@, yuripv@ Approved by: manpages (gbe@) Differential Revision: https://reviews.freebsd.org/D27545 --- usr.bin/man/man.1 | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/usr.bin/man/man.1 b/usr.bin/man/man.1 index 89bef50d718a..79821c405416 100644 --- a/usr.bin/man/man.1 +++ b/usr.bin/man/man.1 @@ -357,6 +357,41 @@ Local configuration files. .El .Sh EXIT STATUS .Ex -std +.Sh EXAMPLES +Show the manual page for +.Xr stat 2 : +.Bd -literal -offset indent +$ man 2 stat +.Ed +.Pp +Show all manual pages for +.Ql stat . +.Bd -literal -offset indent +$ man -a stat +.Ed +.Pp +List manual pages which match the regular expression either in the title or in +the body: +.Bd -literal -offset indent +$ man -k '\e<copy\e>.*archive' +.Ed +.Pp +Show the manual page for +.Xr ls 1 +and use +.Xr cat 1 +as pager: +.Bd -literal -offset indent +$ man -P cat ls +.Ed +.Pp +Show the location of the +.Xr ls 1 +manual page: +.Bd -literal -offset indent +$ man -w ls +.Ed +.Pp .Sh SEE ALSO .Xr apropos 1 , .Xr intro 1 ,
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202101091706.109H6Wks006946>