Information

01 Jan 2024

Usage guide

1 minute reading time

Updated 01 Feb 2024

#Features

Halve-Z is a retro two-column theme for Zola. It features search, taxonomies, automatic color schemes, media shortcodes, project cards, and a comment system (Cactus/Giscus).

#Front matter

Available (extra) options:

h1 headers are reserved for page title (left/top block) and subtitle (optional, right/bottom block).

In addition to default variables, a page can have an image, a subtitle, a category, a song, CSP strings, and multiple tags.

+++
title = "Example"
date = 2009-09-09
[taxonomies]
categories = ["general"]
tags = ["tag"]
[extra]
subtitle = "Example subtitle"
disable_comments = true
disable_toc = true
image = "https://example.com/image.png"
csp_img = ["example.com/", "foo.org/example"]
song = ["Michael Pitt", "Death to Birth"]
+++

song variable takes an array that includes an artist and a track name. If LASTFM_KEY environment variable is present, names are autocorrected and linked to the Last.fm website.

#Configuration

Set theme to halve-z in your project's config.toml and adjust options according to the example below:

###
base_url = "https://halve-z.netlify.app"
title = "Halve-Z Zola theme"
description = "Two-column retro theme for Zola"
default_language = "en"
author = "charlesrocket"
#theme = "halve-z"

compile_sass = true
minify_html = true
generate_feeds = true
build_search_index = true

taxonomies = [
    { name = "categories", feed = true },
    { name = "tags", feed = true },
]

[search]
include_title = true
include_description = true
include_path = false
include_content = true
index_format = "elasticlunr_json"

[markdown]
highlight_code = true
highlight_theme = "css"
highlight_themes_css = [
    { theme = "OneHalfDark", filename = "syntax-theme-dark.css" },
    { theme = "OneHalfLight", filename = "syntax-theme-light.css" },
]
render_emoji = false
external_links_target_blank = true

[slugify]
paths = "safe"
taxonomies = "safe"
anchors = "safe"

[extra]
locale = "en_US"
logo = "icon-192x192.png"
manifest = "manifest.json"
read_time = true
toc = true
csp = true

[extra.placeholders]
tags = false
subtitle = false

[extra.home]
title = "Halve-Z"
subtitle = "Zola theme"
glitch = false
logo = { enabled = false, height = "100", width = "100" }
footer = true

[extra.images]
home = "c1tyh4ll.png" #https://failsafe.monster/c1tyh4ll.png
post_list = "bk-prk.png" #https://failsafe.monster/bk-prk.jpg
default_post = "bk-prk.png" #https://failsafe.monster/bk-prk.jpg
categories = [
    { name = "media", image = "https://raw.githubusercontent.com/bearcott/8bit-art/master/cities/urban.gif" },
]

[extra.menu]
posts = true
posts_label = "Posts"
links = [
    { name = "Code", url = "@/pages/projects.md" },
]

[extra.footer]
enabled = true
author = true
copyright = true
hash = true
stack = true
links = [
    { name = "sitemap", url = "sitemap.xml" },
    { name = "posts", url = "@/posts/_index.md" },
]

[extra.social]
email = "user_email"
mastodon = "server/@user_name"
twitter = "user_name"
facebook = "user_name"
codeberg = "username"
github = "user_name"
gitlab = "user_name"
bitbucket = "user_name"
stackoverflow = "12345/user_name"
linkedin = "user_name"
instagram = "user_name"
lastfm = "user_name"
twitch = "user_name"
reddit = "user_name"
#flickr = "user_name"
keybase = "user_name"
hackernews = "user_name"

[extra.comments]
system = "none"

[extra.comments.cactus]
site = "site_name"
page_size = 10
guest_posting = true
update_interval = 0

[extra.comments.giscus]
repo = "user_name/repo"
repo_id = ""
category = "Comments"
category_id = ""
mapping = "pathname"
strict = "1"
reactions = "1"
lang = "en"