GithubHelp home page GithubHelp logo

kazzix14 / hugo-theme-anubis Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mitrichius/hugo-theme-anubis

0.0 0.0 0.0 356 KB

Anubis is a simple minimalist theme for Hugo blog engine

License: MIT License

HTML 58.74% CSS 41.26%

hugo-theme-anubis's Introduction

This is my fork of Anubis Theme for my blog License: MIT Donate

Anubis is a simple minimalist theme for Hugo blog engine.

Anubis Screenshot

Features

  • Dark mode (automatic / by switcher)
  • Pagination
  • Tags/Categories support
  • Archive
  • Open Graph and Twitter Cards support
  • Mobile support
  • Google Analytics
  • Disqus
  • RSS feeds
  • Translations (en, ru, fr, pl)
  • Custom CSS/JS
  • Multilingual mode
  • Robots.txt
  • Favorite posts
  • Pagination on post single page
  • Optional "Read more" link

Installation

Inside the folder of your Hugo site run:

$ git submodule add https://github.com/mitrichius/hugo-theme-anubis.git themes/anubis

For more information read the official setup guide of Hugo.

Getting started

After installing the theme successfully it requires a just a few more steps to get your site running.

Update config file

If you have toml config (which is by default), you should rename it to config.yaml or adapt this config for toml syntax.

Example of config.yaml:

languageCode: "en-us"
baseUrl: ""
title: "Anubis"
theme: "anubis"
paginate: 10
disqusShortname: yourdiscussshortname
googleAnalytics: UA-123-45
enableRobotsTXT: true

menu:
  main:
  - identifier: archive
    name: Archive
    title: Archive
    url: /posts/
    weight: 0

params:
  author: ""
  description: ""
  images:
    - images/og-featured.png # relative path to "static" directory
  customCSS:
    - css/my.css # relative path to "assets" directory (don't use main.css filename)
  customJS:
    - js/main.js # relative path to "assets" directory
  dateFormat: "2006-01-02"
  paginationSinglePost: true
  style: light-without-switcher
  readMore: false

markup:
  goldmark:
    renderer:
      unsafe: true # enable raw HTML in Markdown

Check your site

In order to see your site in action, run Hugo's built-in local server.

$ hugo server

Now enter localhost:1313 in the address bar of your browser.

Feature Settings

Dark Mode

Customize via style param in params section of config. Options:

  • light-without-switcher - light theme, without switcher, JS-free (by default)
  • dark-without-switcher - dark theme, without switcher, JS-free
  • auto-without-switcher - theme based on user system settings, without switcher, JS-free
  • light - light theme by default, can be switched by user to dark theme and back. Theme settings are saved for user
  • dark - dark theme by default, can be switched by user to light theme and back. Theme settings are saved for user
  • auto - theme based on user system settings by default, can be switched by user to dark/light theme. Theme settings are saved for user

Google Analytics

Only works for production environment. You either build your site with variable like HUGO_ENV=production hugo --minify or just put env: production to params section of config.

Multilingual mode

Check config/example usage in exampleSiteMultilingual directory and documentation on Hugo site.

Robots.txt

Based on environment.
For production — allow all, for other — disallow all.

Favorite posts

To mark posts as favorite just add favorite: true in post's front matter. It adds a "★" icon nearby post's title.

Pagination on post single page

Enabled by paginationSinglePost param in params section of config.

Contributing

If you find a bug or have an idea for a feature, feel free to write an issue or make a PR.

TODO

See issues.

License

MIT

© Dmitry Kolosov 2020

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.