Gentoo Archives: gentoo-project

From: "Michał Górny" <mgorny@g.o>
To: gentoo-project@l.g.o
Cc: "Michał Górny" <mgorny@g.o>
Subject: [gentoo-project] [PATCH 16/18] glep-0002: Revert to ReST version
Date: Thu, 14 Sep 2017 19:05:07
Message-Id: 20170914190326.12168-17-mgorny@gentoo.org
In Reply to: [gentoo-project] [RFC] GLEP 1/2 updates for the new old-school GLEP workflow by "Michał Górny"
1 ---
2 glep-0002.txt | 602 +++++++++++++++++++++++++++++++++++++++++++++-------------
3 1 file changed, 468 insertions(+), 134 deletions(-)
4
5 diff --git a/glep-0002.txt b/glep-0002.txt
6 index 0d3aec7..06a1964 100644
7 --- a/glep-0002.txt
8 +++ b/glep-0002.txt
9 @@ -1,172 +1,358 @@
10 GLEP: 2
11 -Title: Sample Wiki Markup GLEP Template
12 +Title: Sample ReStructuredText GLEP Template
13 Version: $Revision$
14 Last-Modified: $Date$
15 -Author: Grant Goodyear <g2boojum@g.o>, Chris Reffett <creffett@g.o>
16 +Author: Grant Goodyear <g2boojum@g.o>,
17 Status: Active
18 Type: Informational
19 -Content-Type: text/x-wiki
20 +Content-Type: text/x-rst
21 Created: 31 May 2003
22 Post-History: 2-Jun-2003, 17-Dec-2013
23
24 -==Credits==
25
26 -The text of this GLEP was, to a significant extent, stolen from Python's <ref name="python">http://www.python.org</ref> PEP-0012 <ref name="pep12"> http://www.python.org/peps/pep-0012.html</ref> by David Goodger and Barry A. Warsaw.
27 +Credits
28 +=======
29
30 -Note: if you are reading this GLEP via the web, you should first grab the text (Wiki Markup) source of this GLEP in order to complete the steps below. '''DO NOT USE THE HTML FILE AS YOUR TEMPLATE!'''
31 +The text of this GLEP was, to a significant extent, stolen from Python's
32 +[#PYTHON]_ PEP-0012 [#PEP12]_ by David Goodger and Barry A. Warsaw.
33
34 -To get the source of this (or any) GLEP, look at the top of the page and click on the link titled "View source".
35
36 -==Abstract==
37 +Abstract
38 +========
39
40 -This GLEP provides a boilerplate or sample template for creating your own Wiki text GLEPs. In conjunction with the content guidelines in GLEP 1 <ref name="glep1">GLEP 1, GLEP Purpose and Guidelines, Goodyear, (http://wiki.gentoo.org/index.php?title=GLEP:1)</ref>, this should make it easy for you to conform your own GLEPs to the format outlined below.
41 +This GLEP provides a boilerplate or sample template for creating your own
42 +reStructuredText GLEPs. In conjunction with the content guidelines in GLEP 1
43 +[#GLEP1]_, this should make it easy for you to conform your own GLEPs to the
44 +format outlined below.
45
46 -==Motivation==
47 +Note: if you are reading this GLEP via the web, you should first grab the text
48 +(reStructuredText) source of this GLEP in order to complete the steps below.
49 +**DO NOT USE THE HTML FILE AS YOUR TEMPLATE!**
50
51 -Provide adequate motivation here. In this particular case, we need to provide people with the information necessary to submit GLEPs in the proper form.
52 +To get the source of this (or any) GLEP, look at the top of the HTML page and
53 +click on the link titled "GLEP Source".
54
55 -==Rationale==
56 +Motivation
57 +==========
58
59 -GLEP submissions come in a wide variety of forms, not all adhering to the format guidelines set forth below. Use this template, in conjunction with the format guidelines below, to ensure that your GLEP submission won't get automatically rejected because of form.
60 +Provide adequate motivation here. In this particular case, we need to provide
61 +people with the information necessary to submit GLEPs in the proper form.
62
63 -Wiki Markup is used to allow GLEP authors more functionality and expressivity, while maintaining easy readability in the source text. The format makes the functionality accessible to readers: live hyperlinks, styled text, tables, images, and automatic tables of contents, among other advantages.
64 +Rationale
65 +=========
66
67 -==Backwards Compatibility==
68 +GLEP submissions come in a wide variety of forms, not all adhering to the
69 +format guidelines set forth below. Use this template, in conjunction with the
70 +format guidelines below, to ensure that your GLEP submission won't get
71 +automatically rejected because of form.
72
73 -Not a problem for this GLEP. This section should be included even when it is only to state that there are no backwards compatibility issues.
74 +ReStructuredText is used to allow GLEP authors more functionality and
75 +expressivity, while maintaining easy readability in the source text. The
76 +processed HTML form makes the functionality accessible to readers: live
77 +hyperlinks, styled text, tables, images, and automatic tables of contents,
78 +among other advantages.
79
80 -==How to Use This Template==
81
82 -To use this template you must first decide whether your GLEP is going to be an Informational or Standards Track GLEP. Most GLEPs are Standards Track because they propose new functionality for some aspect of Gentoo Linux. When in doubt, read GLEP 1 for details or contact the GLEP editors <glep@g.o>.
83 -Once you've decided which type of GLEP yours is going to be, follow the directions below.
84 +Backwards Compatibility
85 +=======================
86
87 -* Make a copy of the source as described under "Abstract" and perform the following edits.
88 +Not a problem for this GLEP. This section should be included *even* when it
89 +is only to state that there are no backwards compatibility issues.
90
91 -* Replace the "GLEP: 2" header with "GLEP: XXX" since you don't yet have a GLEP number assignment.
92
93 -* Change the Title header to the title of your GLEP.
94 +How to Use This Template
95 +========================
96
97 -* Leave the Version header alone; we'll take care of those when we add your GLEP to the wiki.
98 +To use this template you must first decide whether your GLEP is going to be an
99 +Informational or Standards Track GLEP. Most GLEPs are Standards Track because
100 +they propose new functionality for some aspect of Gentoo Linux. When in
101 +doubt, read GLEP 1 for details or contact the GLEP editors <glep@g.o>.
102
103 -* Change the Author header to include your name, and optionally your email address. Be sure to follow the format carefully: your name must appear first, and it must not be contained in parentheses. Your email address may appear second (or it can be omitted) and if it appears, it must appear in angle brackets.
104 +Once you've decided which type of GLEP yours is going to be, follow the
105 +directions below.
106
107 -* If there is a forum thread or a mailing list for discussion of your new feature, add a Discussions-To header right after the Author header. You should not add a Discussions-To header if the mailing list to be used is gentoo-dev@g.o, or if discussions should be sent to you directly. Most Informational GLEPs don't have a Discussions-To header.
108 +- Make a copy of this file (``.txt`` file, **not** HTML!) and perform
109 + the following edits.
110
111 -* Change the Status header to "Draft".
112 +- Replace the "GLEP: 2" header with "GLEP: XXX" since you don't yet have
113 + a GLEP number assignment.
114
115 -* For Standards Track GLEPs, change the Type header to "Standards Track".
116 +- Change the Title header to the title of your GLEP.
117
118 -* For Informational GLEPs, change the Type header to "Informational".
119 +- Leave the Version and Last-Modified headers alone; we'll take care
120 + of those when we check your GLEP into CVS.
121
122 -* For Standards Track GLEPs, if your feature depends on the acceptance of some other currently in-development GLEP, add a Requires header right after the Type header. The value should be the GLEP number of the GLEP yours depends on. Don't add this header if your dependent feature is described in a Final GLEP.
123 +- Change the Author header to include your name, and optionally your
124 + email address. Be sure to follow the format carefully: your name must
125 + appear first, and it must not be contained in parentheses. Your email
126 + address may appear second (or it can be omitted) and if it appears, it must
127 + appear in angle brackets. Your e-mail address
128 + here will e automatically obfuscated.
129
130 -* Change the Created header to today's date. Be sure to follow the format carefully: it must be in dd-mmm-yyyy format, where the mmm is the 3 English letter month abbreviation, i.e. one of Jan, Feb, Mar, Apr, May, Jun, Jul, Aug, Sep, Oct, Nov, Dec.
131 +- If there is a forum thread or a mailing list for discussion
132 + of your new feature, add a Discussions-To header right after the Author
133 + header. You should not add a Discussions-To header if the mailing list to
134 + be used is gentoo-dev@g.o, or if discussions should be sent to you
135 + directly. Most Informational GLEPs don't have a Discussions-To header.
136
137 -* Leave Post-History alone for now; you'll add dates to this header each time you post your GLEP to gentoo-dev@g.o. If you posted your GLEP to the list on August 14, 2003 and September 3, 2003, the Post-History header would look like:
138 +- Change the Status header to "Draft".
139
140 - Post-History: 14-Aug-2003, 03-Sept-2003
141 +- For Standards Track GLEPs, change the Type header to "Standards
142 + Track".
143
144 -You must manually add new dates and check them in. If you don't have check-in privileges, send your changes to the GLEP editors.
145 +- For Informational GLEPs, change the Type header to "Informational".
146
147 -* Add a Replaces header if your GLEP obsoletes an earlier GLEP. The value of this header is the number of the GLEP that your new GLEP is replacing. Only add this header if the older GLEP is in "final" form, i.e. is either Accepted, Final, or Rejected. You aren't replacing an older open GLEP if you're submitting a competing idea.
148 -* Now write your Abstract, Rationale, and other content for your GLEP, replacing all of this gobbledygook with your own text. Be sure to adhere to the format guidelines below, specifically on the indentation requirements.
149 -* Update your References section. You should leave the Copyright section as-is, since all new GLEPs are to be licensed under the Creative Commons Attribution-ShareAlike License, Version 3.0.
150 -* Send your GLEP submission to the GLEP editors at glep@g.o.
151 +- For Standards Track GLEPs, if your feature depends on the acceptance
152 + of some other currently in-development GLEP, add a Requires header right
153 + after the Type header. The value should be the GLEP number of the GLEP
154 + yours depends on. Don't add this header if your dependent feature is
155 + described in a Final GLEP.
156
157 -==Wiki Markup GLEP Formatting Requirements==
158 +- Change the Created header to today's date. Be sure to follow the
159 + format carefully: it must be in ``dd-mmm-yyyy`` format, where the ``mmm`` is
160 + the 3 English letter month abbreviation, i.e. one of Jan, Feb, Mar, Apr,
161 + May, Jun, Jul, Aug, Sep, Oct, Nov, Dec.
162
163 -The following is a GLEP-specific summary of Wiki Markup syntax. For the sake of simplicity and brevity, much detail is omitted. For more detail, see [[#Resources|Resources]] below. <nowiki><nowiki></nowiki> blocks (in which no markup processing is done) are used for examples throughout, to illustrate the plaintext markup.
164 +- Leave Post-History alone for now; you'll add dates to this header
165 + each time you post your GLEP to gentoo-dev@g.o. If you posted your
166 + GLEP to the list on August 14, 2003 and September 3, 2003, the Post-History
167 + header would look like::
168
169 -===General===
170 + Post-History: 14-Aug-2003, 03-Sept-2003
171
172 -You must adhere to the convention of adding two spaces at the end of every sentence. There are no longer line length restrictions when creating GLEPs.
173 + You must manually add new dates and check them in. If you don't have
174 + check-in privileges, send your changes to the GLEP editors.
175
176 -===Section Headings===
177 +- Add a Replaces header if your GLEP obsoletes an earlier GLEP. The
178 + value of this header is the number of the GLEP that your new GLEP is
179 + replacing. Only add this header if the older GLEP is in "final" form, i.e.
180 + is either Accepted, Final, or Rejected. You aren't replacing an older open
181 + GLEP if you're submitting a competing idea.
182
183 -GLEP headings must begin in column zero and the initial letter of each word must be capitalized as in book titles. Acronyms should be in all capitals. Section titles must be properly marked as such using the "=" (equals sign) character, with the number of equals corresponding to the level of the heading plus one, so two equals signs on each side for a first-level title, three on each side for a second-level title, and so on up to five levels. For example:
184 -<pre>
185 -==First-Level Title==
186 -===Second-Level Title===
187 -====Third-Level Title====
188 -</pre>
189 -You shouldn't have more than five levels of sections in your GLEP. If you do, you should consider rewriting it.
190 +- Now write your Abstract, Rationale, and other content for your GLEP,
191 + replacing all of this gobbledygook with your own text. Be sure to adhere to
192 + the format guidelines below, specifically on the indentation requirements.
193
194 -You must use two blank lines between the last line of a section's body and the next section heading. If a subsection heading immediately follows a section heading, a single blank line in-between is sufficient.
195 +- Update your References and Copyright section. Usually you'll place
196 + your GLEP into the public domain, in which case just leave the Copyright
197 + section alone. Alternatively, you can use the `Open Publication License`__,
198 + but public domain is still strongly preferred.
199
200 -The body of each section is not normally indented, although some constructs do use indentation, as described below. Blank lines are used to separate constructs.
201 + __ http://www.opencontent.org/openpub/
202
203 -===Paragraphs===
204 +- Send your GLEP submission to the GLEP editors at glep@g.o.
205
206 -Paragraphs are left-aligned text blocks separated by blank lines. Paragraphs are not indented unless they are part of an indented construct (such as a block quote or a list item). Wiki Markup formatting interprets newlines in a specific way. A single newline is treated as formatting and so there is no line inserted into the displayed product, but two newlines is interpreted as a line break and inserts a newline into the final product. For example,
207 -this does not display a line break, but
208
209 -this has two newlines and therefore does.
210 +ReStructuredText GLEP Formatting Requirements
211 +=============================================
212
213 -===Inline Markup===
214 +The following is a GLEP-specific summary of reStructuredText syntax. For the
215 +sake of simplicity and brevity, much detail is omitted. For more detail, see
216 +`Resources`_ below. `Literal blocks`_ (in which no markup processing is done)
217 +are used for examples throughout, to illustrate the plaintext markup.
218
219 -Portions of text within paragraphs and other text blocks may be styled. For example:
220
221 -Text may be marked as ''emphasized'' (double apostrophe markup, typically shown in italics) or '''strongly emphasized''' (triple apostrophes, typically boldface). Preformatted sections (set off using <nowiki><pre></nowiki> tags) are typically rendered in a monospaced typeface. No further markup recognition is done within the tags, so they're safe for any kind of code snippets. Alternatively, if the snippet should not be set aside in a monospaced typeface, the <nowiki><nowiki></nowiki> tag may be used, but this strips line breaks and other whitespace.
222 +General
223 +-------
224
225 -===Block Quotes===
226 +You must adhere to the convention of adding two spaces at the end of every
227 +sentence. You should fill your paragraphs to column 70, but under no
228 +circumstances should your lines extend past column 79. If your code samples
229 +spill over column 79, you should rewrite them.
230
231 -Block quotes consist of indented body elements. For example:
232 +
233 +Section Headings
234 +----------------
235 +
236 +GLEP headings must begin in column zero and the initial letter of each word
237 +must be capitalized as in book titles. Acronyms should be in all capitals.
238 +Section titles must be adorned with an underline, a single repeated
239 +punctuation character, which begins in column zero and must extend at least as
240 +far as the right edge of the title text (4 characters minimum). First-level
241 +section titles are underlined with "=" (equals signs), second-level section
242 +titles with "-" (hyphens), and third-level section titles with "'" (single
243 +quotes or apostrophes). For example::
244 +
245 + First-Level Title
246 + =================
247 +
248 + Second-Level Title
249 + ------------------
250 +
251 + Third-Level Title
252 + '''''''''''''''''
253 +
254 +If there are more than three levels of sections in your GLEP, you may insert
255 +overline/underline-adorned titles for the first and second levels as follows::
256 +
257 + ============================
258 + First-Level Title (optional)
259 + ============================
260 +
261 + -----------------------------
262 + Second-Level Title (optional)
263 + -----------------------------
264 +
265 + Third-Level Title
266 + =================
267 +
268 + Fourth-Level Title
269 + ------------------
270 +
271 + Fifth-Level Title
272 + '''''''''''''''''
273 +
274 +You shouldn't have more than five levels of sections in your GLEP. If you do,
275 +you should consider rewriting it.
276 +
277 +You must use two blank lines between the last line of a section's body and the
278 +next section heading. If a subsection heading immediately follows a section
279 +heading, a single blank line in-between is sufficient.
280 +
281 +The body of each section is not normally indented, although some constructs do
282 +use indentation, as described below. Blank lines are used to separate
283 +constructs.
284 +
285 +
286 +Paragraphs
287 +----------
288 +
289 +Paragraphs are left-aligned text blocks separated by blank lines. Paragraphs
290 +are not indented unless they are part of an indented construct (such as a
291 +block quote or a list item).
292 +
293 +
294 +Inline Markup
295 +-------------
296 +
297 +Portions of text within paragraphs and other text blocks may be
298 +styled. For example::
299 +
300 + Text may be marked as *emphasized* (single asterisk markup,
301 + typically shown in italics) or **strongly emphasized** (double
302 + asterisks, typically boldface). ``Inline literals`` (using double
303 + backquotes) are typically rendered in a monospaced typeface. No
304 + further markup recognition is done within the double backquotes,
305 + so they're safe for any kind of code snippets.
306 +
307 +
308 +Block Quotes
309 +------------
310 +
311 +Block quotes consist of indented body elements. For example::
312
313 This is a paragraph.
314
315 This is a block quote.
316 +
317 A block quote may contain many paragraphs.
318
319 -Block quotes are used to quote extended passages from other sources. Block quotes may be nested inside other body elements. Use a 4-space tab per indent level. A contiguous block quote should not have extra spacing between lines; this causes the wiki to break them up into separate quotes.
320 +Block quotes are used to quote extended passages from other sources.
321 +Block quotes may be nested inside other body elements. Use a 4-space tab
322 +per indent level.
323 +
324 +
325 +Literal Blocks
326 +--------------
327 +
328 +..
329 + In the text below, double backquotes are used to denote inline
330 + literals. "``::``" is written so that the colons will appear in a
331 + monospaced font; the backquotes (``) are markup, not part of the
332 + text. See "Inline Markup" above.
333 +
334 + By the way, this is a comment, described in "Comments" below.
335 +
336 +Literal blocks are used for code samples or preformatted ASCII art. To
337 +indicate a literal block, preface the indented text block with
338 +"``::``" (two colons). The literal block continues until the end of
339 +the indentation. Indent the text block by a tab. For example::
340 +
341 + This is a typical paragraph. A literal block follows.
342 +
343 + ::
344 +
345 + for a in [5,4,3,2,1]: # this is program code, shown as-is
346 + print a
347 + print "it's..."
348 + # a literal block continues until the indentation ends
349 +
350 +The paragraph containing only "``::``" will be completely removed from
351 +the output; no empty paragraph will remain. "``::``" is also
352 +recognized at the end of any paragraph. If immediately preceded by
353 +whitespace, both colons will be removed from the output. When text
354 +immediately precedes the "``::``", *one* colon will be removed from
355 +the output, leaving only one colon visible (i.e., "``::``" will be
356 +replaced by "``:``"). For example, one colon will remain visible
357 +here::
358 +
359 + Paragraph::
360 +
361 + Literal block
362 +
363 +
364 +Lists
365 +-----
366 +
367 +Bullet list items begin with one of "-", "*", or "+" (hyphen,
368 +asterisk, or plus sign), followed by whitespace and the list item
369 +body. List item bodies must be left-aligned and indented relative to
370 +the bullet; the text immediately after the bullet determines the
371 +indentation. For example::
372 +
373 + This paragraph is followed by a list.
374
375 -===Literal Blocks===
376 + * This is the first bullet list item. The blank line above the
377 + first list item is required; blank lines between list items
378 + (such as below this paragraph) are optional.
379
380 -<!--
381 -In the text below, <pre> and <nowiki> tags are used to indicate to the markup parser that a tag should be displayed literally. Thus, <nowiki><pre></nowiki> and <nowiki><nowiki></nowiki> are displayed as <pre> and <nowiki> respectively. See "Inline Markup" above.
382 + * This is the first paragraph in the second item in the list.
383
384 -By the way, this is a comment, described in "Comments" below.
385 --->
386 -Literal blocks are used for code samples or preformatted ASCII art. To indicate a literal block, preface the text block with <nowiki><pre></nowiki>. The literal block continues until the <nowiki></pre></nowiki> block is reached. For example:
387 + This is the second paragraph in the second item in the list.
388 + The blank line above this paragraph is required. The left edge
389 + of this paragraph lines up with the paragraph above, both
390 + indented relative to the bullet.
391
392 -This is a typical paragraph. A literal block follows.
393 + - This is a sublist. The bullet lines up with the left edge of
394 + the text blocks above. A sublist is a new list so requires a
395 + blank line above and below.
396
397 -<pre>
398 -for a in [5,4,3,2,1]: # this is program code, shown as-is
399 - print a
400 -print "it's..."
401 -</pre>
402 + * This is the third item of the main list.
403
404 -===Lists===
405 + This paragraph is not part of the list.
406
407 -Bullet list items begin with "*" (asterisk) for a bulleted list followed by whitespace and the list item body. Sub-lists may be created by adding additional list symbols, so "**" would add a bullet for a sub-list, "***" would add a bullet for a sub-sub-list, and so on. For example:
408 +Enumerated (numbered) list items are similar, but use an enumerator
409 +instead of a bullet. Enumerators are numbers (1, 2, 3, ...), letters
410 +(A, B, C, ...; uppercase or lowercase), or Roman numerals (i, ii, iii,
411 +iv, ...; uppercase or lowercase), formatted with a period suffix
412 +("1.", "2."), parentheses ("(1)", "(2)"), or a right-parenthesis
413 +suffix ("1)", "2)"). For example::
414
415 -This paragraph is followed by a list.
416 + 1. As with bullet list items, the left edge of paragraphs must
417 + align.
418
419 -* This is the first bullet list item.
420 -* This is the first paragraph in the second item in the list. <br />This is the second paragraph in the second item in the list. In order to add extra paragraphs to a list item, add the <nowiki><br /></nowiki> tag before the second paragraph.
421 -** This is is a sublist.
422 -* This is the third item of the main list.
423 + 2. Each list item may contain multiple paragraphs, sublists, etc.
424
425 -This paragraph is not part of the list.
426 + This is the second paragraph of the second list item.
427
428 -Enumerated (numbered) list items are similar, but use the "#" symbol instead of the "*" symbol.
429 + a) Enumerated lists may be nested.
430 + b) Blank lines may be omitted between list items.
431
432 -# First entry of an enumerated list.
433 -# Each list item may contain multiple paragraphs, sublists, etc. <br />This is the second paragraph of the second list item.
434 -## Enumerated lists may be nested.
435 -## Keep in mind that you should not have extra newlines between list elements, since they must be in a contiguous group in order to be numbered properly
436 +Definition lists are written like this::
437
438 -Definition lists are written like this:
439 + what
440 + Definition lists associate a term with a definition.
441
442 -;what
443 -:Definition lists associate a term with a definition.
444 + how
445 + The term is a one-line phrase, and the definition is one
446 + or more paragraphs or body elements, indented relative to
447 + the term.
448
449 -;how
450 -:the term is a one-line phrase preceded by ; (a semicolon), and the definition is preceded by : (a colon).
451
452 -===Tables===
453 +Tables
454 +------
455
456 -Simple tables are easy and compact:
457 +Simple tables are easy and compact::
458
459 ===== ===== =======
460 A B A and B
461 @@ -179,7 +365,7 @@ Simple tables are easy and compact:
462
463 There must be at least two columns in a table (to differentiate from
464 section titles). Column spans use underlines of hyphens ("Inputs"
465 -spans the first two columns):
466 +spans the first two columns)::
467
468 ===== ===== ======
469 Inputs Output
470 @@ -208,75 +394,223 @@ consist of multiple lines. For example::
471 list (row 3, column 2).
472 ===== =========================
473
474 -===Hyperlinks===
475
476 -When referencing an external web page in the body of a GLEP, you should include the title of the page in the text, with either an inline hyperlink reference to the URL or a footnote reference (see [[#Footnotes|Footnotes]] below). Do not include the URL in the body text of the GLEP.
477 +Hyperlinks
478 +----------
479 +
480 +When referencing an external web page in the body of a GLEP, you should
481 +include the title of the page in the text, with either an inline
482 +hyperlink reference to the URL or a footnote reference (see
483 +`Footnotes`_ below). Do not include the URL in the body text of the
484 +GLEP.
485 +
486 +Hyperlink references use backquotes and a trailing underscore to mark
487 +up the reference text; backquotes are optional if the reference text
488 +is a single word. For example::
489 +
490 + In this paragraph, we refer to the `Python web site`_.
491 +
492 +An explicit target provides the URL. Put targets in a References
493 +section at the end of the GLEP, or immediately after the reference.
494 +Hyperlink targets begin with two periods and a space (the "explicit
495 +markup start"), followed by a leading underscore, the reference text,
496 +a colon, and the URL (absolute or relative)::
497 +
498 + .. _Python web site: http://www.python.org/
499 +
500 +The reference text and the target text must match (although the match
501 +is case-insensitive and ignores differences in whitespace). Note that
502 +the underscore trails the reference text but precedes the target text.
503 +If you think of the underscore as a right-pointing arrow, it points
504 +*away* from the reference and *toward* the target.
505 +
506 +The same mechanism can be used for internal references. Every unique
507 +section title implicitly defines an internal hyperlink target. We can
508 +make a link to the Abstract section like this::
509 +
510 + Here is a hyperlink reference to the `Abstract`_ section. The
511 + backquotes are optional since the reference text is a single word;
512 + we can also just write: Abstract_.
513 +
514 +Footnotes containing the URLs from external targets will be generated
515 +automatically at the end of the References section of the GLEP, along
516 +with footnote references linking the reference text to the footnotes.
517 +
518 +Text of the form "GLEP x" or "RFC x" (where "x" is a number) will be
519 +linked automatically to the appropriate URLs.
520 +
521 +
522 +Footnotes
523 +---------
524 +
525 +Footnote references consist of a left square bracket, a number, a
526 +right square bracket, and a trailing underscore::
527 +
528 + This sentence ends with a footnote reference [1]_.
529 +
530 +Whitespace must precede the footnote reference. Leave a space between
531 +the footnote reference and the preceding word.
532 +
533 +When referring to another GLEP, include the GLEP number in the body
534 +text, such as "GLEP 1". The title may optionally appear. Add a
535 +footnote reference following the title. For example::
536 +
537 + Refer to GLEP 1 [2]_ for more information.
538 +
539 +Add a footnote that includes the GLEP's title and author. It may
540 +optionally include the explicit URL on a separate line, but only in
541 +the References section. Footnotes begin with ".. " (the explicit
542 +markup start), followed by the footnote marker (no underscores),
543 +followed by the footnote body. For example::
544 +
545 + References
546 + ==========
547 +
548 + .. [2] GLEP 1, "GLEP Purpose and Guidelines", Goodyear, Warsaw, Hylton
549 + (http://glep.gentoo.org/glep-0001.html)
550 +
551 +If you decide to provide an explicit URL for a GLEP, please use this as
552 +the URL template::
553 +
554 + http://glep.gentoo.org/glep-xxxx.html
555 +
556 +GLEP numbers in URLs must be padded with zeros from the left, so as to
557 +be exactly 4 characters wide, however GLEP numbers in the text are
558 +never padded.
559 +
560 +During the course of developing your GLEP, you may have to add, remove,
561 +and rearrange footnote references, possibly resulting in mismatched
562 +references, obsolete footnotes, and confusion. Auto-numbered
563 +footnotes allow more freedom. Instead of a number, use a label of the
564 +form "#word", where "word" is a mnemonic consisting of alphanumerics
565 +plus internal hyphens, underscores, and periods (no whitespace or
566 +other characters are allowed). For example::
567 +
568 + Refer to GLEP 1 [#GLEP-1]_ for more information.
569 +
570 + References
571 + ==========
572 +
573 + .. [#GLEP-1] GLEP 1, "GLEP Purpose and Guidelines", Goodyear
574 + http://glep.gentoo.org/glep-0001.html
575 +
576 +Footnotes and footnote references will be numbered automatically, and
577 +the numbers will always match. Once a GLEP is finalized, auto-numbered
578 +labels should be replaced by numbers for simplicity.
579 +
580 +
581 +Images
582 +------
583 +
584 +If your GLEP contains a diagram, you may include it in the processed
585 +output using the "image" directive::
586 +
587 + .. image:: diagram.png
588 +
589 +Any browser-friendly graphics format is possible: .png, .jpeg, .gif,
590 +.tiff, etc.
591 +
592 +Since this image will not be visible to readers of the GLEP in source
593 +text form, you should consider including a description or ASCII art
594 +alternative, using a comment (below).
595 +
596 +
597 +Comments
598 +--------
599 +
600 +A comment block is an indented block of arbitrary text immediately
601 +following an explicit markup start: two periods and whitespace. Leave
602 +the ".." on a line by itself to ensure that the comment is not
603 +misinterpreted as another explicit markup construct. Comments are not
604 +visible in the processed document. For the benefit of those reading
605 +your GLEP in source form, please consider including a descriptions of
606 +or ASCII art alternatives to any images you include. For example::
607 +
608 + .. image:: dataflow.png
609 +
610 + ..
611 + Data flows from the input module, through the "black box"
612 + module, and finally into (and through) the output module.
613
614 -Hyperlink references can be accomplished using single brackets. These brackets should contain the link, a space, then the text to display for the hyperlink. For example:
615
616 -<pre>In this paragraph, we refer to the [http://www.python.org/ Python web site]</pre>
617
618 -There are certain limitations to embedding hyperlinks like this, mostly related to special characters requiring replacement. [http://en.wikipedia.org/wiki/Help:Wiki_markup#External_links Wikipedia] has a list of these special cases.
619 +Escaping Mechanism
620 +------------------
621
622 -A similar mechanism can be used for internal references or references within the wiki, although these use double brackets instead of single brackets and a vertical pipe to differentiate between the target and the display text. Every unique section title implicitly defines an internal hyperlink target. We can make a link to the Abstract section like this:
623 +reStructuredText uses backslashes ("``\``") to override the special
624 +meaning given to markup characters and get the literal characters
625 +themselves. To get a literal backslash, use an escaped backslash
626 +("``\\``"). There are two contexts in which backslashes have no
627 +special meaning: `literal blocks`_ and inline literals (see `Inline
628 +Markup`_ above). In these contexts, no markup recognition is done,
629 +and a single backslash represents a literal backslash, without having
630 +to double up.
631
632 -<pre>Here is a hyperlink reference to the [[#Abstract|Abstract]] section.</pre>
633 +If you find that you need to use a backslash in your text, consider
634 +using inline literals or a literal block instead.
635
636 -===Footnotes===
637
638 -<nowiki>
639 -The references section will be generated via the Mediawiki "Cite" extension. In order to add a refence, use <ref name="(name)">(Link/name of source)</ref>. Any subsequent references to the same source may use <ref name="(name)"/> to refer to the same source. All references should have a name associated with them. Under the References section, the tag <references/> should be used to output all of the references in a list. </nowiki>
640 +Habits to Avoid
641 +===============
642
643 -When referring to another GLEP, include the GLEP number in the body text, such as "GLEP 1". The title may optionally appear. Add a footnote reference following the title, which should include the title and author's name, and may optionally include an explicit URL. If you decide to provide an explicit URL for a GLEP, please use this as the URL template:
644 +Many programmers who are familiar with TeX often write quotation marks
645 +like this::
646
647 - http://wiki.gentoo.org/wiki/GLEP:xxxx.html <!--Subject to chance once we actually get the namespace -->
648 + `single-quoted' or ``double-quoted''
649
650 -A citation of GLEP 1 done like this might look like:
651 +Backquotes are significant in reStructuredText, so this practice
652 +should be avoided. For ordinary text, use ordinary 'single-quotes' or
653 +"double-quotes". For inline literal text (see `Inline Markup`_
654 +above), use double-backquotes::
655
656 -<pre>Refer to GLEP 1 for more information.<ref name="glep1">
657 -GLEP 1, GLEP Purpose and Guidelines, Goodyear, (http://wiki.gentoo.org/wiki/GLEP:0001.html)</ref></pre>
658 + ``literal text: in here, anything goes!``
659
660
661 -GLEP numbers in URLs must be padded with zeros from the left, so as to be exactly 4 characters wide, however GLEP numbers in the text are never padded.
662 +Resources
663 +=========
664
665 -Footnotes and footnote references will be numbered and inserted automatically, and the numbers will always match.
666 +Many other constructs and variations are possible. For more details
667 +about the reStructuredText markup, in increasing order of
668 +thoroughness, please see:
669
670 -===Images===
671 +* `A ReStructuredText Primer`__, a gentle introduction.
672
673 -If your GLEP contains a diagram, you first must upload it at the [[Special:Upload|upload page.] You may then include it in the processed
674 -output using a File: tag:
675 + __ http://docutils.sourceforge.net/docs/rst/quickstart.html
676
677 -<pre>[[File:diagram.png]]</pre>
678 +* `Quick reStructuredText`__, a users' quick reference.
679
680 -Any browser-friendly graphics format is possible: .png, .jpeg, .gif, .tiff, etc.
681 + __ http://docutils.sourceforge.net/docs/rst/quickref.html
682
683 -Since this image will not be visible to readers of the GLEP in source text form, you should consider including a description or ASCII art alternative, using a comment (below).
684 +* `reStructuredText Markup Specification`__, the final authority.
685
686 -===Comments===
687 + __ http://docutils.sourceforge.net/spec/rst/reStructuredText.html
688
689 -A comment block is a block of markup text that will not appear in the final page. It is delimited by <nowiki><!-- and --></nowiki>, and so looks like this:
690 +The processing of reStructuredText GLEPs is done using Docutils_. If
691 +you have a question or require assistance with reStructuredText or
692 +Docutils, please `post a message`_ to the `Docutils-Users mailing
693 +list`_. The `Docutils project web site`_ has more information.
694
695 - <pre><!--Here is a comment!--></pre>
696 +.. _Docutils: http://docutils.sourceforge.net/
697 +.. _post a message:
698 + mailto:docutils-users@×××××××××××××××××.net?subject=GLEPs
699 +.. _Docutils-Users mailing list:
700 + http://lists.sourceforge.net/lists/listinfo/docutils-users
701 +.. _Docutils project web site: http://docutils.sourceforge.net/
702
703 -Comments are not visible in the processed document. For the benefit of those reading your GLEP in source form, please consider including a descriptions of or ASCII art alternatives to any images you include. For example:
704
705 -<pre>
706 -[[File:dataflow.png]]
707 -<!--Data flows from the input module, through the "black box" module, and finally into (and through) the output module.-->
708 -</pre>
709 +References
710 +==========
711
712 -==Resources==
713 +.. [#PYTHON] http://www.python.org
714
715 -Wiki Markup has a large number of formatting options, this guide should only be considered to be a basic introduction. For more information, the following links may be useful:
716 +.. [#PEP12] http://www.python.org/peps/pep-0012.html
717
718 -* The Wikipedia Cheat Sheet, which is a quick reference for basic formatting. <ref name="wikicheatsheet">http://en.wikipedia.org/wiki/Wikipedia:Cheatsheet</ref>
719 -* The Wikipedia help page on Wiki Markup, which is much more in-depth and has many subpages for specific topics. <ref name="wikimarkupguide">http://en.wikipedia.org/wiki/Help:Wiki_markup</ref>
720 +.. [#GLEP1] GLEP 1, GLEP Purpose and Guidelines, Goodyear,
721 + (http://glep.gentoo.org/glep-0001.html)
722
723 -==References==
724
725 -This section should include a <nowiki><references /></nowiki> tag, which will automatically generate all footnotes from the above document.
726 -<references/>
727 +Copyright
728 +=========
729
730 -==Copyright==
731 +This document has been placed in the public domain.
732
733 -This work is licensed under the Creative Commons Attribution-ShareAlike 3.0 Unported License. To view a copy of this license, visit http://creativecommons.org/licenses/by-sa/3.0/.
734 --
735 2.14.1