rbcli 0.2.12 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (113) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +15 -0
  3. data/Gemfile.lock +39 -38
  4. data/docs-src/content/development/changelog.md +16 -1
  5. data/docs-src/themes/hugo-theme-learn/CHANGELOG.md +74 -2
  6. data/docs-src/themes/hugo-theme-learn/README.md +42 -5
  7. data/docs-src/themes/hugo-theme-learn/exampleSite/config.toml +27 -0
  8. data/docs-src/themes/hugo-theme-learn/exampleSite/content/basics/_index.zh.md +12 -0
  9. data/docs-src/themes/hugo-theme-learn/exampleSite/content/basics/configuration/_index.en.md +6 -4
  10. data/docs-src/themes/hugo-theme-learn/exampleSite/content/basics/configuration/_index.fr.md +7 -5
  11. data/docs-src/themes/hugo-theme-learn/exampleSite/content/basics/installation/_index.en.md +1 -1
  12. data/docs-src/themes/hugo-theme-learn/exampleSite/content/cont/markdown.en.md +88 -61
  13. data/docs-src/themes/hugo-theme-learn/exampleSite/content/cont/pages/_index.fr.md +3 -3
  14. data/docs-src/themes/hugo-theme-learn/exampleSite/content/cont/syntaxhighlight.en.md +89 -0
  15. data/docs-src/themes/hugo-theme-learn/exampleSite/content/shortcodes/children/_index.en.md +2 -2
  16. data/docs-src/themes/hugo-theme-learn/exampleSite/content/shortcodes/notice.en.md +2 -2
  17. data/docs-src/themes/hugo-theme-learn/exampleSite/content/showcase.en.md +4 -1
  18. data/docs-src/themes/hugo-theme-learn/exampleSite/content/showcase.fr.md +4 -1
  19. data/docs-src/themes/hugo-theme-learn/exampleSite/static/fonts/monogramos-webfont.svg +1 -237
  20. data/docs-src/themes/hugo-theme-learn/exampleSite/static/images/showcase/inteliver_docs.png +0 -0
  21. data/docs-src/themes/hugo-theme-learn/exampleSite/static/images/showcase/tshark_dev.png +0 -0
  22. data/docs-src/themes/hugo-theme-learn/i18n/ar.toml +26 -0
  23. data/docs-src/themes/hugo-theme-learn/i18n/de.toml +26 -0
  24. data/docs-src/themes/hugo-theme-learn/i18n/hi.toml +26 -0
  25. data/docs-src/themes/hugo-theme-learn/i18n/ja.toml +26 -0
  26. data/docs-src/themes/hugo-theme-learn/i18n/ru.toml +26 -0
  27. data/docs-src/themes/hugo-theme-learn/i18n/zh-cn.toml +26 -0
  28. data/docs-src/themes/hugo-theme-learn/layouts/_default/list.html +1 -1
  29. data/docs-src/themes/hugo-theme-learn/layouts/_default/single.html +1 -2
  30. data/docs-src/themes/hugo-theme-learn/layouts/partials/footer.html +3 -4
  31. data/docs-src/themes/hugo-theme-learn/layouts/partials/header.html +8 -6
  32. data/docs-src/themes/hugo-theme-learn/layouts/partials/menu.html +6 -5
  33. data/docs-src/themes/hugo-theme-learn/layouts/shortcodes/children.html +2 -2
  34. data/docs-src/themes/hugo-theme-learn/layouts/shortcodes/ref.html +1 -1
  35. data/docs-src/themes/hugo-theme-learn/layouts/shortcodes/relref.html +1 -1
  36. data/docs-src/themes/hugo-theme-learn/netlify.toml +1 -2
  37. data/docs-src/themes/hugo-theme-learn/static/css/theme.css +4 -0
  38. data/docs-src/themes/hugo-theme-learn/static/fonts/Inconsolata.svg +1 -359
  39. data/docs-src/themes/hugo-theme-learn/static/fonts/Novecentosanswide-Normal-webfont.svg +1 -1019
  40. data/docs-src/themes/hugo-theme-learn/static/fonts/Novecentosanswide-UltraLight-webfont.svg +1 -918
  41. data/docs-src/themes/hugo-theme-learn/static/fonts/Work_Sans_200.svg +1 -332
  42. data/docs-src/themes/hugo-theme-learn/static/fonts/Work_Sans_300.svg +1 -331
  43. data/docs-src/themes/hugo-theme-learn/static/fonts/Work_Sans_500.svg +1 -333
  44. data/docs-src/themes/hugo-theme-learn/static/images/clippy.svg +1 -1
  45. data/docs-src/themes/hugo-theme-learn/static/js/auto-complete.js +3 -223
  46. data/docs-src/themes/hugo-theme-learn/static/js/highlight.pack.js +6 -3
  47. data/docs-src/themes/hugo-theme-learn/static/js/hugo-learn.js +8 -5
  48. data/docs-src/themes/hugo-theme-learn/static/webfonts/fa-brands-400.svg +1 -1260
  49. data/docs-src/themes/hugo-theme-learn/static/webfonts/fa-regular-400.svg +1 -471
  50. data/docs-src/themes/hugo-theme-learn/static/webfonts/fa-solid-900.svg +1 -2763
  51. data/docs/404.html +8 -8
  52. data/docs/advanced/automatic_updates/index.html +85 -65
  53. data/docs/advanced/command_types/index.html +139 -144
  54. data/docs/advanced/distributed_state_locking/index.html +83 -55
  55. data/docs/advanced/hooks/index.html +94 -81
  56. data/docs/advanced/index.html +75 -34
  57. data/docs/advanced/index.xml +8 -8
  58. data/docs/advanced/interactive_commands/index.html +90 -66
  59. data/docs/advanced/logging/index.html +94 -67
  60. data/docs/advanced/remote_execution/index.html +94 -75
  61. data/docs/advanced/state_storage/index.html +122 -119
  62. data/docs/advanced/user_config_files/index.html +94 -71
  63. data/docs/categories/index.html +82 -30
  64. data/docs/categories/index.xml +1 -1
  65. data/docs/css/theme.css +4 -0
  66. data/docs/development/changelog/index.html +185 -177
  67. data/docs/development/code_of_conduct/index.html +85 -64
  68. data/docs/development/contributing/index.html +96 -96
  69. data/docs/development/index.html +75 -34
  70. data/docs/development/index.xml +2 -2
  71. data/docs/development/license/index.html +80 -46
  72. data/docs/fonts/Inconsolata.svg +1 -359
  73. data/docs/fonts/Novecentosanswide-Normal-webfont.svg +1 -1019
  74. data/docs/fonts/Novecentosanswide-UltraLight-webfont.svg +1 -918
  75. data/docs/fonts/Work_Sans_200.svg +1 -332
  76. data/docs/fonts/Work_Sans_300.svg +1 -331
  77. data/docs/fonts/Work_Sans_500.svg +1 -333
  78. data/docs/images/clippy.svg +1 -1
  79. data/docs/index.html +112 -61
  80. data/docs/index.json +24 -24
  81. data/docs/index.xml +13 -13
  82. data/docs/js/auto-complete.js +3 -223
  83. data/docs/js/highlight.pack.js +6 -3
  84. data/docs/js/hugo-learn.js +8 -5
  85. data/docs/quick_reference/index.html +126 -159
  86. data/docs/quick_reference/index.xml +1 -1
  87. data/docs/sitemap.xml +2 -4
  88. data/docs/tags/index.html +82 -30
  89. data/docs/tags/index.xml +1 -1
  90. data/docs/tutorial/10-getting_started/index.html +87 -66
  91. data/docs/tutorial/20-project_layout/index.html +126 -116
  92. data/docs/tutorial/30-your_first_command/index.html +151 -141
  93. data/docs/tutorial/40-options_parameters_and_arguments/index.html +233 -258
  94. data/docs/tutorial/50-publishing/index.html +86 -66
  95. data/docs/tutorial/index.html +75 -34
  96. data/docs/tutorial/index.xml +4 -4
  97. data/docs/webfonts/fa-brands-400.svg +1 -1260
  98. data/docs/webfonts/fa-regular-400.svg +1 -471
  99. data/docs/webfonts/fa-solid-900.svg +1 -2763
  100. data/docs/whoami/index.html +76 -46
  101. data/docs/whoami/index.xml +1 -1
  102. data/lib/rbcli/configuration/configurate_blocks/me.rb +5 -5
  103. data/lib/rbcli/util/deprecation_warning.rb +21 -4
  104. data/lib/rbcli/version.rb +1 -1
  105. data/rbcli.gemspec +8 -8
  106. data/skeletons/project/Gemfile +1 -1
  107. data/skeletons/project/config/general.rb +1 -1
  108. data/skeletons/project/lib/lib.erb +2 -0
  109. data/skeletons/project/spec/spec_helper.rb +7 -7
  110. data/skeletons/project/spec/untitled_spec.rb +6 -6
  111. data/skeletons/project/untitled.gemspec +28 -26
  112. metadata +29 -20
  113. data/docs-src/themes/hugo-theme-learn/static/js/html5shiv-printshiv.min.js +0 -4
