-
Notifications
You must be signed in to change notification settings - Fork 0
72 lines (59 loc) · 1.46 KB
/
release.yaml
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
name: vrunoa.me
on:
push:
tags:
- v*
env:
GH_TOKEN: ${{secrets.GH_TOKEN}}
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node version
uses: actions/setup-node@v1
with:
node-version: 16.x
- name: Install dependencies
run: npm install
- name: Build
run: npm run clear && npm run build
- name: Create tarball
run: |
pushd build
tar -cvf build.tar.gz ./*
popd
- name: Upload tarball
uses: actions/upload-artifact@v2
with:
name: buildtarball
path: |
./build/build.tar.gz
release:
needs: build
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v3
- name: Checkout gh-pages
run: |
git fetch
git checkout gh-pages
- name: Download saucectl binary
uses: actions/download-artifact@v2
with:
name: buildtarball
- name: Extract build
run: |
tar xvf build.tar.gz -C ./
rm -rf build.tar.gz
- name: Update page
run: |
git status
git config --global user.email "[email protected]"
git config --global user.name "vrunoa"
git add assets/*
git add blog/*
git commit -am "updating page"
git push origin gh-pages