ficd.sh/.build.yml

30 lines
751 B
YAML

image: alpine/edge
oauth: pages.sr.ht/PAGES:RW
packages:
- hut
- uv
environment:
site: ficd.ca
tasks:
- build: |
if [ "$GIT_REF" = "refs/heads/main" ]; then
cd ficd-zona
uv run --with 'git+https://git.sr.ht/~ficd/zona@9f38b16d0cd9e2761936fc089735ae911bf06624' zona build
else
echo "Skipping build: not on main"
fi
- package: |
if [ "$GIT_REF" = "refs/heads/main" ]; then
cd ficd-zona/public
tar -cvz . > ../public.tar.gz
else
echo "Skipping package: not on main"
fi
- upload: |
if [ "$GIT_REF" = "refs/heads/main" ]; then
hut pages publish -d "$site" ficd-zona/public.tar.gz
else
echo "Skipping upload: not on main"
fi