]> git.proxmox.com Git - pve-docs.git/blame - README.adoc
new file pve-docs-mediawiki-import.in
[pve-docs.git] / README.adoc
CommitLineData
22b0b166
DM
1Proxmox VE Documentation
2========================
8e6e6411 3include::attributes.txt[]
22b0b166 4
0c36e360 5We try to generate high quality documentation for
8ff3e5f7 6{website}[{pve}], and choose to use
a1ada598
DM
7http://www.methods.co.nz/asciidoc/[AsciiDoc] as base format.
8
0c36e360
DM
9The basic idea is to generate high quality manual pages, and assemble
10them into a complete book, called link:pve-admin-guide.adoc[Proxmox VE
a1ada598
DM
11Administration Guide]. So we have one source, and generate several
12documents from that. It is also possible to generate printable PDF
128b18c0 13files, or ebook formats ('.epub').
22b0b166 14
0c36e360
DM
15When possible, we provide scripts to extract API definitions,
16configuration or command line options from the source code.
17
18To simplify the documentation task, we keep all Documentation within
7aacca6f
DM
19this repository. It is possible to generate the docs without installing
20any additional Proxmox packages with:
0c36e360 21
8ace7110 22 make index
0c36e360 23
7aacca6f
DM
24To update the auto-generate API definitions use:
25
26 make update
27
28NOTE: you need a fully installed development environment for that.
29
8ace7110
DM
30
31Debian Packages
32---------------
33
34We generate a development package called 'pve-doc-generator', which is
35used by other Proxmox VE package to generate manual pages at package
36build time.
37
38Another package called 'pve-docs' is used to publish generated
39'.html' and '.pdf' files on our web servers. You can generate
9d17dbac 40those Debian packages using:
8ace7110
DM
41
42 make deb
0c36e360
DM
43
44
8e6e6411
DM
45Common Macro definition in link:attributes.txt[]
46------------------------------------------------
47
48'asciidoc' allows us to define common macros, which can then be
49referred to using `{macro}`. We try to use this mechanism to improve
50consistency. For example, we defined a macro called `pve`, which
8ff3e5f7
FG
51expands to "Proxmox VE".
52
53For URLs which are used more than once, two macros should be defined:
54
55* `{name-url}`, which just contains the http(s) URL
56* `{name}`, which contains the complete link including the canonical
57description
58
59For example, the macro `{forum-url}` expands to {forum-url}, and the macro
60`{forum}` expands to {forum}.
61
62The plan is to add more such definitions for terms which are used more than once.
63
64WARNING: When asciidoc encounters a misspelled macro name, it will silently drop
65the containing line!
66
67WARNING: Never use macros in document titles or the ``NAME'' section of man pages,
68as these get parsed before the `attributes.txt` file gets included.
8e6e6411 69
578a3111
DM
70Autogenerated CLI Command Synopsis
71----------------------------------
72
73We generate the command line synopsis for all manual pages
74automatically. We can do that, because we have a full declarative
75definition of the {pve} API. I added those generated files
76('*-synopsis.adoc') to the git repository, so that it is possible to
77build the documentation without having a fully installed {pve}
78development environment.
22b0b166 79
d067c2ad
FG
80Style Guide
81-----------
82
83'asciidoc' uses a fairly simple markup syntax for formatting content.
84The following basic principles should be followed throughout our
85documentation.
86
87
88Sections
89~~~~~~~~
90
91Sections are formatted using `two-line titles', by adding a line of
92the appropriate characters and of the same length as the section title
93below the title text:
94
95 Level 0 (top level): ======================
96 Level 1: ----------------------
97 Level 2: ~~~~~~~~~~~~~~~~~~~~~~
98 Level 3: ^^^^^^^^^^^^^^^^^^^^^^
99 Level 4 (bottom level): ++++++++++++++++++++++
100
9d17dbac 101Section titles should always be preceded by two empty lines. Each word
d067c2ad
FG
102in a title should be capitalized except for ``articles, coordinating
103conjunctions, prepositions, and the word to in infinitives unless they
104appear as the first or last word of a title'' (see
105http://web.mit.edu/course/21/21.guide/capitals.htm[Mayfield Electronic Handbook of Technical & Scientific Writing]).
106
107
108Lists
109~~~~~
110
111Numbered Lists
112^^^^^^^^^^^^^^
113
114Numbered lists should be created using the implicit numbering format:
115
116-----
117. First level
118.. Second level
119. First level again
120-----
121
122. First level
123.. Second level
124. First level again
125
126
127Bulleted Lists
128^^^^^^^^^^^^^^
129
130Bulleted lists should be created using the '*' symbol:
131
132-----
133* First level
134** Second level
135* First level again
136-----
137
138* First level
139** Second level
140* First level again
141
142
143Labeled Lists
144^^^^^^^^^^^^^
145
146Labeled lists should be used to make lists of key-value style text
9d17dbac 147more readable, such as command line parameters or configuration options:
d067c2ad
FG
148
149.Regular labeled lists
150-----
151First Label Text::
152
153Element text paragraph
154
155Second Label Text::
156
157Another element text paragraph.
158-----
159
160First Label Text::
161
162Element text paragraph
163
164Second Label Text::
165
166Another element text paragraph.
167
168.Horizontal labeled lists
169-----
170[horizontal]
171First Label Text:: Element text paragraph
172
173Second Label Text:: Another element text paragraph.
174-----
175
176creates
177
178[horizontal]
179First Label Text:: Element text paragraph
180
181Second Label Text:: Another element text paragraph.
182
183The FAQ section uses a special questions and answers style for
184labeled lists.
185
186
187Text and Block Styles
188~~~~~~~~~~~~~~~~~~~~~
189
190'asciidoc' offers a wide range of default text styles:
191
192* 'Emphasized text': created using \'text', used for emphasizing words
193and phrases
194* `Monospaced text`: created using \`text`, used for command / program
128b18c0 195names, file paths, in-line commands, option names and values
d067c2ad
FG
196* *Strong text*: created using \*text*, used for emphasizing concepts
197or names when first introduced in a section.
198
128b18c0 199There are also different built-in block styles that are used in
d067c2ad
FG
200our documentation:
201
202Complete paragraphs can be included literally by prepending each
203of their lines with whitespace. Use this for formatting complete
204commands on their own line, such as:
205
206 pct set ID -option value
207
208----
209By surrounding a paragraph with lines containing at least four '-'
210characters, its content is formatted as listing.
211
212Use this for formatting file contents or command output.
213----
214
215Specially highlighted 'notes', 'warnings' and 'important' information
216can be created by starting a paragraph with `NOTE:`, `WARNING:` or
217`IMPORTANT:`:
218
219NOTE: this is a note
220
221WARNING: this is warning
222
223IMPORTANT: this is important information
224
225For each of these blocks (including lists and paragraphs), a block header
226can be defined by prepending the block with a `.' character and the header
227text:
228
229-----
230.Title of List
231* First element
232* Second element
233* Third element
234-----
235
236.Title of List
237* First element
238* Second element
239* Third element
240
241For example, block headers can be used to add file names/paths to file
242content listings.
243
244
22b0b166
DM
245Copyright
246---------
247
40152dfd 248Copyright (C) 2016 Proxmox Server Solutions Gmbh
22b0b166
DM
249
250Permission is granted to copy, distribute and/or modify this document
251under the terms of the GNU Free Documentation License, Version 1.3 or
252any later version published by the Free Software Foundation; with no
f1e6bbae
DM
253Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A
254copy of the license is included in the link:LICENSE[LICENSE] file.