mirror of https://github.com/theNewDynamic/gohugo-theme-ananke.git

edit | blame | history | raw

Ananke, a starter theme for GoHugo

[!WARNING]
If you are experiencing issues with recent Hugo versions please check the Discussion about the layout changes and add your issues there. Thank you!

The intent of this theme is to provide a solid starting place for GoHugo sites with basic features and include best practices for performance, accessibility, and rapid development.

screenshot

DEMO

Features

  • Responsive
  • Accessible
  • Contact form
  • Custom Robots.txt (changes values based on environment)
  • Internal templates for meta data, google analytics, and DISQUS or COMMENTO comments
  • RSS Discovery
  • Table of Contents (must declare toc: true in post parameter)

Also includes examples of Hugo Features or Functions:

  • Pagination (internal template)
  • Taxonomies
  • Archetypes
  • Custom shortcode
  • Related content
  • Hugo built-in menu
  • i18n
  • with
  • first
  • after
  • sort
  • Site LanguageCode
  • where
  • Content Views
  • Partials
  • Template layouts (type "post" uses a special list template, single template, and a content view)
  • Tags
  • len
  • Conditionals
  • ge (greater than or equal to)
  • .Site.Params.mainSections to avoid hard-coding "blog," etc. [release note]

This theme uses the Tachyons CSS library. This will allow you to manipulate the design of the theme by changing class names in HTML without touching the original CSS files.

Compatibility

[!IMPORTANT]
The main branch contains the latest version of Ananke that is tested and working with GoHugo v0.146.0+. If you wish to use an older version of GoHugo, use the v2.12 branch that is working with GoHugo v0.128.1 to v0.145.0. To get the theme working with an even older version of GoHugo feel free to peruse the releases page to find a version that is working with your GoHugo version.

Installation

Dive into our documentation on installing the theme as GoHugo Module or Git Submodule. The official setup guide of GoHugo covers the installation of the theme as Git Submodule.

Getting started

After installing the theme successfully it requires a few more steps to get your site running. Read on for a quick overview of the most important steps. Or follow one of the more detailed guides following.

Latest Changes

See the CHANGELOG for details about what has changed recently. For a list of older changes, see the changelog-old.md file.

Contributing

If you find a bug feel free to use the issue tracker to let me know. If you are having issues setting up your site with the theme, or have an idea for a feature, please use the discussions for support.

Join me on my ananke-theme Discord channel for direct support, but please remember that I am doing this in my spare time.

If you would like to contribute code, please read the CONTRIBUTING.md file for guidelines on how to contribute.

edit | blame | history | raw

Changelog

2.12.1 (2025-05-13)

Documentation

Theme

  • fix: hyperlink text color on home different from other pages (cd83033)
  • fix: hyperlink text color on home different from other pages (on more layouts) (c789473)
  • fix: replace username only when given (1027ebf), closes #843
  • fix: use html.dir attribute configured in language setup (92ee7ad)

Refactors

  • move all template methods to proper GoHugo methods (1804711)
  • sort css classes (36503c4)

Build System

2.12.0 (2025-02-09)

Build System

  • fix: add release:minor script (0e25604)

2.11.3 (2025-02-09)

Content

  • fix: add Netlify demo site to theme.toml (33e51d6)
  • fix: use Hugo page on Wikipedia for sample link (50996e8)

