website/.forgejo/workflows/build.yaml
hoernschen 9c5843e800
Some checks failed
build-to-pages / build (push) Failing after 9s
build-to-pages / push (push) Failing after 2s
.forgejo/workflows/build.yaml aktualisiert
2023-10-22 19:31:49 +00:00

44 lines
No EOL
1.1 KiB
YAML

name: build-to-pages
on: [push]
branches: [main]
jobs:
build:
runs-on: docker
#env:
# HUGO_VERSION: 0.115.4
steps:
- name: Install Hugo CLI
run: apt update && apt install hugo -y
- name: Install Dart Sass
# run: sudo snap install dart-sass
run: hugo version
- uses: actions/checkout@v4
with:
submodules: recursive
- name: Build with Hugo
env:
# For maximum backward compatibility with Hugo modules
HUGO_ENVIRONMENT: production
HUGO_ENV: production
run: hugo --minify
- uses: actions/upload-artifact@v3
with:
name: hugo-output
path: ./public
if-no-files-found: error
push:
runs-on: docker
steps:
- uses: actions/checkout@v4
with:
ref: pages
- uses: actions/download-artifact@v3
with:
name: hugo-output
- run: ls -l
- run: |
git config user.name "forgejo-actions"
git config user.email ""
git add .
git commit -m "generated"
git push