Skip to content

Commit ae2ab8f

Browse files
committed
Add Learn section to sidebar
Move videos, Pro Git book, and external links to Learn section. Will require the book CI to rerun to update the section of the site the book is in.
1 parent 9f926a7 commit ae2ab8f

File tree

4 files changed

+17
-7
lines changed

4 files changed

+17
-7
lines changed

content/doc/ext/_index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
section: "documentation"
2+
section: "learn"
33
subsection: "external-links"
44
title: "Git - External Links"
55
url: /doc/ext.html

content/videos/_index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
section: "documentation"
2+
section: "learn"
33
subsection: "videos"
44
title: "Git - Videos"
55
url: /videos.html

layouts/partials/sidebar.html

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,16 @@
1717
{{ end }}
1818
</ul>
1919
</li>
20+
2021
<li>
21-
<a href="{{ relURL "doc" }}"{{ if (eq $section "documentation") }} class="active"{{ end }}>Documentation</a>
22-
<ul {{ if (eq $section "documentation") }}class="expanded"{{ end }}>
22+
<a href="{{ relURL "learn" }}"{{ if (eq $section "learn") }} class="active"{{ end }}>Learn</a>
23+
<ul {{ if (eq $section "learn") }}class="expanded"{{ end }}>
2324
<li>
24-
<a href="{{ relURL "docs" }}"{{ if or (eq .Params.Subsection "reference") (eq .Params.Subsection "manual") }} class="active"{{ end }}>Reference</a>
25+
<a href="{{ relURL "book" }}"{{ if (eq .Params.Subsection "book") }} class="active"{{ end }}>Book</a>
2526
</li>
27+
2628
<li>
27-
<a href="{{ relURL "book" }}"{{ if (eq .Params.Subsection "book") }} class="active"{{ end }}>Book</a>
29+
<a href="{{ relURL "cheat-sheet" }}"{{ if (eq .Params.Subsection "cheat-sheet") }} class="active"{{ end }}>Cheat Sheet</a>
2830
</li>
2931
<li>
3032
<a href="{{ relURL "videos" }}"{{ if (eq .Params.Subsection "videos") }} class="active"{{ end }}>Videos</a>
@@ -34,6 +36,14 @@
3436
</li>
3537
</ul>
3638
</li>
39+
<li>
40+
<a href="{{ relURL "doc" }}"{{ if (eq $section "documentation") }} class="active"{{ end }}>Documentation</a>
41+
<ul {{ if (eq $section "documentation") }}class="expanded"{{ end }}>
42+
<li>
43+
<a href="{{ relURL "docs" }}"{{ if or (eq .Params.Subsection "reference") (eq .Params.Subsection "manual") }} class="active"{{ end }}>Reference</a>
44+
</li>
45+
</ul>
46+
</li>
3747
<li>
3848
<a href="{{ relURL "downloads" }}"{{ if (eq $section "downloads") }} class="active"{{ end }}>Downloads</a>
3949
<ul {{ if (eq $section "downloads") }}class="expanded"{{ end }}>

script/book.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ def initialize(edition, language_code)
5858
def front_matter
5959
front_matter = {
6060
"category" => "book",
61-
"section" => "documentation",
61+
"section" => "learn",
6262
"subsection" => "book",
6363
"sidebar" => "book",
6464
"book" => {

0 commit comments

Comments
 (0)