.dotfiles/.github/workflows/build-and-deploy.yaml
Leon Schwarzäugl 37a8e17cc9
Some checks failed
Build and Deploy / build (push) Has been cancelled
Flake check / Check flake (push) Has been cancelled
Build and Deploy / deploy (push) Has been cancelled
docs: improve a few sections
2026-01-11 02:04:14 +01:00

64 lines
1.5 KiB
YAML

name: Build and Deploy
on:
push:
branches:
- main
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: "pages"
cancel-in-progress: false
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install Emacs
run: |
sudo apt-get update
sudo apt-get install -y emacs-nox elpa-htmlize
- name: Prepare site images
run: |
mkdir -p site/files/topology
cp files/topology/topology_small.png site/files/topology/topology_small.png
- name: Tangle files & export to HTML
run: |
emacs --batch \
--eval "(require 'org)" \
--eval "(setq org-confirm-babel-evaluate nil
org-html-validation-link nil
org-export-headline-levels 6
org-export-with-broken-links 'mark)" \
--visit=SwarselSystems.org \
--funcall org-babel-tangle \
--funcall org-html-export-to-html
- name: Setup Pages
uses: actions/configure-pages@v4
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: 'site'
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4