What is this project?
maks.top โ a static site built with Hugo using a custom theme maks. No third-party themes or frameworks โ everything is written from scratch.
Hugo pipeline: how the site is built
content/ (markdown) โโโ
layouts/ (templates) โโโผโโโบ Hugo build โโโบ public/ โโโบ GitHub Pages
static/ (assets) โโโ
- Hugo reads
hugo.tomlโ site configuration - For each
.mdfile incontent/, it finds a matching template fromlayouts/ - The template inserts data from frontmatter +
.Content(markdown body) - Static files from
static/andthemes/maks/static/are copied as-is - The result โ a
public/folder with clean HTML/CSS/JS
Template lookup โ priority order
Hugo searches for a template in this order (first match wins):
| Page | Template lookup (in order) |
|---|---|
/posts/lpic2-200-1/ | layouts/posts/single.html โ layouts/_default/single.html |
/posts/linux-namespaces/ | layouts/posts/linux-namespaces.html โ layouts/posts/single.html |
/certs/ccna/ | layouts/certs/single.html โ layouts/_default/single.html |
/ccna-quiz/p01/ | layouts/ccna-quiz/single.html |
/ccna-quiz/ | layouts/ccna-quiz/list.html |
/about/ | layouts/about/single.html โ layouts/_default/single.html |
/ | layouts/index.html |
/posts/ | layouts/posts/list.html โ layouts/_default/list.html |
/tags/ | layouts/taxonomy/tag.html |
Key rule: a more specific path always overrides the default.
Directory structure
maks.top/
โ
โโโ hugo.toml # Site configuration
โ
โโโ content/ # Content (markdown)
โ โโโ about.md # /about/ page
โ โโโ posts/ # /posts/ section (blog)
โ โ โโโ lpic2-200-1-*.md # LPIC-2 articles
โ โ โโโ linux-namespaces.md # Interactive namespace explorer
โ โโโ certs/ # /certs/ section
โ โ โโโ ccna.md # CCNA cert page (accordion + resource tiles)
โ โ โโโ lpic-1.md, lpic-2.md # LPIC cert pages
โ โ โโโ network-engineer.md # OTUS course: 17 topics, 24 articles
โ โ โโโ aws-saa.md
โ โโโ ccna-quiz/ # /ccna-quiz/ section
โ โ โโโ _index.md # Quiz index page (49-tile grid)
โ โ โโโ p01.md โ p49.md # 489 questions, 10 per page, YAML frontmatter
โ โโโ kb/ # /kb/ section (quick references)
โ โ โโโ linux-network.md # ip, ss, tcpdump, nmcli, iptables
โ โ โโโ bash.md # Variables, arrays, loops, functions
โ โ โโโ text-processing.md # grep, awk, sed, cut, sort, xargs
โ โ โโโ filesystem.md # find, du/df, lsof, chmod, LVM
โ โ โโโ processes.md # ps, systemd, cron, journald
โ โ โโโ cisco-routing.md # OSPF/EIGRP/BGP IOS commands
โ โ โโโ cisco-switching.md # VLAN/STP/EtherChannel IOS commands
โ โ โโโ docker.md # run/build/compose/volumes
โ โ โโโ git.md # commit/rebase/stash/cherry-pick
โ โ โโโ aws-cli.md # EC2/S3/IAM/VPC commands
โ โ โโโ iptables-nftables.md # Firewall rules deep-dive
โ โ โโโ ssh.md # Keys/tunnels/config/rsync
โ โโโ docs/ # /docs/ section (this documentation)
โ
โโโ static/ # Global static files
โ โโโ img/quiz/ # 247 JPEG images extracted from CCNA PDF
โ โโโ roadmap/index.html # Static roadmap page (/roadmap/)
โ โโโ CNAME # Custom domain for GitHub Pages
โ
โโโ themes/maks/ # Custom theme
โโโ theme.toml # Theme metadata
โ
โโโ layouts/ # Hugo templates (Go templates)
โ โโโ index.html # Home page /
โ โโโ _default/
โ โ โโโ baseof.html # Base layout (wrapper for all pages)
โ โ โโโ single.html # Article with ToC and progress bar
โ โ โโโ list.html # Page listing with pagination
โ โโโ posts/
โ โ โโโ list.html # Blog listing + Pagefind search
โ โ โโโ linux-namespaces.html # Interactive namespace explorer
โ โโโ ccna-quiz/
โ โ โโโ list.html # Quiz index (49 page tiles)
โ โ โโโ single.html # Quiz page: questions, options, scoring
โ โโโ about/
โ โ โโโ single.html # About page with certs-widget
โ โโโ certs/
โ โ โโโ single.html # Cert overview: hero, resource tiles, accordion
โ โโโ taxonomy/
โ โ โโโ tag.html # Tags with interactive filtering
โ โโโ kb/
โ โ โโโ list.html # KB index grouped by Params.group
โ โโโ partials/ # Reusable fragments
โ โ โโโ certs-widget.html # Cert cards for About page
โ โ โโโ pagination.html # Dot-grid pagination (shared CSS in global.css)
โ โ โโโ breadcrumb.html # Breadcrumb navigation
โ โโโ shortcodes/ # Shortcode components for markdown
โ โโโ ns-card.html # Linux namespace card (uses --c variable)
โ โโโ code.html # Code block with Chroma highlighting
โ
โโโ static/ # Theme static files
โโโ js/
โ โโโ site.js # Global functions (theme, menu)
โ โโโ ns.js # Namespace explorer logic
โโโ styles/
โโโ global.css # Variables, nav, common components, pagination
โโโ home.css # Home page styles
โโโ prose.css # Article typography, NS cards, tabs, ref-panel
โโโ cert.css # Cert pages (hero, resource tiles, accordion)
โโโ quiz.css # CCNA quiz cards, options, scoring badges
โโโ ns.css # linux-namespaces page layout only
โโโ chroma.css # Syntax highlighting: Dracula (dark) / GitHub (light)
โโโ fonts.css # @font-face: Inter (body), JetBrains Mono, Unbounded
โโโ mobile.css # Mobile nav and breakpoints
Build pipeline: from push to live site
git push origin hugo
โ
โผ
GitHub Actions (.github/workflows/deploy.yml)
โ
โโโ actions/checkout@v4 # Clones repo with submodules
โโโ peaceiris/actions-hugo@v3 # Installs Hugo (latest, extended)
โโโ hugo --minify --gc # Builds site into public/
โ โโโ --minify: compresses HTML/CSS/JS
โ โโโ --gc: removes unused cache files
โโโ pagefind --site public # Indexes content for search
โโโ actions/upload-pages-artifact # Uploads public/ as artifact
โโโ actions/deploy-pages@v4 # Deploys to GitHub Pages
โ
โผ
https://maks.top/
(Fastly CDN + Let's Encrypt TLS + gzip)
hugo.toml โ key parameters
baseURL = "https://maks.top/" # Used for absolute links
languageCode = "en"
title = "maks.top"
theme = "maks" # References themes/maks/
paginate = 10 # Posts per page in listings
[params] # Available in templates as .Site.Params.*
author = "Maks"
description = "..."
location = "Sydney, AU"
github = "https://github.com/NickelFace"
linkedin = "..."
telegram = "..."
[taxonomies]
tag = "tags" # Tags: /tags/{tag-name}/
category = "categories" # Categories: /categories/{name}/
[outputs]
home = ["HTML"] # HTML only (no RSS, JSON)
section = ["HTML"]
page = ["HTML"]
[markup.goldmark.renderer]
unsafe = true # Allows raw HTML inside markdown
[markup.highlight]
noClasses = false # Class-based Chroma (CSS in chroma.css)
codeFences = true # Syntax highlight fenced code blocks
guessSyntax = true # Auto-detect language if not specified
lineNos = false
tabWidth = 2
How Hugo passes data to templates
Each template has access to . (dot) โ the current page context:
| Variable | Type | Description |
|---|---|---|
.Title | string | From frontmatter title: |
.Date | time.Time | From frontmatter date: |
.Content | template.HTML | Markdown body converted to HTML |
.Description | string | From frontmatter description: |
.Params | map | All custom frontmatter fields |
.Params.tags | []string | From frontmatter tags: |
.Permalink | string | Full page URL |
.RelPermalink | string | Relative URL |
.Section | string | Section: “posts”, “certs”, “ccna-quiz” |
.IsHome | bool | true only for the home page |
.Site | Site | Global site object |
.Site.Params | map | Parameters from [params] in hugo.toml |
.Site.RegularPages | []Page | All site pages |
.Site.Taxonomies.tags | Taxonomy | All tags with post counts |
.Paginator | Paginator | Pagination object (in list templates) |
Related pages
- Templates โ each layout file in detail
- CSS โ style architecture and class reference
- Frontmatter โ all fields by content type
- JavaScript โ functions and event listeners