summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.build.yml2
-rw-r--r--config.toml5
-rw-r--r--content/_index.md3
-rwxr-xr-xpublish.sh22
4 files changed, 26 insertions, 6 deletions
diff --git a/.build.yml b/.build.yml
index 26d6a6e..a51278f 100644
--- a/.build.yml
+++ b/.build.yml
@@ -15,4 +15,4 @@ tasks:
cd site
tar -C public -cvz . > ../site.tar.gz
- upload: |
- hut pages publish -d $site --site-config siteconfig.json site.tar.gz
+ hut pages publish -d $site --site-config site/siteconfig.json site.tar.gz
diff --git a/config.toml b/config.toml
index 9b58f5a..c907705 100644
--- a/config.toml
+++ b/config.toml
@@ -14,11 +14,8 @@ taxonomies = [
{ name = "tags", feed = true},
]
-[markdown]
-# Whether to do syntax highlighting
-# Theme can be customised by setting the `highlight_theme` variable to a theme supported by Zola
-highlight_code = false
+[markdown]
external_links_class = "external_link"
[extra]
diff --git a/content/_index.md b/content/_index.md
index 04fb732..523d3d0 100644
--- a/content/_index.md
+++ b/content/_index.md
@@ -7,7 +7,8 @@ Hi, I'm lemon. Welcome to my page. It's kind of barren at the moment.
## Links
- I have a [blog](/w).
-- My programming stuff is in [sourcehut](https://git.sr.ht/~lsof/), older stuff is in [github](https://github.com/lemon32767/).
+- My programming stuff is in [codeberg](https://codeberg.org/lsof), [sourcehut](https://git.sr.ht/~lsof/), older stuff is in [github](https://github.com/lemon32767/).
+ - [antcc](https://codeberg.org/lsof/antcc): a C compiler
- I have a [youtube channel](https://www.youtube.com/@lemon9bug).
- ![](/asset/link.png)
- [contact](/contact)
diff --git a/publish.sh b/publish.sh
new file mode 100755
index 0000000..aed9d88
--- /dev/null
+++ b/publish.sh
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+set -eox pipefail
+
+base="$(realpath $(dirname "$0"))"
+git checkout main
+hash="$(git rev-parse HEAD| head -c 12)"
+temp="/tmp/site-$hash"
+
+git push
+zola build
+cd /tmp
+git clone --branch pages "$base" "$temp"
+cd "$temp"
+git rm -r "*" || :
+cp -ar "$base"/public/* "$base"/.domains .
+git add --all
+git commit -m "Publish $hash" || :
+git remote add cb 'ssh://git@codeberg.org/lsof/pages.git'
+git push cb
+cd
+rm -rf "$temp"