Skip to content

Commit a126da0

Browse files
authored
migrate to zola (#4)
1 parent c6fa486 commit a126da0

28 files changed

Lines changed: 986 additions & 343 deletions

.github/workflows/hugo.yaml

Lines changed: 0 additions & 78 deletions
This file was deleted.

.github/workflows/zola.yaml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
name: Deploy Zola site to Pages
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
workflow_dispatch:
8+
9+
permissions:
10+
contents: read
11+
pages: write
12+
id-token: write
13+
14+
concurrency:
15+
group: "pages"
16+
cancel-in-progress: false
17+
18+
defaults:
19+
run:
20+
shell: bash
21+
22+
jobs:
23+
build:
24+
runs-on: ubuntu-latest
25+
env:
26+
ZOLA_VERSION: 0.21.0
27+
steps:
28+
- name: Checkout
29+
uses: actions/checkout@v4
30+
with:
31+
fetch-depth: 0
32+
- name: Setup Pages
33+
id: pages
34+
uses: actions/configure-pages@v5
35+
- name: Install Zola
36+
run: |
37+
curl -L "https://github.com/getzola/zola/releases/download/v${ZOLA_VERSION}/zola-v${ZOLA_VERSION}-x86_64-unknown-linux-gnu.tar.gz" -o zola.tar.gz
38+
tar -xzf zola.tar.gz
39+
sudo mv zola /usr/local/bin/zola
40+
- name: Build with Zola
41+
env:
42+
TZ: America/Toronto
43+
run: |
44+
zola build \
45+
--base-url "${{ steps.pages.outputs.base_url }}/"
46+
- name: Upload artifact
47+
uses: actions/upload-pages-artifact@v3
48+
with:
49+
path: ./public
50+
51+
deploy:
52+
environment:
53+
name: github-pages
54+
url: ${{ steps.deployment.outputs.page_url }}
55+
runs-on: ubuntu-latest
56+
needs: build
57+
steps:
58+
- name: Deploy to GitHub Pages
59+
id: deployment
60+
uses: actions/deploy-pages@v4

.gitignore

Lines changed: 10 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,15 @@
1-
# Ignore the public directory where Hugo builds the site
1+
# Zola build output
22
/public/
33

4-
# Ignore the Hugo cache
5-
/.hugo_cache/
4+
# Zola cache
5+
/.zola-cache/
66

7-
# Ignore Hugo build lock file
8-
/.hugo_build.lock
7+
# Sass cache
8+
/.sass-cache/
99

10-
# Ignore Hugo generated resources
11-
/resources/_gen/
12-
13-
# Ignore temporary files created by the editor
14-
*.swp
15-
*.swo
16-
*.bak
17-
*.tmp
18-
*~
19-
20-
# Ignore IDE files
21-
.vscode/
22-
.idea/
23-
24-
# Ignore the node_modules directory
25-
node_modules/
26-
27-
# Ignore OS-specific files
28-
.DS_Store # macOS
29-
Thumbs.db # Windows
10+
# OS/editor files
11+
.DS_Store
12+
Thumbs.db
3013

14+
# Zola generated syntax highlight CSS
15+
/static/syntax-theme-*.css

.gitmodules

Whitespace-only changes.

Justfile

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,25 @@
1-
21
# list commands
32
default:
4-
just --list
3+
just --list --unsorted
54

65
# build with drafts and serve locally
76
serve:
8-
hugo serve --buildDrafts --disableFastRender
7+
zola serve --drafts --interface 127.0.0.1 --port 1111
98

109
# build release site and serve locally
1110
serve-release:
12-
hugo --cleanDestinationDir serve
11+
zola serve --interface 127.0.0.1 --port 1111
12+
13+
# build site (includes drafts)
14+
build:
15+
zola build --drafts
16+
17+
# build release site
18+
build-release:
19+
zola build
1320

14-
# new post, e.g. "just new 2025/my-title.md", or "just new 2025/my-title" for a folder
21+
# new post, e.g. "just new 2025/my-title" or "just new my-title"
1522
new title:
16-
hugo new content content/posts/{{title}}
23+
@mkdir -p "content/posts/$(dirname "{{title}}")"
24+
@printf '+++\ntitle = "%s"\ndate = %s\ndraft = true\n+++\n\n' "{{title}}" "$(date -Iseconds)" > "content/posts/{{title}}.md"
25+
@echo "Created content/posts/{{title}}.md"

archetypes/default.md

Lines changed: 0 additions & 5 deletions
This file was deleted.

config.toml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
base_url = "https://kzuberi.github.io"
2+
title = "kzuberi.github.io"
3+
description = ""
4+
default_language = "en"
5+
theme = "kz-theme"
6+
build_search_index = false
7+
generate_feeds = true
8+
feed_filenames = ["rss.xml"]
9+
10+
taxonomies = [
11+
{ name = "tags" },
12+
]
13+
14+
[markdown]
15+
highlight_code = true
16+
highlight_theme = "css"
17+
highlight_themes_css = [
18+
{ theme = "base16-ocean-light", filename = "syntax-theme-light.css" },
19+
{ theme = "base16-ocean-dark", filename = "syntax-theme-dark.css" },
20+
]
21+
render_emoji = false
22+
23+
[extra]
24+
default_theme = "auto"
25+
show_theme_toggle = true
26+
show_top_link = true
27+
menu = [
28+
{ name = "Tags", url = "/tags/" },
29+
{ name = "About", url = "/about/" },
30+
]

content/about.md

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
1-
---
2-
title: "About"
3-
date: 2025-03-22T17:51:49-04:00
4-
draft: false
5-
---
1+
+++
2+
title = "About"
3+
date = 2025-03-22T17:51:49-04:00
4+
draft = false
5+
+++
66

7-
Coding in the vicinity of Science. Computational-biology, bioinformatics, fast-fading memories of remote sensing and still dimmer recollections of numerical analysis.
7+
Coding in the vicinity of Science. Computational-biology, bioinformatics, fast-fading memories of remote sensing and still dimmer recollections of numerical analysis.
8+
9+
Contact by [email](mailto:kzthisthat@gmail.com).

content/posts/2025/_index.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
+++
2+
transparent = true
3+
+++

content/posts/2025/first-post.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
title = 'First Post'
33
date = 2025-03-12T20:48:08-04:00
44
draft = true
5+
taxonomies = { tags = ["notes"] }
56
+++
67

7-
Nothing to see here, yet.
8+
Nothing to see here, yet.

0 commit comments

Comments
 (0)