hugo-theme-relearn/pir/cont/pages/index.print.html

222 lines
22 KiB
HTML
Raw Normal View History

<!DOCTYPE html>
<html lang="pir" dir="rtl">
<head>
<meta charset="utf-8">
<meta name="viewport" content="height=device-height, width=device-width, initial-scale=1.0, minimum-scale=1.0">
<meta name="generator" content="Hugo 0.120.4">
<meta name="generator" content="Relearn 5.23.2+tip">
<meta name="description" content="Documentation for Hugo Relearn Theme">
<meta name="author" content="Sören Weber">
<meta name="twitter:card" content="summary_large_image">
<meta name="twitter:image" content="https://McShelby.github.io/hugo-theme-relearn/images/hero.png">
<meta name="twitter:title" content="planks orrrganizat&#39;n :: Cap&#39;n Hugo Relearrrn Theme">
<meta name="twitter:description" content="Documentation for Hugo Relearn Theme">
<meta property="og:title" content="planks orrrganizat&#39;n :: Cap&#39;n Hugo Relearrrn Theme">
<meta property="og:description" content="Documentation for Hugo Relearn Theme">
<meta property="og:type" content="website">
<meta property="og:url" content="https://McShelby.github.io/hugo-theme-relearn/pir/cont/pages/index.html">
<meta property="og:image" content="https://McShelby.github.io/hugo-theme-relearn/images/hero.png">
<meta property="og:site_name" content="Cap&#39;n Hugo Relearrrn Theme">
<title>planks orrrganizat&#39;n :: Cap&#39;n Hugo Relearrrn Theme</title>
<link href="https://McShelby.github.io/hugo-theme-relearn/cont/pages/index.html" rel="alternate" hreflang="x-default">
<link href="https://McShelby.github.io/hugo-theme-relearn/cont/pages/index.html" rel="alternate" hreflang="en">
<link href="https://McShelby.github.io/hugo-theme-relearn/pir/cont/pages/index.html" rel="alternate" hreflang="pir">
<link href="https://McShelby.github.io/hugo-theme-relearn/pir/cont/pages/index.html" rel="canonical" type="text/html" title="planks orrrganizat&#39;n :: Cap&#39;n Hugo Relearrrn Theme">
<link href="../../../pir/cont/pages/index.xml" rel="alternate" type="application/rss+xml" title="planks orrrganizat&#39;n :: Cap&#39;n Hugo Relearrrn Theme">
<link href="../../../images/logo.svg?1701029988" rel="icon" type="image/svg+xml">
<!-- https://github.com/filamentgroup/loadCSS/blob/master/README.md#how-to-use -->
<link href="../../../css/fontawesome-all.min.css?1701029991" rel="stylesheet" media="print" onload="this.media='all';this.onload=null;"><noscript><link href="../../../css/fontawesome-all.min.css?1701029991" rel="stylesheet"></noscript>
<link href="../../../css/nucleus.css?1701029991" rel="stylesheet">
<link href="../../../css/auto-complete.css?1701029991" rel="stylesheet" media="print" onload="this.media='all';this.onload=null;"><noscript><link href="../../../css/auto-complete.css?1701029991" rel="stylesheet"></noscript>
<link href="../../../css/perfect-scrollbar.min.css?1701029991" rel="stylesheet">
<link href="../../../css/fonts.css?1701029991" rel="stylesheet" media="print" onload="this.media='all';this.onload=null;"><noscript><link href="../../../css/fonts.css?1701029991" rel="stylesheet"></noscript>
<link href="../../../css/theme.css?1701029991" rel="stylesheet">
<link href="../../../css/theme-relearn-auto.css?1701029991" rel="stylesheet" id="R-variant-style">
<link href="../../../css/chroma-relearn-auto.css?1701029991" rel="stylesheet" id="R-variant-chroma-style">
<link href="../../../css/variant.css?1701029991" rel="stylesheet">
<link href="../../../css/print.css?1701029991" rel="stylesheet" media="print">
<link href="../../../css/format-print.css?1701029991" rel="stylesheet">
<link href="../../../css/ie.css?1701029991" rel="stylesheet">
<script src="../../../js/url.js?1701029991"></script>
<script src="../../../js/variant.js?1701029991"></script>
<script>
// hack to let hugo tell us how to get to the root when using relativeURLs, it needs to be called *url= for it to do its magic:
// https://github.com/gohugoio/hugo/blob/145b3fcce35fbac25c7033c91c1b7ae6d1179da8/transform/urlreplacers/absurlreplacer.go#L72
window.index_js_url="../../../pir/index.search.js";
var root_url="../../../";
var baseUri=root_url.replace(/\/$/, '');
window.relearn = window.relearn || {};
window.relearn.baseUriFull='https:\/\/McShelby.github.io\/hugo-theme-relearn/';
// variant stuff
window.variants && variants.init( [ 'relearn-auto', 'relearn-light', 'relearn-dark', 'relearn-bright', 'zen-auto', 'zen-light', 'zen-dark', 'neon', 'learn', 'blue', 'green', 'red' ] );
// translations
window.T_Copy_to_clipboard = `Copy t' clipboard`;
window.T_Copied_to_clipboard = `Copied t' clipboard!`;
window.T_Copy_link_to_clipboard = `Copy link t' clipboard`;
window.T_Link_copied_to_clipboard = `Copied link t' clipboard!`;
window.T_Reset_view = `Rrreset view`;
window.T_View_reset = `View rrreset!`;
window.T_No_results_found = `No rrresults found fer "{0}"`;
window.T_N_results_found = `{1} rrresults found fer "{0}"`;
</script>
<style>
#R-body img.bg-white {
background-color: white;
}
</style>
</head>
<body class="mobile-support print disableInlineCopyToClipboard" data-url="../../../pir/cont/pages/index.html">
<div id="R-body" class="default-animation">
<div id="R-body-overlay"></div>
<nav id="R-topbar">
<div class="topbar-wrapper">
<div class="topbar-sidebar-divider"></div>
<div class="topbar-area topbar-area-start" data-area="start">
<div class="topbar-button topbar-button-sidebar" data-content-empty="disable" data-width-s="show" data-width-m="hide" data-width-l="hide">
<button class="topbar-control" onclick="toggleNav()" type="button" title="Menu (CTRL&#43;ALT&#43;n)">
<i class="fa-fw fas fa-bars"></i>
</button>
</div>
</div>
<ol class="topbar-breadcrumbs breadcrumbs highlightable" itemscope itemtype="http://schema.org/BreadcrumbList"><li
itemscope itemtype="https://schema.org/ListItem" itemprop="itemListElement"><a itemprop="item" href="../../../pir/cont/index.html"><span itemprop="name">Rambl&#39;n</span></a><meta itemprop="position" content="1">&nbsp;>&nbsp;</li><li
itemscope itemtype="https://schema.org/ListItem" itemprop="itemListElement"><span itemprop="name">planks orrrganizat&#39;n</span><meta itemprop="position" content="2"></li>
</ol>
<div class="topbar-area topbar-area-end" data-area="end">
</div>
</div>
</nav>
<div id="R-main-overlay"></div>
<main id="R-body-inner" class="highlightable default" tabindex="-1">
<div class="flex-block-wrapper">
<article class="default">
<header class="headline">
</header>
<h1 id="planks-orrrganizatn">planks orrrganizat&#39;n</h1>
<p>In <strong>Cap'n Hugo</strong>, planks be th' core o' yer ship. Once it be configured, planks be definitely th' added value t' yer documentat'n ship.</p>
<h2 id="folders">Folders</h2>
<p>Org'nize yer ship like <a href="https://gohugo.io/content/organization/" target="_blank">any other Cap'n Hugo project</a>. Typically, ye will have a <em>rrrambl'n</em> folder wit' all yer planks.</p>
<div class="wrap-code highlight"><pre tabindex="0" class="chroma"><code class="language-plaintext" data-lang="plaintext"><span class="line"><span class="cl">rrrambl'n
</span></span><span class="line"><span class="cl">├── level-one
</span></span><span class="line"><span class="cl">│ ├── level-two
</span></span><span class="line"><span class="cl">│ │ ├── level-three
</span></span><span class="line"><span class="cl">│ │ │ ├── level-four
</span></span><span class="line"><span class="cl">│ │ │ │ ├── _index.md &lt;-- /level-one/level-two/level-three/level-four
</span></span><span class="line"><span class="cl">│ │ │ │ ├── page-4-a.md &lt;-- /level-one/level-two/level-three/level-four/page-4-a
</span></span><span class="line"><span class="cl">│ │ │ │ ├── page-4-b.md &lt;-- /level-one/level-two/level-three/level-four/page-4-b
</span></span><span class="line"><span class="cl">│ │ │ │ └── page-4-c.md &lt;-- /level-one/level-two/level-three/level-four/page-4-c
</span></span><span class="line"><span class="cl">│ │ │ ├── _index.md &lt;-- /level-one/level-two/level-three
</span></span><span class="line"><span class="cl">│ │ │ ├── page-3-a.md &lt;-- /level-one/level-two/level-three/page-3-a
</span></span><span class="line"><span class="cl">│ │ │ ├── page-3-b.md &lt;-- /level-one/level-two/level-three/page-3-b
</span></span><span class="line"><span class="cl">│ │ │ └── page-3-c.md &lt;-- /level-one/level-two/level-three/page-3-c
</span></span><span class="line"><span class="cl">│ │ ├── _index.md &lt;-- /level-one/level-two
</span></span><span class="line"><span class="cl">│ │ ├── page-2-a.md &lt;-- /level-one/level-two/page-2-a
</span></span><span class="line"><span class="cl">│ │ ├── page-2-b.md &lt;-- /level-one/level-two/page-2-b
</span></span><span class="line"><span class="cl">│ │ └── page-2-c.md &lt;-- /level-one/level-two/page-2-c
</span></span><span class="line"><span class="cl">│ ├── _index.md &lt;-- /level-one
</span></span><span class="line"><span class="cl">│ ├── page-1-a.md &lt;-- /level-one/page-1-a
</span></span><span class="line"><span class="cl">│ ├── page-1-b.md &lt;-- /level-one/page-1-b
</span></span><span class="line"><span class="cl">│ └── page-1-c.md &lt;-- /level-one/page-1-c
</span></span><span class="line"><span class="cl">├── _index.md &lt;-- /
</span></span><span class="line"><span class="cl">└── page-top.md &lt;-- /page-top</span></span></code></pre></div>
<div class="box notices cstyle note">
<div class="box-label"><i class="fa-fw fas fa-exclamation-circle"></i> Avast</div>
<div class="box-content">
<p><code>_index.md</code> be required 'n each folder, its yer “folder home page”</p>
</div>
</div>
<h2 id="create-your-project">Create yer project</h2>
<p>Th' follow'n steps be here t' help ye initialize yer new website. If ye don&rsquo;t know Cap'n Hugo at all, we strongly suggest ye t' train by follow'n <a href="https://gohugo.io/overview/quickstart/" target="_blank">great documentat'n fer beginners</a>.</p>
<p>Cap'n Hugo provides a <code>new</code> command t' create a new website.</p>
<div class="wrap-code highlight"><pre tabindex="0" class="chroma"><code class="language-shell" data-lang="shell"><span class="line"><span class="cl">hugo new ship &lt;new_project&gt;</span></span></code></pre></div><p>Th' Relearrrn theme provides <a href="../../../cont/archetypes/index.html">archetypes</a> t' help ye create this kind o' planks.</p>
<h2 id="frontmatter-configuration">Frontmatter Configurat'n</h2>
<p>Each Cap'n Hugo plank has t' define a <a href="https://gohugo.io/content/front-matter/" target="_blank">frontmatter</a> 'n <em>toml</em>, <em>yaml</em> or <em>json</em>. This ship will use <em>toml</em> 'n all cases.</p>
<p>Th' Relearrrn theme uses th' follow'n parameters on top o' Cap'n Hugo ones:</p>
<div class="wrap-code highlight"><pre tabindex="0" class="chroma"><code class="language-toml" data-lang="toml"><span class="line"><span class="cl"><span class="err">+++</span>
</span></span><span class="line"><span class="cl"><span class="c"># T'ble o' contents (toc) be enabled by default. Set this parameter t' true t' dis'ble it.</span>
</span></span><span class="line"><span class="cl"><span class="c"># Avast: Toc be always disabled fer chapter planks</span>
</span></span><span class="line"><span class="cl"><span class="nx">disableToc</span> <span class="p">=</span> <span class="kc">false</span>
</span></span><span class="line"><span class="cl"><span class="c"># If set, this will be used fer th' page&#39;s menu entry (instead o' th' `title` attribute)</span>
</span></span><span class="line"><span class="cl"><span class="nx">menuTitle</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
</span></span><span class="line"><span class="cl"><span class="c"># If set t' true, th' menu 'n th' sidebar will be displayed 'n a collaps'ble tree view. Although th' functionality works wit' old browsers (IE11), th' display o' th' expander ay'cons be limited t' modern browsers</span>
</span></span><span class="line"><span class="cl"><span class="nx">collapsibleMenu</span> <span class="p">=</span> <span class="kc">false</span>
</span></span><span class="line"><span class="cl"><span class="c"># If set, this will explicitly override common rules fer th' expand state o' a page&#39;s menu entry</span>
</span></span><span class="line"><span class="cl"><span class="nx">alwaysopen</span> <span class="p">=</span> <span class="kc">true</span>
</span></span><span class="line"><span class="cl"><span class="c"># If set, this will explicitly override common rules fer th' sort'n order o' a page&#39;s submenu entries</span>
</span></span><span class="line"><span class="cl"><span class="nx">ordersectionsby</span> <span class="p">=</span> <span class="s2">&#34;weight&#34;</span>
</span></span><span class="line"><span class="cl"><span class="c"># Th' title o' th' plank head'n will be prefixed by this HTML rrrambl'n</span>
</span></span><span class="line"><span class="cl"><span class="nx">headingPre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
</span></span><span class="line"><span class="cl"><span class="c"># Th' title o' th' plank head'n will be postfixed by this HTML rrrambl'n</span>
</span></span><span class="line"><span class="cl"><span class="nx">headingPost</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
</span></span><span class="line"><span class="cl"><span class="c"># Th' title o' th' plank 'n menu will be prefixed by this HTML rrrambl'n</span>
</span></span><span class="line"><span class="cl"><span class="nx">menuPre</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
</span></span><span class="line"><span class="cl"><span class="c"># Th' title o' th' plank 'n menu will be postfixed by this HTML rrrambl'n</span>
</span></span><span class="line"><span class="cl"><span class="nx">menuPost</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
</span></span><span class="line"><span class="cl"><span class="c"># Hide a menu entry by sett'n this t' true</span>
</span></span><span class="line"><span class="cl"><span class="nx">hidden</span> <span class="p">=</span> <span class="kc">false</span>
</span></span><span class="line"><span class="cl"><span class="c"># Display name o' this plank modifier. If set, it will be displayed 'n th' footer.</span>
</span></span><span class="line"><span class="cl"><span class="nx">LastModifierDisplayName</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
</span></span><span class="line"><span class="cl"><span class="c"># Email o' this plank modifier. If set wit' LastModifierDisplayName, it will be displayed 'n th' footer</span>
</span></span><span class="line"><span class="cl"><span class="nx">LastModifierEmail</span> <span class="p">=</span> <span class="s2">&#34;&#34;</span>
</span></span><span class="line"><span class="cl"><span class="c"># Override default values fer image effects, ye can even add yer own arbitrary effects t' th' list</span>
</span></span><span class="line"><span class="cl"><span class="p">[</span><span class="nx">params</span><span class="p">.</span><span class="nx">imageEffects</span><span class="p">]</span>
</span></span><span class="line"><span class="cl"> <span class="nx">border</span> <span class="p">=</span> <span class="kc">false</span>
</span></span><span class="line"><span class="cl"> <span class="nx">lightbox</span> <span class="p">=</span> <span class="kc">true</span>
</span></span><span class="line"><span class="cl"> <span class="nx">shadow</span> <span class="p">=</span> <span class="kc">false</span>
</span></span><span class="line"><span class="cl"><span class="err">+++</span></span></span></code></pre></div><h3 id="add-icon-to-a-menu-entry">Add ay'con t' a menu entry</h3>
<p>In th' plank frontmatter, add a <code>menuPre</code> param t' insert any HTML code before th' menu label. Th' example below uses th' GitHub ay'con.</p>
<div class="wrap-code highlight"><pre tabindex="0" class="chroma"><code class="language-toml" data-lang="toml"><span class="line"><span class="cl"><span class="err">+++</span>
</span></span><span class="line"><span class="cl"><span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;GitHub repo&#34;</span>
</span></span><span class="line"><span class="cl"><span class="nx">menuPre</span> <span class="p">=</span> <span class="s2">&#34;&lt;i class=&#39;fab fa-github&#39;&gt;&lt;/i&gt; &#34;</span>
</span></span><span class="line"><span class="cl"><span class="err">+++</span></span></span></code></pre></div><p><a href="#R-image-272d6a3c6df0922f0e880b387779f82c" class="lightbox-link"><img src="../../../cont/pages/frontmatter-icon.png?width=18.75rem" alt="Title wit' icon" class="figure-image bg-white border lightbox noshadow" style="height: auto; width: 18.75rem;" loading="lazy"></a>
<a href="javascript:history.back();" class="lightbox-back" id="R-image-272d6a3c6df0922f0e880b387779f82c"><img src="../../../cont/pages/frontmatter-icon.png?width=18.75rem" alt="Title wit' icon" class="lightbox-image bg-white border lightbox noshadow" loading="lazy"></a></p>
<h3 id="ordering-sibling-menupage-entries">Order'n sibl'n menu/page entries</h3>
<p>Cap'n Hugo provides a <a href="https://gohugo.io/content/ordering/" target="_blank">flex'ble way</a> t' handle order fer yer planks.</p>
<p>Th' simplest way be t' set <code>weight</code> parameter t' a number.</p>
<div class="wrap-code highlight"><pre tabindex="0" class="chroma"><code class="language-toml" data-lang="toml"><span class="line"><span class="cl"><span class="err">+++</span>
</span></span><span class="line"><span class="cl"><span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;My page&#34;</span>
</span></span><span class="line"><span class="cl"><span class="nx">weight</span> <span class="p">=</span> <span class="mi">5</span>
</span></span><span class="line"><span class="cl"><span class="err">+++</span></span></span></code></pre></div><h3 id="using-a-custom-title-for-menu-entries">Us'n a custom title fer menu entries</h3>
<p>By default, th' Relearrrn theme will use a page&rsquo;s <code>title</code> attribute fer th' menu item (or <code>linkTitle</code> if defined).</p>
<p>But a page&rsquo;s title has t' be descriptive on its own while th' menu be a hierarchy.
We&rsquo;ve added th' <code>menuTitle</code> parameter fer that purpose:</p>
<p>For example (for a plank named <code>content/install/linux.md</code>):</p>
<div class="wrap-code highlight"><pre tabindex="0" class="chroma"><code class="language-toml" data-lang="toml"><span class="line"><span class="cl"><span class="err">+++</span>
</span></span><span class="line"><span class="cl"><span class="nx">title</span> <span class="p">=</span> <span class="s2">&#34;Install on Linux&#34;</span>
</span></span><span class="line"><span class="cl"><span class="nx">menuTitle</span> <span class="p">=</span> <span class="s2">&#34;Linux&#34;</span>
</span></span><span class="line"><span class="cl"><span class="err">+++</span></span></span></code></pre></div><h3 id="override-expand-state-rules-for-menu-entries">Override expand state rules fer menu entries</h3>
<p>Ye can change how th' theme expands menu entries on th' side o' th' rrrambl'n wit' th' <code>alwaysopen</code> sett'n on a per plank basis. If <code>alwaysopen=false</code> fer any given entry, its children will not be shown 'n th' menu as long as it be not necessary fer th' sake o' navigat'n.</p>
<p>Th' theme generates th' menu based on th' follow'n rules:</p>
<ul>
<li>all parent entries o' th' active plank includ'n their sibl'ns be shown regardless o' any sett'ns</li>
<li>immediate children entries o' th' active plank be shown regardless o' any sett'ns</li>
<li>if not overridden, all other first level entries behave like they would have been given <code>alwaysopen=false</code></li>
<li>if not overridden, all other entries o' levels besides th' first behave like they would have been given <code>alwaysopen=true</code></li>
<li>all vis'ble entries show their immediate children entries if <code>alwaysopen=true</code>; this proceeds recursively</li>
<li>all remain'n entries be not shown</li>
</ul>
<p>Ye can see this feature 'n act'n on th' example plank fer <a href="../../../shortcodes/children/index.html">children shortcode</a> an' its children planks.</p>
<h2 id="disable-section-pages">Dis'ble Sect'n Planks</h2>
<p>Ye may want t' structure yer planks 'n a hierachical way but don&rsquo;t want t' generate planks fer those sections? Th' theme got ye covered.</p>
<p>T' stay wit' th' initial example: Suppose ye want <code>level-one</code> appear 'n th' sidebar but don&rsquo;t want t' generate a plank fer it. So th' entry 'n th' sidebar should not be click'ble but should show an expander.</p>
<p>For this, open <code>content/level-one/_index.md</code> an' add th' follow'n frontmatter</p>
<div class="wrap-code highlight"><pre tabindex="0" class="chroma"><code class="language-toml" data-lang="toml"><span class="line"><span class="cl"><span class="nx">collapsibleMenu</span> <span class="p">=</span> <span class="kc">true</span> <span class="c"># this adds th' expander t' th' menu entry if not already set 'n yer config.toml</span>
</span></span><span class="line"><span class="cl"><span class="p">[</span><span class="nx">_build</span><span class="p">]</span>
</span></span><span class="line"><span class="cl"> <span class="nx">render</span> <span class="p">=</span> <span class="s2">&#34;never&#34;</span> <span class="c"># no plank will be generated so th' plank does not have a url</span></span></span></code></pre></div>
<footer class="footline">
</footer>
</article>
</div>
</main>
</div>
<script src="../../../js/clipboard.min.js?1701029991" defer></script>
<script src="../../../js/perfect-scrollbar.min.js?1701029991" defer></script>
<script src="../../../js/theme.js?1701029991" defer></script>
</body>
</html>