Skip to content

release_event

release_event #6

Workflow file for this run

# This is a basic workflow to help you get started with Actions
name: CI
# Controls when the action will run. Triggers the workflow on push or pull request
# events but only for the master branch
on:
# push:
# branches: [ main ]
# pull_request:
# branches: [ main ]
repository_dispatch:
events:
[ release_event ]
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
deploy:
# The type of runner that the job will run on
runs-on: ubuntu-22.04
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
with:
submodules: recursive # Fetch the Docsy theme
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
- name: Download Markdown Files
run: |
./get_latest_md.sh ${{ github.event.client_payload.artifact_download_url }}
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: '^1.13.1' # The Go version to download (if necessary) and use.
- run: go version
- name: Setup Hugo
uses: peaceiris/actions-hugo@v3
with:
hugo-version: '0.120.4'
extended: true
- name: Setup Node
uses: actions/setup-node@v1
with:
node-version: '20.x'
- run: npm install
# - name: Install pandoc
# run: sudo apt-get install pandoc
# - name: Cache dependencies
# uses: actions/cache@v1
# with:
# path: ~/.npm
# key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
# restore-keys: |
# ${{ runner.os }}-node-
- name: Build
run: hugo --minify
# - run: ls -l ./public
- name: Deploy
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./public
# keep_files: true
publish_branch: gh-pages