summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Cleberg <[email protected]>2026-08-02 18:14:35 -0500
committerChristian Cleberg <[email protected]>2026-08-02 18:14:35 -0500
commit8780e8761da6b1eec5d686a25c9f673c22d974c6 (patch)
tree0bb327a0b42a28a38fd7a6c2830d6c68f1cddb87
parent3028f0d7da990bd3c0da515658dd5ab90dd9e1d4 (diff)
downloadkrz.sh-8780e8761da6b1eec5d686a25c9f673c22d974c6.tar.gz
krz.sh-8780e8761da6b1eec5d686a25c9f673c22d974c6.tar.bz2
krz.sh-8780e8761da6b1eec5d686a25c9f673c22d974c6.zip
add pre-push deploy hook; source links to git.krz.sh; fix app button color
- pre-push hook builds with zola and rsyncs public/ to homelab on main - wire core.hooksPath to tracked .githooks/ - point app source links at git.krz.sh instead of github - keep .prose btn text at --text/--btn-fg instead of link blue - drop dead github pages workflow (remote is self-hosted git now)
-rwxr-xr-x.githooks/pre-push28
-rw-r--r--.github/workflows/deploy.yml39
-rw-r--r--content/apps/_index.md2
-rw-r--r--content/apps/daybyday.md2
-rw-r--r--content/apps/domain-dig.md2
-rw-r--r--content/apps/hutch.md2
-rw-r--r--content/apps/solar.md2
-rw-r--r--sass/main.scss2
8 files changed, 35 insertions, 44 deletions
diff --git a/.githooks/pre-push b/.githooks/pre-push
new file mode 100755
index 0000000..7de897e
--- /dev/null
+++ b/.githooks/pre-push
@@ -0,0 +1,28 @@
+#!/usr/bin/env bash
+# Build with zola and deploy public/ to homelab on push to main.
+set -euo pipefail
+
+remote_host="homelab"
+remote_path="/var/www/krz.sh"
+
+# pre-push feeds "<local ref> <local sha> <remote ref> <remote sha>" per line.
+# Only deploy when main is being pushed (and not deleted).
+zero="0000000000000000000000000000000000000000"
+deploy=0
+while read -r local_ref local_sha remote_ref remote_sha; do
+ if [ "$remote_ref" = "refs/heads/main" ] && [ "$local_sha" != "$zero" ]; then
+ deploy=1
+ fi
+done
+
+if [ "$deploy" -eq 0 ]; then
+ exit 0
+fi
+
+echo "pre-push: building site with zola..."
+zola build
+
+echo "pre-push: deploying to ${remote_host}:${remote_path}..."
+rsync -az --delete public/ "${remote_host}:${remote_path}/"
+
+echo "pre-push: deploy complete."
diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml
deleted file mode 100644
index 50b0584..0000000
--- a/.github/workflows/deploy.yml
+++ /dev/null
@@ -1,39 +0,0 @@
-name: Deploy to GitHub Pages
-
-on:
- push:
- branches: [main]
- workflow_dispatch:
-
-permissions:
- contents: read
- pages: write
- id-token: write
-
-concurrency:
- group: pages
- cancel-in-progress: true
-
-jobs:
- build:
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v4
- - name: Build with Zola
- uses: shalzz/zola-deploy-action@master
- env:
- BUILD_ONLY: true
- BUILD_DIR: .
- - uses: actions/upload-pages-artifact@v3
- with:
- path: public
-
- deploy:
- needs: build
- runs-on: ubuntu-latest
- environment:
- name: github-pages
- url: ${{ steps.deployment.outputs.page_url }}
- steps:
- - id: deployment
- uses: actions/deploy-pages@v4
diff --git a/content/apps/_index.md b/content/apps/_index.md
index cb9674d..7226c39 100644
--- a/content/apps/_index.md
+++ b/content/apps/_index.md
@@ -7,4 +7,4 @@ page_template = "page.html"
+++
Native apps and privacy-respecting frontends. Each one is small, focused, and
-built to last. Source is on [GitHub](https://github.com/krazywarez).
+built to last. Source is at [git.krz.sh](https://git.krz.sh).
diff --git a/content/apps/daybyday.md b/content/apps/daybyday.md
index 46cb4d6..44b5c8b 100644
--- a/content/apps/daybyday.md
+++ b/content/apps/daybyday.md
@@ -4,7 +4,7 @@ description = "An educational iOS app that helps children learn the calendar."
weight = 5
[extra]
-link = "https://github.com/krazywarez/daybyday"
+link = "https://git.krz.sh/daybyday"
link_label = "Source"
appstore = "https://apps.apple.com/us/app/daybyday-learn/id6760321939"
privacy = "/privacy/daybyday/"
diff --git a/content/apps/domain-dig.md b/content/apps/domain-dig.md
index 496895f..8dfe1b9 100644
--- a/content/apps/domain-dig.md
+++ b/content/apps/domain-dig.md
@@ -4,7 +4,7 @@ description = "DNS and SSL analysis, in your pocket."
weight = 2
[extra]
-link = "https://github.com/krazywarez/domain-dig"
+link = "https://git.krz.sh/domain-dig"
link_label = "Source"
appstore = "https://apps.apple.com/us/app/domaindig/id6760368004"
privacy = "/privacy/domain-dig/"
diff --git a/content/apps/hutch.md b/content/apps/hutch.md
index 323cd88..68ea21b 100644
--- a/content/apps/hutch.md
+++ b/content/apps/hutch.md
@@ -4,7 +4,7 @@ description = "A native iOS client for SourceHut."
weight = 1
[extra]
-link = "https://github.com/krazywarez/hutch"
+link = "https://git.krz.sh/hutch"
link_label = "Source"
appstore = "https://apps.apple.com/us/app/hutch-for-sourcehut/id6760742299"
privacy = "/privacy/hutch/"
diff --git a/content/apps/solar.md b/content/apps/solar.md
index 7604d93..ef38650 100644
--- a/content/apps/solar.md
+++ b/content/apps/solar.md
@@ -4,7 +4,7 @@ description = "A native iOS client for Cloudflare."
weight = 3
[extra]
-link = "https://github.com/krazywarez/solar"
+link = "https://git.krz.sh/solar"
link_label = "Source"
privacy = "/privacy/solar/"
+++
diff --git a/sass/main.scss b/sass/main.scss
index 8f92cd7..b3e32b2 100644
--- a/sass/main.scss
+++ b/sass/main.scss
@@ -137,6 +137,8 @@ a:hover { text-decoration: underline; text-underline-offset: 3px; }
// ---- App page: actions + screenshots ---------------------------------------
.app-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; margin: 2rem 0 1rem; }
+.prose a.btn { color: var(--text); }
+.prose a.btn-primary { color: var(--btn-fg); }
.privacy-link { font-size: 0.9rem; margin: 0.25rem 0 0; }
.shots {