Skip to content

change hugoVersion to 0.140.2 #42

change hugoVersion to 0.140.2

change hugoVersion to 0.140.2 #42

Workflow file for this run

name: Deploy public
on:
push:
branches: ["main"]
workflow_dispatch:
inputs:
hugoVersion:
description: 'Hugo version to use'
required: false
default: '0.128.0'
type: string
permissions:
contents: write
jobs:
build-and-deploy:
runs-on: ubuntu-latest
env:
HUGO_VERSION: ${{ inputs.hugoVersion || '0.140.2' }}
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Hugo
run: |
wget -O ${{ runner.temp }}/hugo.deb https://github.com/gohugoio/hugo/releases/download/v${{ env.HUGO_VERSION }}/hugo_extended_${{ env.HUGO_VERSION }}_linux-amd64.deb
sudo dpkg -i ${{ runner.temp }}/hugo.deb
- name: Build
run: hugo --minify --gc --cleanDestinationDir
- name: Deploy to public branch
uses: s0/git-publish-subdir-action@develop
env:
REPO: self
BRANCH: public
FOLDER: public
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MESSAGE: "Build: ({sha}) {msg}"
SQUASH_HISTORY: true