@@ -15,7 +15,7 @@ hugo new site <new_project>
15
15
 
16
16
  ## Install the theme
17
17
 
18
- Install the **Hugo-theme-learn** theme by following [this documentation](https://gohugo.io/themes/installing/)
18
+ Install the **Hugo-theme-learn** theme by following [this documentation](https://gohugo.io/getting-started/quick-start/#step-3-add-a-theme)
19
19
 
20
20
  This theme's repository is: https://github.com/matcornic/hugo-theme-learn.git
21
21
 
@@ -25,8 +25,7 @@ Some of the key benefits are:
25
25
  John Gruber, the author of Markdown, puts it like this:
26
26
 
27
27
  > The overriding design goal for Markdown’s formatting syntax is to make it as readable as possible. The idea is that a Markdown-formatted document should be publishable as-is, as plain text, without looking like it’s been marked up with tags or formatting instructions. While Markdown’s syntax has been influenced by several existing text-to-HTML filters, the single biggest source of inspiration for Markdown’s syntax is the format of plain text email.
28
- > -- <cite>John Gruber</cite>
29
-
28
+ > -- John Gruber
30
29
 
31
30
  Grav ships with built-in support for [Markdown](http://daringfireball.net/projects/markdown/) and [Markdown Extra](https://michelf.ca/projects/php-markdown/extra/). You must enable **Markdown Extra** in your `system.yaml` configuration file
32
31
 
@@ -50,12 +49,18 @@ Headings from `h1` through `h6` are constructed with a `#` for each level:
50
49
  ```
51
50
 
52
51
  Renders to:
53
-
52
+ <!-- markdownlint-disable MD025 -->
54
53
  # h1 Heading
54
+ <!-- markdownlint-enable MD025 -->
55
+
55
56
  ## h2 Heading
57
+
56
58
  ### h3 Heading
59
+
57
60
  #### h4 Heading
61
+
58
62
  ##### h5 Heading
63
+
59
64
  ###### h6 Heading
60
65
 
61
66
  HTML:
@@ -78,13 +83,13 @@ Comments should be HTML compatible
78
83
  This is a comment
79
84
  -->
80
85
  ```
86
+
81
87
  Comment below should **NOT** be seen:
82
88
 
83
89
  <!--
84
90
  This is a comment
85
91
  -->
86
92
 
87
-
88
93
  ## Horizontal Rules
89
94
 
90
95
  The HTML `<hr>` element is for creating a "thematic break" between paragraph-level elements. In markdown, you can create a `<hr>` with any of the following:
@@ -97,11 +102,6 @@ renders to:
97
102
 
98
103
  ___
99
104
 
100
- ---
101
-
102
- ***
103
-
104
-
105
105
  ## Body Copy
106
106
 
107
107
  Body copy written as normal, plain text will be wrapped with `<p></p>` tags in the rendered HTML.
@@ -111,6 +111,7 @@ So this body copy:
111
111
  ```markdown
112
112
  Lorem ipsum dolor sit amet, graecis denique ei vel, at duo primis mandamus. Et legere ocurreret pri, animal tacimates complectitur ad cum. Cu eum inermis inimicus efficiendi. Labore officiis his ex, soluta officiis concludaturque ei qui, vide sensibus vim ad.
113
113
  ```
114
+
114
115
  renders to this HTML:
115
116
 
116
117
  ```html
@@ -120,6 +121,7 @@ renders to this HTML:
120
121
  ## Emphasis
121
122
 
122
123
  ### Bold
124
+
123
125
  For emphasizing a snippet of text with a heavier font-weight.
124
126
 
125
127
  The following snippet of text is **rendered as bold text**.
@@ -127,9 +129,12 @@ The following snippet of text is **rendered as bold text**.
127
129
  ```markdown
128
130
  **rendered as bold text**
129
131
  ```
132
+
130
133
  renders to:
131
134
 
135
+ <!-- markdownlint-disable MD036 -->
132
136
  **rendered as bold text**
137
+ <!-- markdownlint-enable MD036 -->
133
138
 
134
139
  and this HTML
135
140
 
@@ -138,6 +143,7 @@ and this HTML
138
143
  ```
139
144
 
140
145
  ### Italics
146
+
141
147
  For emphasizing a snippet of text with italics.
142
148
 
143
149
  The following snippet of text is _rendered as italicized text_.
@@ -148,7 +154,9 @@ _rendered as italicized text_
148
154
 
149
155
  renders to:
150
156
 
157
+ <!-- markdownlint-disable MD036 -->
151
158
  _rendered as italicized text_
159
+ <!-- markdownlint-enable MD036 -->
152
160
 
153
161
  and this HTML:
154
162
 
@@ -156,13 +164,14 @@ and this HTML:
156
164
  <em>rendered as italicized text</em>
157
165
  ```
158
166
 
167
+ ### Strikethrough
159
168
 
160
- ### strikethrough
161
169
  In GFM (GitHub flavored Markdown) you can do strikethroughs.
162
170
 
163
171
  ```markdown
164
172
  ~~Strike through this text.~~
165
173
  ```
174
+
166
175
  Which renders to:
167
176
 
168
177
  ~~Strike through this text.~~
@@ -219,10 +228,10 @@ Renders to:
219
228
  The old mechanism for notices overriding the block quote syntax (`>>>`) has been deprecated. Notices are now handled via a dedicated plugin called [Markdown Notices](https://github.com/getgrav/grav-plugin-markdown-notices)
220
229
  {{% /notice %}}
221
230
 
222
-
223
231
  ## Lists
224
232
 
225
233
  ### Unordered
234
+
226
235
  A list of items in which the order of the items does not explicitly matter.
227
236
 
228
237
  You may use any of the following symbols to denote bullets for each list item:
@@ -249,8 +258,10 @@ For example
249
258
  + Aenean sit amet erat nunc
250
259
  + Eget porttitor lorem
251
260
  ```
261
+
252
262
  Renders to:
253
263
 
264
+ <!-- markdownlint-disable MD004 -->
254
265
  + Lorem ipsum dolor sit amet
255
266
  + Consectetur adipiscing elit
256
267
  + Integer molestie lorem at massa
@@ -263,6 +274,7 @@ Renders to:
263
274
  + Faucibus porta lacus fringilla vel
264
275
  + Aenean sit amet erat nunc
265
276
  + Eget porttitor lorem
277
+ <!-- markdownlint-enable MD004 -->
266
278
 
267
279
  And this HTML
268
280
 
@@ -292,14 +304,15 @@ A list of items in which the order of items does explicitly matter.
292
304
 
293
305
  ```markdown
294
306
  1. Lorem ipsum dolor sit amet
295
- 2. Consectetur adipiscing elit
296
- 3. Integer molestie lorem at massa
297
- 4. Facilisis in pretium nisl aliquet
298
- 5. Nulla volutpat aliquam velit
299
- 6. Faucibus porta lacus fringilla vel
300
- 7. Aenean sit amet erat nunc
301
- 8. Eget porttitor lorem
307
+ 4. Consectetur adipiscing elit
308
+ 2. Integer molestie lorem at massa
309
+ 8. Facilisis in pretium nisl aliquet
310
+ 4. Nulla volutpat aliquam velit
311
+ 99. Faucibus porta lacus fringilla vel
312
+ 21. Aenean sit amet erat nunc
313
+ 6. Eget porttitor lorem
302
314
  ```
315
+
303
316
  Renders to:
304
317
 
305
318
  1. Lorem ipsum dolor sit amet
@@ -353,6 +366,7 @@ Renders to:
353
366
  ## Code
354
367
 
355
368
  ### Inline code
369
+
356
370
  Wrap inline snippets of code with `` ` ``.
357
371
 
358
372
  ```markdown
@@ -361,31 +375,33 @@ In this example, `<section></section>` should be wrapped as **code**.
361
375
 
362
376
  Renders to:
363
377
 
364
- In this example, `<section></section>` should be wrapped with **code**.
378
+ In this example, `<section></section>` should be wrapped as **code**.
365
379
 
366
380
  HTML:
367
381
 
368
382
  ```html
369
- <p>In this example, <code>&lt;section&gt;&lt;/section&gt;</code> should be wrapped with <strong>code</strong>.</p>
383
+ <p>In this example, <code>&lt;section&gt;&lt;/section&gt;</code> should be wrapped as <strong>code</strong>.</p>
370
384
  ```
371
385
 
372
386
  ### Indented code
373
387
 
374
- Or indent several lines of code by at least four spaces, as in:
388
+ Or indent several lines of code by at least two spaces, as in:
375
389
 
376
- <pre>
377
- // Some comments
378
- line 1 of code
379
- line 2 of code
380
- line 3 of code
381
- </pre>
390
+ ```markdown
391
+ // Some comments
392
+ line 1 of code
393
+ line 2 of code
394
+ line 3 of code
395
+ ```
382
396
 
383
397
  Renders to:
384
398
 
399
+ <!-- markdownlint-disable MD046 -->
385
400
  // Some comments
386
401
  line 1 of code
387
402
  line 2 of code
388
403
  line 3 of code
404
+ <!-- markdownlint-enable MD046 -->
389
405
 
390
406
  HTML:
391
407
 
@@ -400,19 +416,11 @@ HTML:
400
416
  </pre>
401
417
  ```
402
418
 
403
-
404
419
  ### Block code "fences"
405
420
 
406
421
  Use "fences" ```` ``` ```` to block in multiple lines of code.
407
422
 
408
- <pre>
409
- ``` markup
410
- Sample text here...
411
- ```
412
- </pre>
413
-
414
-
415
- ```
423
+ ```markdown
416
424
  Sample text here...
417
425
  ```
418
426
 
@@ -426,30 +434,34 @@ HTML:
426
434
 
427
435
  ### Syntax highlighting
428
436
 
429
- GFM, or "GitHub Flavored Markdown" also supports syntax highlighting. To activate it, simply add the file extension of the language you want to use directly after the first code "fence", ` ```js `, and syntax highlighting will automatically be applied in the rendered HTML. For example, to apply syntax highlighting to JavaScript code:
430
-
431
- <pre>
432
- ```js
433
- grunt.initConfig({
434
- assemble: {
435
- options: {
436
- assets: 'docs/assets',
437
- data: 'src/data/*.{json,yml}',
438
- helpers: 'src/custom-helpers.js',
439
- partials: ['src/partials/**/*.{hbs,md}']
440
- },
441
- pages: {
442
- options: {
443
- layout: 'default.hbs'
444
- },
445
- files: {
446
- './': ['src/templates/pages/index.hbs']
437
+ GFM, or "GitHub Flavored Markdown" also supports syntax highlighting. To activate it, simply add the file extension of the language you want to use directly after the first code "fence", ` ```js `, and syntax highlighting will automatically be applied in the rendered HTML.
438
+
439
+ See [Code Highlighting]({{< ref "syntaxhighlight.md" >}}) for additional documentation.
440
+
441
+ For example, to apply syntax highlighting to JavaScript code:
442
+
443
+ ```plaintext
444
+ ```js
445
+ grunt.initConfig({
446
+ assemble: {
447
+ options: {
448
+ assets: 'docs/assets',
449
+ data: 'src/data/*.{json,yml}',
450
+ helpers: 'src/custom-helpers.js',
451
+ partials: ['src/partials/**/*.{hbs,md}']
452
+ },
453
+ pages: {
454
+ options: {
455
+ layout: 'default.hbs'
456
+ },
457
+ files: {
458
+ './': ['src/templates/pages/index.hbs']
459
+ }
460
+ }
447
461
  }
448
- }
449
- }
450
- };
462
+ };
463
+ ```
451
464
  ```
452
- </pre>
453
465
 
454
466
  Renders to:
455
467
 
@@ -475,8 +487,8 @@ grunt.initConfig({
475
487
  ```
476
488
 
477
489
  ## Tables
478
- Tables are created by adding pipes as dividers between each cell, and by adding a line of dashes (also separated by bars) beneath the header. Note that the pipes do not need to be vertically aligned.
479
490
 
491
+ Tables are created by adding pipes as dividers between each cell, and by adding a line of dashes (also separated by bars) beneath the header. Note that the pipes do not need to be vertically aligned.
480
492
 
481
493
  ```markdown
482
494
  | Option | Description |
@@ -553,8 +565,7 @@ HTML:
553
565
  <a href="http://assemble.io">Assemble</a>
554
566
  ```
555
567
 
556
-
557
- ### Add a title
568
+ ### Add a tooltip
558
569
 
559
570
  ```markdown
560
571
  [Upstage](https://github.com/upstage/ "Visit Upstage!")
@@ -580,6 +591,7 @@ Named anchors enable you to jump to the specified anchor point on the same page.
580
591
  * [Chapter 2](#chapter-2)
581
592
  * [Chapter 3](#chapter-3)
582
593
  ```
594
+
583
595
  will jump to these sections:
584
596
 
585
597
  ```markdown
@@ -600,12 +612,15 @@ Images have a similar syntax to links but include a preceding exclamation point.
600
612
  ```markdown
601
613
  ![Minion](https://octodex.github.com/images/minion.png)
602
614
  ```
615
+
603
616
  ![Minion](https://octodex.github.com/images/minion.png)
604
617
 
605
618
  or
619
+
606
620
  ```markdown
607
621
  ![Alt text](https://octodex.github.com/images/stormtroopocat.jpg "The Stormtroopocat")
608
622
  ```
623
+
609
624
  ![Alt text](https://octodex.github.com/images/stormtroopocat.jpg "The Stormtroopocat")
610
625
 
611
626
  Like links, Images also have a footnote style syntax
@@ -615,6 +630,7 @@ Like links, Images also have a footnote style syntax
615
630
  ```markdown
616
631
  ![Alt text][id]
617
632
  ```
633
+
618
634
  ![Alt text][id]
619
635
 
620
636
  With a reference later in the document defining the URL location:
@@ -652,14 +668,25 @@ Add a HTTP `classes` parameter to the link image to add CSS classes. `shadow`and
652
668
  ```markdown
653
669
  ![stormtroopocat](https://octodex.github.com/images/stormtroopocat.jpg?classes=shadow)
654
670
  ```
671
+
655
672
  ![stormtroopocat](https://octodex.github.com/images/stormtroopocat.jpg?width=40pc&classes=shadow)
656
673
 
657
674
  ```markdown
658
675
  ![stormtroopocat](https://octodex.github.com/images/stormtroopocat.jpg?classes=border)
659
676
  ```
677
+
660
678
  ![stormtroopocat](https://octodex.github.com/images/stormtroopocat.jpg?width=40pc&classes=border)
661
679
 
662
680
  ```markdown
663
681
  ![stormtroopocat](https://octodex.github.com/images/stormtroopocat.jpg?classes=border,shadow)
664
682
  ```
683
+
665
684
  ![stormtroopocat](https://octodex.github.com/images/stormtroopocat.jpg?width=40pc&classes=border,shadow)
685
+
686
+ ### Lightbox
687
+
688
+ Add a HTTP `featherlight` parameter to the link image to disable lightbox. By default lightbox is enabled using the featherlight.js plugin. You can disable this by defining `featherlight` to `false`.
689
+
690
+ ```markdown
691
+ ![Minion](https://octodex.github.com/images/minion.png?featherlight=false)
692
+ ```
@@ -4,11 +4,11 @@ title: Organisation des pages
4
4
  weight: 5
5
5
  ---
6
6
 
7
- Dans **Hugo**, les pages sont le coeur de votre site. Une fois configurées, les pages sont la valeur ajoutée de votre site de documentation.
7
+ Dans **Hugo**, les pages sont le cœur de votre site. Une fois configurées, les pages sont la valeur ajoutée de votre site de documentation.
8
8
 
9
9
  ## Dossiers
10
10
 
11
- Organisez votre site comment n'importe quel autre [projet Hugo](https://gohugo.io/content/organization/). Typiquement, vous allez avoir un dossier *content* avec vos pages.
11
+ Organisez votre site comme n'importe quel autre [projet Hugo](https://gohugo.io/content/organization/). Typiquement, vous allez avoir un dossier *content* avec vos pages.
12
12
 
13
13
  content
14
14
  ├── niveau-un
@@ -35,7 +35,7 @@ Organisez votre site comment n'importe quel autre [projet Hugo](https://gohugo.i
35
35
  └── premiere-page.md <-- /premiere-page
36
36
 
37
37
  {{% notice note %}}
38
- Le fichier `_index.md` est obligatoire dans chaque dossier, c'est en quelques rotes votre page d'accueil pour le dossier.
38
+ Le fichier `_index.md` est obligatoire dans chaque dossier, c'est en quelque sorte votre page d'accueil pour le dossier.
39
39
  {{% /notice %}}
40
40
 
41
41
  ## Types
@@ -0,0 +1,89 @@
1
+ ---
2
+ date: 2020-06-01T13:31:12+01:00
3
+ title: Code highlighting
4
+ weight: 16
5
+ ---
6
+
7
+ Learn theme uses [highlight.js](https://highlightjs.org/) to provide code syntax highlighting.
8
+
9
+ ## Markdown syntax
10
+
11
+ Wrap the code block with three backticks and the name of the language. Highlight will try to auto detect the language if one is not provided.
12
+
13
+ <!-- markdownlint-disable MD046 -->
14
+ ```plaintext
15
+ ```json
16
+ [
17
+ {
18
+ "title": "apples",
19
+ "count": [12000, 20000],
20
+ "description": {"text": "...", "sensitive": false}
21
+ },
22
+ {
23
+ "title": "oranges",
24
+ "count": [17500, null],
25
+ "description": {"text": "...", "sensitive": false}
26
+ }
27
+ ]
28
+ ```
29
+ ```
30
+ <!-- markdownlint-disable MD046 -->
31
+
32
+ Renders to:
33
+
34
+ ```json
35
+ [
36
+ {
37
+ "title": "apples",
38
+ "count": [12000, 20000],
39
+ "description": {"text": "...", "sensitive": false}
40
+ },
41
+ {
42
+ "title": "oranges",
43
+ "count": [17500, null],
44
+ "description": {"text": "...", "sensitive": false}
45
+ }
46
+ ]
47
+ ```
48
+
49
+ ## Supported languages
50
+
51
+ Learn theme ships with its own version of highlight.js to support offline browsing. The included package supports 38 common languages, as described on the [highlight.js download page](https://highlightjs.org/download/).
52
+
53
+ ## Identifying failed language detection
54
+
55
+ Highlight will write a warning to the browser console if a requested language was not found. For example, the following code block references an imaginary language `foo`. An error will be output to the console on this page.
56
+
57
+ ```plaintext
58
+ ```foo
59
+ bar
60
+ ```
61
+ ```
62
+
63
+ ```nohighlight
64
+ Could not find the language 'foo', did you forget to load/include a language module?(anonymous) @ highlight.pack.js
65
+ ```
66
+
67
+ ## Supporting additional languages
68
+
69
+ To support languages other than the 38 common languages included in the default highlight.js you will need to download your own version of highlight.js and add it to your site content.
70
+
71
+ ### Download custom highlight.js
72
+
73
+ Visit [https://highlightjs.org/download/](https://highlightjs.org/download/) and select your desired language support. Note that more languages means greater package size.
74
+
75
+ ### Add custom highlight.js to static resources
76
+
77
+ Inside the zip archive downloaded from highlight.js extract the file named `highlight.pack.js`. Move this file to the **new** location
78
+
79
+ ```nohighlight
80
+ static/js/highlight.pack.js
81
+ ```
82
+
83
+ **Do not** replace the existing file at `themes/hugo-theme-learn/static/js/highlight.pack.js`.
84
+
85
+ Including the file in the correct path will override the theme default highlight.pack.js and prevent issues caused in the future if the theme default file is updated.
86
+
87
+ ## Further usage information
88
+
89
+ See [https://highlightjs.org/usage/](https://highlightjs.org/usage/)