Package: asciidoc / 8.6.9-5

html_bottom_date_change.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
Author: Joseph Herlant <herlantj@gmail.com>
Description: This patch updates the behavior of the bottom text adding a footer-style
--- a/doc/asciidoc.txt
+++ b/doc/asciidoc.txt
@@ -5948,6 +5948,22 @@
 prior to the first document section. The document also needs to be
 dated to output this attribute.
 
+|footer-style |html4, html5, xhtml11 |
+Changes the "Last updated" field in the footer of the document or removes this
+field and the revision number (in the footer only). +
+Can take 3 values:
+
+- none : Don't display the "Last updated" and "Revision number" fields in the
+  footer of the document
+- revdate : The "Last updated" field's date in the footer will be the revision
+  date specified in the document (`revdate` attribute)
+- default (or any other value) : The "Last updated" field's date in the footer
+  will be the date of the input file modification
+
+This attribute can be set, for example, using `:footer-style: revdate` in the
+header of the file or using the `--attribute footer-style=revdate` command-line
+option.
+
 |scriptsdir |html5, xhtml11 |
 The name of the directory containing linked JavaScripts.
 See <<X35,HTML stylesheets and JavaScript locations>>.
--- a/html4.conf
+++ b/html4.conf
@@ -444,11 +444,14 @@
 |
 
 [footer]
+# Removing footer date and version if footer-style set to none
+ifeval::["{footer-style=default}"!="none"]
 <p></p>
 <p></p>
 <hr><p><small>
 template::[footer-text]
 </small></p>
+endif::[]
 </body>
 </html>
 
@@ -467,6 +470,16 @@
 template::[docinfo]
 </head>
 
+[footer-date]
+# Default footer date is document modification time
+ifeval::["{footer-style=default}"!="revdate"]
+ {docdate} {doctime}
+endif::[]
+# If set to "revdate", it'll be set to the revision date
+ifeval::["{footer-style=default}"=="revdate"]
+ {revdate}
+endif::[]
+
 #--------------------------------
 # article and book document types
 #--------------------------------
--- a/html5.conf
+++ b/html5.conf
@@ -662,9 +662,12 @@
 </div>
 {disable-javascript%<div id="footnotes"><hr></div>}
 <div id="footer">
+# Removing footer date and version if footer-style set to none
+ifeval::["{footer-style=default}"!="none"]
 <div id="footer-text">
 template::[footer-text]
 </div>
+endif::[]
 ifdef::badges[]
 <div id="footer-badges">
 ifndef::icons[]
@@ -688,6 +691,16 @@
 </body>
 </html>
 
+[footer-date]
+# Default footer date is document modification time
+ifeval::["{footer-style=default}"!="revdate"]
+ {docdate} {doctime}
+endif::[]
+# If set to "revdate", it'll be set to the revision date
+ifeval::["{footer-style=default}"=="revdate"]
+ {revdate}
+endif::[]
+
 ifdef::doctype-manpage[]
 [synopsis]
 template::[sect1]
--- a/lang-cs.conf
+++ b/lang-cs.conf
@@ -23,7 +23,8 @@
 
 [footer-text]
 Verze {revnumber}{basebackend-xhtml11?<br />}{basebackend-xhtml11=<br>}
-Poslední úprava {docdate} {doctime}
+Poslední úprava
+template::[footer-date]
 
 endif::basebackend-html[]
 
--- a/lang-de.conf
+++ b/lang-de.conf
@@ -29,7 +29,8 @@
 
 [footer-text]
 Version {revnumber}{basebackend-xhtml11?<br />}{basebackend-xhtml11=<br>}
-Letzte Änderung {docdate} {doctime}
+Letzte Änderung
+template::[footer-date]
 
 endif::basebackend-html[]
 
--- a/lang-el.conf
+++ b/lang-el.conf
@@ -23,7 +23,8 @@
 
 [footer-text]
 Έκδοση {revnumber}{basebackend-xhtml11?<br />}{basebackend-xhtml11=<br>}
-Τελευταία αναθεώρηση {docdate} {doctime}
+Τελευταία αναθεώρηση
+template::[footer-date]
 
 endif::basebackend-html[]
 
--- a/lang-en.conf
+++ b/lang-en.conf
@@ -22,7 +22,8 @@
 
 [footer-text]
 Version {revnumber}{basebackend-xhtml11?<br />}{basebackend-xhtml11=<br>}
-Last updated {docdate} {doctime}
+Last updated
+template::[footer-date]
 
 endif::basebackend-html[]
 
