doc/man/asciidoc.conf: add doctype-manpage conditions
[lttng-tools.git] / doc / man / asciidoc.conf
1 [macros]
2
3 # man macro
4 #
5 # Inspired by linkgit macro:
6 # <https://github.com/git/git/blob/master/Documentation/asciidoc.conf>
7 #
8 # Usage: man:command(manpage-section)
9 (?su)[\\]?(?P<name>man):(?P<target>\S*?)\((?P<attrlist>.*?)\)=
10
11 # linkgenoptions macro
12 #
13 # Usage: linkgenoptions:(text)
14 (?su)[\\]?(?P<name>linkgenoptions):\((?P<text>.*?)\)=
15
16 # no link option macro
17 #
18 # Usage: nloption:--option-name
19 (?su)[\\]?(?P<name>nloption):(?P<opt>--?[a-zA-Z0-9-]*)=
20
21 # lttng(1) general option macro
22 #
23 # Usage: genoption:--option-name
24 (?su)[\\]?(?P<name>genoption):(?P<opt>--?[a-zA-Z0-9-]*)=
25
26 # option macro
27 #
28 # Usage: option:--option-name
29 (?su)[\\]?(?P<name>option):(?P<opt>--?[a-zA-Z0-9-]*)=
30
31 # not macro
32 #
33 # Usage: :not:
34 :not:=not
35
36 # escwc macro
37 #
38 # Usage: :escwc:
39 :escwc:=escwc
40
41 # man macro expansions
42 ifdef::doctype-manpage[]
43 ifdef::backend-docbook[]
44 [man-inlinemacro]
45 {0%{target}}
46 {0#<citerefentry>}
47 {0#<refentrytitle>{target}</refentrytitle><manvolnum>{0}</manvolnum>}
48 {0#</citerefentry>}
49 endif::backend-docbook[]
50 endif::doctype-manpage[]
51
52 # linkgenoptions macro expansions
53 ifdef::doctype-manpage[]
54 ifdef::backend-docbook[]
55 [linkgenoptions-inlinemacro]
56 {text}
57 endif::backend-docbook[]
58 endif::doctype-manpage[]
59
60 # option macro expansions
61 ifdef::doctype-manpage[]
62 ifdef::backend-docbook[]
63 [option-inlinemacro]
64 <literal>{opt}</literal>
65 endif::backend-docbook[]
66 endif::doctype-manpage[]
67
68 # no link option macro expansions
69 ifdef::doctype-manpage[]
70 ifdef::backend-docbook[]
71 [nloption-inlinemacro]
72 <literal>{opt}</literal>
73 endif::backend-docbook[]
74 endif::doctype-manpage[]
75
76 # lttng(1) general option macro expansions
77 ifdef::doctype-manpage[]
78 ifdef::backend-docbook[]
79 [genoption-inlinemacro]
80 <literal>{opt}</literal>
81 endif::backend-docbook[]
82 endif::doctype-manpage[]
83
84 # not macro expansions
85 ifdef::doctype-manpage[]
86 ifdef::backend-docbook[]
87 [not-inlinemacro]
88 NOT
89 endif::backend-docbook[]
90 endif::doctype-manpage[]
91
92 # escwc macro expansions
93 ifdef::doctype-manpage[]
94 ifdef::backend-docbook[]
95 [escwc-inlinemacro]
96 <literal>\e*</literal>
97 endif::backend-docbook[]
98 endif::doctype-manpage[]
99
100 # configure XML man page header
101 ifdef::doctype-manpage[]
102 ifdef::backend-docbook[]
103 [header]
104 template::[header-declarations]
105 <refentry>
106 <refmeta>
107 <refentrytitle>{mantitle}</refentrytitle>
108 <manvolnum>{manvolnum}</manvolnum>
109 <refmiscinfo class="source">LTTng</refmiscinfo>
110 <refmiscinfo class="version">{lttng_version}</refmiscinfo>
111 <refmiscinfo class="manual">LTTng Manual</refmiscinfo>
112 </refmeta>
113 <refnamediv>
114 <refname>{manname}</refname>
115 <refpurpose>{manpurpose}</refpurpose>
116 </refnamediv>
117 endif::backend-docbook[]
118 endif::doctype-manpage[]
This page took 0.045997 seconds and 4 git commands to generate.