From dd1882b89da6a18e5df560516f77a75e3d2c0a5e Mon Sep 17 00:00:00 2001 From: Correl Roush Date: Mon, 26 Aug 2024 15:23:07 +0000 Subject: [PATCH] Add build workflow --- .forgejo/workflows/build.yaml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 .forgejo/workflows/build.yaml diff --git a/.forgejo/workflows/build.yaml b/.forgejo/workflows/build.yaml new file mode 100644 index 0000000..362ea86 --- /dev/null +++ b/.forgejo/workflows/build.yaml @@ -0,0 +1,21 @@ +on: + push: + branches: + - main +jobs: + build: + runs-on: docker + env: + hugo_version: "0.133.1" + hugo_destination: "public" + steps: + - working-directory: /tmp + run: | + wget https://github.com/gohugoio/hugo/releases/download/v${hugo_version}/hugo_extended_${hugo_version}_Linux-64bit.tar.gz + tar zxf hugo_extended_${hugo_version}_Linux-64bit.tar.gz + mv hugo /usr/local/bin/hugo + - uses: actions/checkout@v4 + - run: hugo -d ${hugo_destination} + - run: tar zcf /tmp/html.tar.gz ${hugo_destination} + - uses: actions/upload-artifact@v4 + path: /tmp/html.tar.gz