From 68ec94a096918e656dff59e82f587561d61a55bd Mon Sep 17 00:00:00 2001 From: ebner Date: Wed, 1 Jul 2026 13:13:02 +0200 Subject: [PATCH] add gitea workflow to publish site --- .gitea/workflows/publish.yaml | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 .gitea/workflows/publish.yaml diff --git a/.gitea/workflows/publish.yaml b/.gitea/workflows/publish.yaml new file mode 100644 index 0000000..46daca1 --- /dev/null +++ b/.gitea/workflows/publish.yaml @@ -0,0 +1,33 @@ +name: Build and Publish Site + +on: + push: + branches: + - main + workflow_dispatch: + +jobs: + docker: + runs-on: ubuntu-latest-intranet + container: + image: gitea.psi.ch/images/alpine-zensical + steps: + - name: Checkout + uses: actions/checkout@v4 + + # - name: Build page + # run: /opt/python-env/bin/zensical build + + - name: Configure Git + run: | + git config --global user.name "Gitea Actions" + git config --global user.email "actions@gitea.local" + + - name: Push to gitea-pages branch + run: | + git checkout --orphan gitea-pages + git reset --hard + mv site/* . + git add . + git commit -m "Update site - $(date)" + git push -f https://${{ secrets.GITHUB_TOKEN }}@gitea.psi.ch/${{ github.repository }}.git gitea-pages