-
Notifications
You must be signed in to change notification settings - Fork 2
42 lines (39 loc) · 1 KB
/
deploy.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
---
name: "🚀 Deploy Call"
on:
push:
branches: [main]
tags: ["v*.*.*"]
workflow_dispatch: {}
env:
CLIENT_SECRET: ${{ secrets.CLIENT_SECRET }}
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 10
environment: production
steps:
- uses: actions/checkout@v4
with:
submodules: true
fetch-depth: 0
- name: Hugo setup
uses: peaceiris/[email protected]
with:
hugo-version: latest
extended: true
- uses: actions/cache@v4
with:
path: /tmp/hugo_cache
key: ${{ runner.os }}-hugomod-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-hugomod-
- run: hugo --minify
- uses: peaceiris/actions-gh-pages@v4
if: ${{ github.ref == 'refs/heads/main' }}
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./public