Skip to content

Commit

Permalink
Update runners
Browse files Browse the repository at this point in the history
  • Loading branch information
miguelsolorio committed May 9, 2024
1 parent 5862368 commit 637e408
Showing 1 changed file with 10 additions and 27 deletions.
37 changes: 10 additions & 27 deletions .github/workflows/hugo.yml → .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Sample workflow for building and deploying a Hugo site to GitHub Pages
name: Deploy Hugo site to Pages
name: Build & Deploy Hugo site to GitHub Pages

on:
# Runs on pushes targeting the default branch
Expand Down Expand Up @@ -31,34 +31,17 @@ jobs:
build:
runs-on: ubuntu-latest
env:
HUGO_VERSION: 0.121.2
HUGO_VERSION: 0.115.2
steps:
- name: Install Hugo CLI
run: |
wget -O ${{ runner.temp }}/hugo.deb https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_linux-amd64.deb \
&& sudo dpkg -i ${{ runner.temp }}/hugo.deb
- name: Install Dart Sass
run: sudo snap install dart-sass
- name: Checkout
uses: actions/checkout@v4
- uses: actions/checkout@v3
- name: Use Node.js
uses: actions/setup-node@v3
with:
submodules: recursive
- name: Setup Pages
id: pages
uses: actions/configure-pages@v5
- name: Install Node.js dependencies
run: "[[ -f package-lock.json || -f npm-shrinkwrap.json ]] && npm ci || true"
- name: Build with Hugo
env:
# For maximum backward compatibility with Hugo modules
HUGO_ENVIRONMENT: production
HUGO_ENV: production
run: |
hugo \
--minify \
--baseURL "${{ steps.pages.outputs.base_url }}/"
node-version: 18.16
- run: npm install
- run: npm run export
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
uses: actions/upload-pages-artifact@v2
with:
path: ./public

Expand All @@ -72,4 +55,4 @@ jobs:
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
uses: actions/deploy-pages@v2

0 comments on commit 637e408

Please sign in to comment.