File: globaltoc.html

package info (click to toggle)
borgbackup 1.4.3-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 15,732 kB
  • sloc: python: 26,637; pascal: 3,245; ansic: 2,597; sh: 151; makefile: 137; tcl: 94
file content (20 lines) | stat: -rw-r--r-- 633 bytes parent folder | download | duplicates (9)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
<div class="sidebar-block">
  <div class="sidebar-toc">
    {# Restrict the sidebar toc depth to two levels while generating command usage pages.
       This avoids superfluous entries for each "Description" and "Examples" heading. #}
    {% if pagename.startswith("usage/") and pagename not in (
      "usage/general", "usage/help", "usage/debug", "usage/notes",
    ) %}
      {% set maxdepth = 2 %}
    {% else %}
      {% set maxdepth = 3 %}
    {% endif %}

    {% set toctree = toctree(maxdepth=maxdepth, collapse=True) %}
    {% if toctree %}
      {{ toctree }}
    {% else %}
      {{ toc }}
    {% endif %}
  </div>
</div>