Skip to content

Update deploy_blog.yml #18

Update deploy_blog.yml

Update deploy_blog.yml #18

Workflow file for this run

name: Deploy to GitHub Page (Hackwiki Blog)
on:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Install Hugo
run: |
sudo apt install hugo
- name: Build Hugo Site
run: |
hugo -D
find public -name "*.html" | xargs sed -i '4i<meta name="theme-color" content="#6495ed" />'
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: ./public
deploy:
runs-on: ubuntu-latest
needs: build
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4