Documentation

  • fix: fix Formspree free plan description (#774) (f5a5599)
  • fix: fix markdown in README.md (6454183)
  • fix: remove ref to 'Production' section in README (#778) (2247bc5)
  • fix: typos (#775) (61c3ec6)
  • fix: update wording in README.md (324da65)
  • remove comments about HUGO_ENV (e726c8b)

Theme

  • fix: add author bylines and fix author generation (3fc0dba), closes #623
  • fix: add show_recent_posts parameter to stop showing recent posts on index (#795) (b06949e), closes #123 #794
  • fix: move by.html into single.html (f672979)
  • fix: remove additional config load and some refactoring (1f4ac20)
  • fix: rework of the way the main sections for index.html are calculated (40fea59), closes #686
  • fix: social follow/share using new config (#821) (e64f74c), closes #808
  • fix: update module paths to v2 (4c02c19)

Refactors

  • codestyle: rewrite author meta tag generation (2bd232b)
  • using full file names for partials (5ab0adb)

Chore

  • cleanup workspace configuration (d6ef8f2)
  • config: update dependabot to monthly runs (6a77b14)
  • config: update gitignore (1839b4f)
  • fix: update PR template (02994de)
  • remove go.sum from exampleSite (1f83746)
  • setup: set GO_VERSION to 1.21 (0ba75ea)
  • setup: update gitignore file (799886d)
  • setup: update issue template (b119a21)
  • setup: update issue templates (294ab0b)

Configuration

  • improve configuration for example site (#786) (8d55b50)

Build System

CI

  • fix: remove CODEOWNERS structure (e8ccda0)
  • workflow: add CODEOWNERS for i18n (649eb22)

2.11.2 (2024-10-27)

Chore

2.11.0 (2024-10-24)

Chore

2.11.0 (2024-10-24)

2.10.1-prerelease.6 (2024-10-24)

Documentation

  • fix: update theme.toml with min version and authors (ae14ccf)

Theme

  • fix: add transform.Plainify to the summary body content of the share links (#758) (2cfb09e)
  • fix: paths to social func partials (1bcc471)
  • fix: remove caching of share links (#757) (473c7c1)

Chore

  • release: v2.10.1-prerelease.5 (aced7bd)

Configuration

  • fix: no default networks, move networks config to exampleSite (396d013)

2.10.1-prerelease.5 (2024-10-24)

Documentation

  • fix: update theme.toml with min version and authors (ae14ccf)

Theme

  • fix: add transform.Plainify to the summary body content of the share links (#758) (2cfb09e)
  • fix: paths to social func partials (1bcc471)

Configuration

  • fix: no default networks, move networks config to exampleSite (396d013)

2.10.1-prerelease.4 (2024-10-23)

Documentation

  • fix: add note about WIP on the README.md (0a307d7)
  • fix: update link to demo (e22c428)

Chore

  • deps: update dependencies (088c3e7)

Build System

2.10.1-prerelease.3 (2024-10-21)

Documentation

Theme

Chore

  • config: add markdownlint configuration (65c8a11)
  • release: v2.10.1-prerelease.1 (5afb33c)
  • release: v2.10.1-prerelease.2 (9332bad)

Build System

  • fix: proper replacement path (e8f39dd)

2.10.1-prerelease.2 (2024-10-21)

Documentation

Theme

  • fix: bring some logic into /disabled sharing (a9cd70d)
  • fix: proper configuration for all networks (9df0c0a)

Chore

  • config: add markdownlint configuration (65c8a11)
  • release: v2.10.1-prerelease.1 (5afb33c)

Build System

  • fix: proper replacement path (e8f39dd)

2.10.1-prerelease.1 (2024-10-21)

Documentation

Theme

  • fix: bring some logic into /disabled sharing (a9cd70d)
  • fix: proper configuration for all networks (9df0c0a)

Chore

  • config: add markdownlint configuration (65c8a11)

2.10.1-prerelease.0 (2024-10-20)

Content

  • fix: remove default value from front matter (d866e89)

Documentation

Theme

  • feat: social media follow links (4f3e709)
  • feat: social share links (wip) (d9f9cb5)
  • fix: add configs for various networks (e2360e7)
  • fix: add labels and label override functionality (7913086)
  • fix: cleanup unused functions (825ea52)
  • fix: hover color for social icons (14eeb65)
  • fix: making sure the noopener rel attribute stays even with other configurations (8762f56)
  • fix: override profile link generation with full link (9254c45)
  • fix: smaller config fixes for social media integration (ef4a6a0)

Refactors

  • removed a space (c018578)
  • Simplify lang attribute in html element (0b0fe2f)

Chore

  • config: update workspace configuration (0608f9f)
  • deps: update go module configuration (dcc979b)
  • git: merge pull request #738 from jmooring:simplify-lang-attribute (773f06c)
  • git: merge pull request #740 from theNewDynamic/fix/netlify-config (8e1a6dc)
  • git: revert last commit (1ff3417)

Configuration

  • fix: move paginate to pagination.pagerSize (deprecation) (363bd2e), closes #746

Build System

2.10.0 (2024-09-28)

2.10.0-prerelease.0 (2024-09-26)

Documentation

  • fix: add note about powershell environment (c1530b7)
  • fix: move old changelog (e086aa9)
  • fix: proper TOML format for frontmatter sample (#717) (ca6da48)
  • fix: remove todo note that can't be traced to any issue (b1f6a28)

Features

Theme

  • fix: replace deprecated resources.ToCSS with css.Sass (321680f), closes #712
  • i18n: add indonesian language (#672) (53463ff)

Refactors

  • indentation and file formatting changes (76460d7)

Chore

  • add package lockfile (8a7847f)
  • config: add dependabot configuration (3c3478a)
  • config: add github templates for issues and pull requests (7c5c9c3)
  • config: add resources to ignored files (549d735)
  • config: add workspace configuration file for vscode (1a4ad28)
  • config: move configuration into config subfolder structure and require 0.128.0 (4e613a9)
  • config: update dependencies and package.json content (d0490cb)
  • fix: being maintained again (9a0a974)
  • fix: full URL to discussion forum (791c400)

Build System

  • fix: add release scripts (a889122)
  • fix: recover build system (dccde1e)

older changelogs

Find older changelog entries in .github/changelog-old.md

edit | blame | history | raw

Contributing to Ananke

Thank you for your interest in improving the Ananke Hugo theme! Contributions of all kinds help keep the theme useful for the community. This document explains how to get started, what kinds of contributions we welcome, and how to collaborate effectively.

Types of Contributions

We welcome many forms of help, including:

  • Bug reports: Tell us about problems you encounter and steps to reproduce them.
  • Feature requests: Propose new capabilities or improvements to existing features.
  • Code contributions: Fix bugs, add features, or improve build tooling.
  • Documentation updates: Improve explanations, examples, or add missing details.
  • Translations: Enhance or correct strings in the i18n/ directory.

Getting Started

  1. Install Hugo extended version and ensure hugo version matches the version in config/_default/hugo.toml > min_version.
  2. Install Node.js dependencies for asset building: npm install.
  3. Run the development server with hugo server and open the served URL.

Contribution Process

Reporting Issues and Requesting Features

  • Use GitHub Issues to report bugs or GitHub Discussions to suggest enhancements.
  • Include clear steps to reproduce, expected versus actual behavior, and environment details (e.g., Hugo version (the output of hugo version), OS, browser).
  • Share screenshots or logs when relevant, but keep in mind to avoid sensitive information in public issues places.

Submitting Code Changes

  • Fork the repository and create a descriptive branch name (e.g., fix/menu-alignment).
  • Keep changes focused and prefer smaller, reviewable pull requests.
  • Create one pull request per logical change.
  • Follow the existing code style and structure; mirror patterns you see in layouts/, assets/, and static/ (this will be updated with a link to coding standards as soon as we have them).
  • Add or update documentation for any user-facing change.
  • Write or update tests where applicable, then run them locally before opening a PR. Common commands:
  • npm test for JavaScript-related checks.
  • hugo server and hugo to verify the site builds without errors.
  • Ensure commits have clear messages describing the intent. If your PR addresses an issue, reference it in the description (e.g., "Fixes #123").

Documentation Contributions

  • Update markdown files in README.md, config/, or relevant component docs to reflect your changes.
  • Keep examples minimal but complete, and prefer showing the final output or screenshot references when helpful.

Code of Conduct

Please review and follow the principles in the project's Code of Conduct (to be implemented). If you see behavior that violates these guidelines, report it through the project issue tracker or contact a maintainer privately.

Communication and Support

  • For general questions, open a discussion or issue on the repository.
  • For security concerns, please avoid public issues and reach out to a maintainer directly when possible.

Licensing

By contributing, you agree that your contributions will be licensed under the same terms as the project, as detailed in LICENSE.md.

edit | blame | history | raw

The MIT License (MIT)

Copyright (c) 2016-2024 Bud Parr

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

.github/ISSUE_TEMPLATE/bugs 1 KB
.github/changelog-old 14 KB
.github/pull_request_template 976 b
CHANGELOG 4 KB
LICENSE 1 KB
README 14 KB
archetypes/default 131 b
exampleSite/content/en/_index 446 b
exampleSite/content/en/about/index 922 b
exampleSite/content/en/contact 413 b
exampleSite/content/en/post/_index 226 b
exampleSite/content/en/post/chapter-1 5 KB
exampleSite/content/en/post/chapter-2 4 KB
exampleSite/content/en/post/chapter-3 6 KB
exampleSite/content/en/post/chapter-4 4 KB
exampleSite/content/en/post/chapter-5 4 KB
exampleSite/content/en/post/chapter-6 4 KB
exampleSite/content/fr/_index 330 b
exampleSite/content/fr/contact 452 b
exampleSite/content/fr/post/_index 95 b
exampleSite/content/fr/post/chapter-1 2 KB
layouts/robots 275 b