Skip to content

Commit 7bd3c2c

Browse files
committed
garden v1.10.1-rc.0
1 parent e63287d commit 7bd3c2c

25 files changed

+422
-695
lines changed

404.html

Lines changed: 18 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!DOCTYPE HTML>
2-
<html lang="en" class="ayu" dir="ltr">
2+
<html lang="en" class="ayu sidebar-visible" dir="ltr">
33
<head>
44
<!-- Book generated using mdBook -->
55
<meta charset="UTF-8">
@@ -8,7 +8,7 @@
88

99

1010
<!-- Custom HTML head -->
11-
11+
1212
<meta name="description" content="Garden grows and cultivates Git trees">
1313
<meta name="viewport" content="width=device-width, initial-scale=1">
1414
<meta name="theme-color" content="#ffffff">
@@ -33,15 +33,17 @@
3333

3434
<!-- MathJax -->
3535
<script async src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
36-
</head>
37-
<body class="sidebar-visible no-js">
38-
<div id="body-container">
36+
3937
<!-- Provide site root to javascript -->
4038
<script>
4139
var path_to_root = "";
4240
var default_theme = window.matchMedia("(prefers-color-scheme: dark)").matches ? "ayu" : "ayu";
4341
</script>
44-
42+
<!-- Start loading toc.js asap -->
43+
<script src="toc.js"></script>
44+
</head>
45+
<body>
46+
<div id="body-container">
4547
<!-- Work around some values being stored in localStorage wrapped in quotes -->
4648
<script>
4749
try {
@@ -63,19 +65,16 @@
6365
var theme;
6466
try { theme = localStorage.getItem('mdbook-theme'); } catch(e) { }
6567
if (theme === null || theme === undefined) { theme = default_theme; }
66-
var html = document.querySelector('html');
68+
const html = document.documentElement;
6769
html.classList.remove('ayu')
6870
html.classList.add(theme);
69-
var body = document.querySelector('body');
70-
body.classList.remove('no-js')
71-
body.classList.add('js');
71+
html.classList.add("js");
7272
</script>
7373

7474
<input type="checkbox" id="sidebar-toggle-anchor" class="hidden">
7575

7676
<!-- Hide / unhide sidebar before it is displayed -->
7777
<script>
78-
var body = document.querySelector('body');
7978
var sidebar = null;
8079
var sidebar_toggle = document.getElementById("sidebar-toggle-anchor");
8180
if (document.body.clientWidth >= 1080) {
@@ -85,45 +84,25 @@
8584
sidebar = 'hidden';
8685
}
8786
sidebar_toggle.checked = sidebar === 'visible';
88-
body.classList.remove('sidebar-visible');
89-
body.classList.add("sidebar-" + sidebar);
87+
html.classList.remove('sidebar-visible');
88+
html.classList.add("sidebar-" + sidebar);
9089
</script>
9190

9291
<nav id="sidebar" class="sidebar" aria-label="Table of contents">
93-
<div class="sidebar-scrollbox">
94-
<ol class="chapter"><li class="chapter-item expanded "><a href="index.html"><strong aria-hidden="true">1.</strong> Garden</a></li><li class="chapter-item expanded "><a href="glossary.html"><strong aria-hidden="true">2.</strong> Glossary</a></li><li class="chapter-item expanded "><a href="installation.html"><strong aria-hidden="true">3.</strong> Installation</a></li><li class="chapter-item expanded "><a href="setup-and-usage.html"><strong aria-hidden="true">4.</strong> Setup and Usage</a></li><li class="chapter-item expanded "><a href="tree-queries.html"><strong aria-hidden="true">5.</strong> Tree Queries</a></li><li class="chapter-item expanded "><a href="commands.html"><strong aria-hidden="true">6.</strong> Commands</a></li><li class="chapter-item expanded "><a href="configuration.html"><strong aria-hidden="true">7.</strong> Configuration</a></li><li class="chapter-item expanded "><a href="examples.html"><strong aria-hidden="true">8.</strong> Examples</a></li><li><ol class="section"><li class="chapter-item expanded "><a href="examples/photo-restoration.html"><strong aria-hidden="true">8.1.</strong> Photo Restoration</a></li><li class="chapter-item expanded "><a href="examples/git-cola.html"><strong aria-hidden="true">8.2.</strong> Git Cola</a></li><li class="chapter-item expanded "><a href="examples/command-interpreters.html"><strong aria-hidden="true">8.3.</strong> Command Interpreters</a></li><li class="chapter-item expanded "><a href="examples/python.html"><strong aria-hidden="true">8.4.</strong> Python</a></li><li class="chapter-item expanded "><a href="examples/node.html"><strong aria-hidden="true">8.5.</strong> Node</a></li></ol></li><li class="chapter-item expanded "><a href="tips-and-tricks.html"><strong aria-hidden="true">9.</strong> FAQ, Tips and Tricks</a></li><li class="chapter-item expanded "><a href="changelog.html"><strong aria-hidden="true">10.</strong> Changelog</a></li></ol>
95-
</div>
92+
<!-- populated by js -->
93+
<mdbook-sidebar-scrollbox class="sidebar-scrollbox"></mdbook-sidebar-scrollbox>
94+
<noscript>
95+
<iframe class="sidebar-iframe-outer" src="toc.html"></iframe>
96+
</noscript>
9697
<div id="sidebar-resize-handle" class="sidebar-resize-handle">
9798
<div class="sidebar-resize-indicator"></div>
9899
</div>
99100
</nav>
100101

101-
<!-- Track and set sidebar scroll position -->
102-
<script>
103-
var sidebarScrollbox = document.querySelector('#sidebar .sidebar-scrollbox');
104-
sidebarScrollbox.addEventListener('click', function(e) {
105-
if (e.target.tagName === 'A') {
106-
sessionStorage.setItem('sidebar-scroll', sidebarScrollbox.scrollTop);
107-
}
108-
}, { passive: true });
109-
var sidebarScrollTop = sessionStorage.getItem('sidebar-scroll');
110-
sessionStorage.removeItem('sidebar-scroll');
111-
if (sidebarScrollTop) {
112-
// preserve sidebar scroll position when navigating via links within sidebar
113-
sidebarScrollbox.scrollTop = sidebarScrollTop;
114-
} else {
115-
// scroll sidebar to current active section when navigating via "next/previous chapter" buttons
116-
var activeSection = document.querySelector('#sidebar .active');
117-
if (activeSection) {
118-
activeSection.scrollIntoView({ block: 'center' });
119-
}
120-
}
121-
</script>
122-
123102
<div id="page-wrapper" class="page-wrapper">
124103

125104
<div class="page">
126-
<div id="menu-bar-hover-placeholder"></div>
105+
<div id="menu-bar-hover-placeholder"></div>
127106
<div id="menu-bar" class="menu-bar sticky">
128107
<div class="left-buttons">
129108
<label id="sidebar-toggle" class="icon-button" for="sidebar-toggle-anchor" title="Toggle Table of Contents" aria-label="Toggle Table of Contents" aria-controls="sidebar">

book.js

Lines changed: 9 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ function playground_text(playground, hidden = true) {
225225
}
226226

227227
var clipButton = document.createElement('button');
228-
clipButton.className = 'fa fa-copy clip-button';
228+
clipButton.className = 'clip-button';
229229
clipButton.title = 'Copy to clipboard';
230230
clipButton.setAttribute('aria-label', clipButton.title);
231231
clipButton.innerHTML = '<i class=\"tooltiptext\"></i>';
@@ -258,7 +258,7 @@ function playground_text(playground, hidden = true) {
258258

259259
if (window.playground_copyable) {
260260
var copyCodeClipboardButton = document.createElement('button');
261-
copyCodeClipboardButton.className = 'fa fa-copy clip-button';
261+
copyCodeClipboardButton.className = 'clip-button';
262262
copyCodeClipboardButton.innerHTML = '<i class="tooltiptext"></i>';
263263
copyCodeClipboardButton.title = 'Copy to clipboard';
264264
copyCodeClipboardButton.setAttribute('aria-label', copyCodeClipboardButton.title);
@@ -289,6 +289,10 @@ function playground_text(playground, hidden = true) {
289289
var themeToggleButton = document.getElementById('theme-toggle');
290290
var themePopup = document.getElementById('theme-list');
291291
var themeColorMetaTag = document.querySelector('meta[name="theme-color"]');
292+
var themeIds = [];
293+
themePopup.querySelectorAll('button.theme').forEach(function (el) {
294+
themeIds.push(el.id);
295+
});
292296
var stylesheets = {
293297
ayuHighlight: document.querySelector("[href$='ayu-highlight.css']"),
294298
tomorrowNight: document.querySelector("[href$='tomorrow-night.css']"),
@@ -317,7 +321,7 @@ function playground_text(playground, hidden = true) {
317321
function get_theme() {
318322
var theme;
319323
try { theme = localStorage.getItem('mdbook-theme'); } catch (e) { }
320-
if (theme === null || theme === undefined) {
324+
if (theme === null || theme === undefined || !themeIds.includes(theme)) {
321325
return default_theme;
322326
} else {
323327
return theme;
@@ -459,17 +463,6 @@ function playground_text(playground, hidden = true) {
459463
try { localStorage.setItem('mdbook-sidebar', 'visible'); } catch (e) { }
460464
}
461465

462-
463-
var sidebarAnchorToggles = document.querySelectorAll('#sidebar a.toggle');
464-
465-
function toggleSection(ev) {
466-
ev.currentTarget.parentElement.classList.toggle('expanded');
467-
}
468-
469-
Array.from(sidebarAnchorToggles).forEach(function (el) {
470-
el.addEventListener('click', toggleSection);
471-
});
472-
473466
function hideSidebar() {
474467
body.classList.remove('sidebar-visible')
475468
body.classList.add('sidebar-hidden');
@@ -597,12 +590,12 @@ function playground_text(playground, hidden = true) {
597590

598591
function hideTooltip(elem) {
599592
elem.firstChild.innerText = "";
600-
elem.className = 'fa fa-copy clip-button';
593+
elem.className = 'clip-button';
601594
}
602595

603596
function showTooltip(elem, msg) {
604597
elem.firstChild.innerText = msg;
605-
elem.className = 'fa fa-copy tooltipped';
598+
elem.className = 'clip-button tooltipped';
606599
}
607600

608601
var clipboardSnippets = new ClipboardJS('.clip-button', {

changelog.html

Lines changed: 24 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
<!DOCTYPE HTML>
2-
<html lang="en" class="ayu" dir="ltr">
2+
<html lang="en" class="ayu sidebar-visible" dir="ltr">
33
<head>
44
<!-- Book generated using mdBook -->
55
<meta charset="UTF-8">
66
<title>Changelog - Garden User Guide</title>
77

88

99
<!-- Custom HTML head -->
10-
10+
1111
<meta name="description" content="Garden grows and cultivates Git trees">
1212
<meta name="viewport" content="width=device-width, initial-scale=1">
1313
<meta name="theme-color" content="#ffffff">
@@ -32,15 +32,17 @@
3232

3333
<!-- MathJax -->
3434
<script async src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script>
35-
</head>
36-
<body class="sidebar-visible no-js">
37-
<div id="body-container">
35+
3836
<!-- Provide site root to javascript -->
3937
<script>
4038
var path_to_root = "";
4139
var default_theme = window.matchMedia("(prefers-color-scheme: dark)").matches ? "ayu" : "ayu";
4240
</script>
43-
41+
<!-- Start loading toc.js asap -->
42+
<script src="toc.js"></script>
43+
</head>
44+
<body>
45+
<div id="body-container">
4446
<!-- Work around some values being stored in localStorage wrapped in quotes -->
4547
<script>
4648
try {
@@ -62,19 +64,16 @@
6264
var theme;
6365
try { theme = localStorage.getItem('mdbook-theme'); } catch(e) { }
6466
if (theme === null || theme === undefined) { theme = default_theme; }
65-
var html = document.querySelector('html');
67+
const html = document.documentElement;
6668
html.classList.remove('ayu')
6769
html.classList.add(theme);
68-
var body = document.querySelector('body');
69-
body.classList.remove('no-js')
70-
body.classList.add('js');
70+
html.classList.add("js");
7171
</script>
7272

7373
<input type="checkbox" id="sidebar-toggle-anchor" class="hidden">
7474

7575
<!-- Hide / unhide sidebar before it is displayed -->
7676
<script>
77-
var body = document.querySelector('body');
7877
var sidebar = null;
7978
var sidebar_toggle = document.getElementById("sidebar-toggle-anchor");
8079
if (document.body.clientWidth >= 1080) {
@@ -84,45 +83,25 @@
8483
sidebar = 'hidden';
8584
}
8685
sidebar_toggle.checked = sidebar === 'visible';
87-
body.classList.remove('sidebar-visible');
88-
body.classList.add("sidebar-" + sidebar);
86+
html.classList.remove('sidebar-visible');
87+
html.classList.add("sidebar-" + sidebar);
8988
</script>
9089

9190
<nav id="sidebar" class="sidebar" aria-label="Table of contents">
92-
<div class="sidebar-scrollbox">
93-
<ol class="chapter"><li class="chapter-item expanded "><a href="index.html"><strong aria-hidden="true">1.</strong> Garden</a></li><li class="chapter-item expanded "><a href="glossary.html"><strong aria-hidden="true">2.</strong> Glossary</a></li><li class="chapter-item expanded "><a href="installation.html"><strong aria-hidden="true">3.</strong> Installation</a></li><li class="chapter-item expanded "><a href="setup-and-usage.html"><strong aria-hidden="true">4.</strong> Setup and Usage</a></li><li class="chapter-item expanded "><a href="tree-queries.html"><strong aria-hidden="true">5.</strong> Tree Queries</a></li><li class="chapter-item expanded "><a href="commands.html"><strong aria-hidden="true">6.</strong> Commands</a></li><li class="chapter-item expanded "><a href="configuration.html"><strong aria-hidden="true">7.</strong> Configuration</a></li><li class="chapter-item expanded "><a href="examples.html"><strong aria-hidden="true">8.</strong> Examples</a></li><li><ol class="section"><li class="chapter-item expanded "><a href="examples/photo-restoration.html"><strong aria-hidden="true">8.1.</strong> Photo Restoration</a></li><li class="chapter-item expanded "><a href="examples/git-cola.html"><strong aria-hidden="true">8.2.</strong> Git Cola</a></li><li class="chapter-item expanded "><a href="examples/command-interpreters.html"><strong aria-hidden="true">8.3.</strong> Command Interpreters</a></li><li class="chapter-item expanded "><a href="examples/python.html"><strong aria-hidden="true">8.4.</strong> Python</a></li><li class="chapter-item expanded "><a href="examples/node.html"><strong aria-hidden="true">8.5.</strong> Node</a></li></ol></li><li class="chapter-item expanded "><a href="tips-and-tricks.html"><strong aria-hidden="true">9.</strong> FAQ, Tips and Tricks</a></li><li class="chapter-item expanded "><a href="changelog.html" class="active"><strong aria-hidden="true">10.</strong> Changelog</a></li></ol>
94-
</div>
91+
<!-- populated by js -->
92+
<mdbook-sidebar-scrollbox class="sidebar-scrollbox"></mdbook-sidebar-scrollbox>
93+
<noscript>
94+
<iframe class="sidebar-iframe-outer" src="toc.html"></iframe>
95+
</noscript>
9596
<div id="sidebar-resize-handle" class="sidebar-resize-handle">
9697
<div class="sidebar-resize-indicator"></div>
9798
</div>
9899
</nav>
99100

100-
<!-- Track and set sidebar scroll position -->
101-
<script>
102-
var sidebarScrollbox = document.querySelector('#sidebar .sidebar-scrollbox');
103-
sidebarScrollbox.addEventListener('click', function(e) {
104-
if (e.target.tagName === 'A') {
105-
sessionStorage.setItem('sidebar-scroll', sidebarScrollbox.scrollTop);
106-
}
107-
}, { passive: true });
108-
var sidebarScrollTop = sessionStorage.getItem('sidebar-scroll');
109-
sessionStorage.removeItem('sidebar-scroll');
110-
if (sidebarScrollTop) {
111-
// preserve sidebar scroll position when navigating via links within sidebar
112-
sidebarScrollbox.scrollTop = sidebarScrollTop;
113-
} else {
114-
// scroll sidebar to current active section when navigating via "next/previous chapter" buttons
115-
var activeSection = document.querySelector('#sidebar .active');
116-
if (activeSection) {
117-
activeSection.scrollIntoView({ block: 'center' });
118-
}
119-
}
120-
</script>
121-
122101
<div id="page-wrapper" class="page-wrapper">
123102

124103
<div class="page">
125-
<div id="menu-bar-hover-placeholder"></div>
104+
<div id="menu-bar-hover-placeholder"></div>
126105
<div id="menu-bar" class="menu-bar sticky">
127106
<div class="left-buttons">
128107
<label id="sidebar-toggle" class="icon-button" for="sidebar-toggle-anchor" title="Toggle Table of Contents" aria-label="Toggle Table of Contents" aria-controls="sidebar">
@@ -182,6 +161,12 @@ <h1 class="menu-title">Garden User Guide</h1>
182161
<div id="content" class="content">
183162
<main>
184163
<h1 id="changelog"><a class="header" href="#changelog">Changelog</a></h1>
164+
<h2 id="upcoming"><a class="header" href="#upcoming">Upcoming</a></h2>
165+
<p><strong>Features</strong>:</p>
166+
<ul>
167+
<li><code>garden completion</code> now includes a comment in its output indicating which version of
168+
<code>garden</code> was used to generate the completion script.</li>
169+
</ul>
185170
<h2 id="v1100"><a class="header" href="#v1100">v1.10.0</a></h2>
186171
<p><em>Released 2024-12-14</em></p>
187172
<p><strong>Features</strong>:</p>

0 commit comments

Comments
 (0)