Skip to content

Update theme

Update theme #6

Workflow file for this run

name: Deploy Hexo
on:
# Runs on pushes targeting the default branch
push:
branches: [ "mastar" ]
# Allows us to run this workflow manually from the Actions tab.
workflow_dispatch:
jobs:
# Build site.
build:
# Use Ubuntu to build. Considering Nix?
runs-on: ubuntu-latest
steps:
# See: https://github.com/actions/checkout.
- name: Checkout repository
uses: actions/checkout@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
submodules: false
- name: Install Nix
uses: cachix/install-nix-action@v27
with:
nix_path: nixpkgs=channel:nixos-24.11
- name: Cache NPM dependencies
uses: actions/cache@v4
with:
path: node_modules
key: ${{ runner.OS }}-npm-cache
restore-keys: ${{ runner.OS }}-npm-cache
- name: Build site
run: nix develop --command bash -c "pnpm install && hexo generate"
- name: Upload Pages artifact
uses: actions/upload-pages-artifact@v3
with:
path: ./public
# Deploy site to GitHub Pages.
deploy:
needs: build
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
# Specify runner + deployment step
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4