--- a/lang-es.conf
+++ b/lang-es.conf
@@ -25,7 +25,8 @@
 [footer-text]
 #TODO: Translation of 'Version' and 'Last updated'.
 Version {revnumber}{basebackend-xhtml11?<br />}{basebackend-xhtml11=<br>}
-Last updated {docdate} {doctime}
+Last updated
+template::[footer-date]
 
 endif::basebackend-html[]
 
--- a/lang-fr.conf
+++ b/lang-fr.conf
@@ -27,7 +27,8 @@
 
 [footer-text]
 Version {revnumber}{basebackend-xhtml11?<br />}{basebackend-xhtml11=<br>}
-Dernière mise à jour {docdate} {doctime}
+Dernière mise à jour
+template::[footer-date]
 
 endif::basebackend-html[]
 
--- a/lang-hu.conf
+++ b/lang-hu.conf
@@ -25,7 +25,8 @@
 
 [footer-text]
 Verzió {revnumber}{basebackend-xhtml11?<br />}{basebackend-xhtml11=<br>}
-Utolsó frissítés: {docdate} {doctime}
+Utolsó frissítés:
+template::[footer-date]
 
 endif::basebackend-html[]
 
--- a/lang-it.conf
+++ b/lang-it.conf
@@ -25,7 +25,8 @@
 [footer-text]
 #TODO: Translation of 'Version' and 'Last updated'.
 Version {revnumber}{basebackend-xhtml11?<br />}{basebackend-xhtml11=<br>}
-Last updated {docdate} {doctime}
+Last updated
+template::[footer-date]
 
 endif::basebackend-html[]
 
--- a/lang-nl.conf
+++ b/lang-nl.conf
@@ -29,7 +29,8 @@
 
 [footer-text]
 Versie {revnumber}{basebackend-xhtml11?<br />}{basebackend-xhtml11=<br>}
-Laatst bijgewerkt {docdate} {doctime}
+Laatst bijgewerkt
+template::[footer-date]
 
 endif::basebackend-html[]
 
--- a/lang-pt-BR.conf
+++ b/lang-pt-BR.conf
@@ -26,7 +26,8 @@
 [footer-text]
 #TODO: Translation of 'Version' and 'Last updated'.
 Version {revnumber}{basebackend-xhtml11?<br />}{basebackend-xhtml11=<br>}
-Last updated {docdate} {doctime}
+Last updated
+template::[footer-date]
 
 endif::basebackend-html[]
 
--- a/lang-ro.conf
+++ b/lang-ro.conf
@@ -27,7 +27,8 @@
 
 [footer-text]
 Versiunea {revnumber}{basebackend-xhtml11?<br />}{basebackend-xhtml11=<br>}
-Ultima actualizare {docdate} {doctime}
+Ultima actualizare
+template::[footer-date]
 
 endif::basebackend-html[]
 
--- a/lang-ru.conf
+++ b/lang-ru.conf
@@ -27,7 +27,8 @@
 
 [footer-text]
 Редакция {revnumber}{basebackend-xhtml11?<br />}{basebackend-xhtml11=<br>}
-Последнее обновление {docdate} {doctime}
+Последнее обновление
+template::[footer-date]
 
 endif::basebackend-html[]
 
--- a/lang-uk.conf
+++ b/lang-uk.conf
@@ -28,7 +28,8 @@
 [footer-text]
 #TODO: Translation of 'Version' and 'Last updated'.
 Version {revnumber}{basebackend-xhtml11?<br />}{basebackend-xhtml11=<br>}
-Last updated {docdate} {doctime}
+Last updated
+template::[footer-date]
 
 endif::basebackend-html[]
 
--- a/xhtml11.conf
+++ b/xhtml11.conf
@@ -657,9 +657,12 @@
 </div>
 {disable-javascript%<div id="footnotes"><hr /></div>}
 <div id="footer">
+# Removing footer date and version if footer-style set to none
+ifeval::["{footer-style=default}"!="none"]
 <div id="footer-text">
 template::[footer-text]
 </div>
+endif::[]
 ifdef::badges[]
 <div id="footer-badges">
 ifndef::icons[]
@@ -684,6 +687,16 @@
 </body>
 </html>
 
+[footer-date]
+# Default footer date is document modification time
+ifeval::["{footer-style=default}"!="revdate"]
+ {docdate} {doctime}
+endif::[]
+# If set to "revdate", it'll be set to the revision date
+ifeval::["{footer-style=default}"=="revdate"]
+ {revdate}
+endif::[]
+
 ifdef::doctype-manpage[]
 [synopsis]
 template::[sect1]