-
Notifications
You must be signed in to change notification settings - Fork 185
40 lines (39 loc) · 1.36 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
name: deploy
on:
push:
branches:
- master
workflow_dispatch:
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set GitHub variables
run: |
export REPO_OWNER=$(echo $GITHUB_REPOSITORY | cut -d '/' -f1 | tr '[:upper:]' '[:lower:]')
if [ $REPO_OWNER = "supertuxkart" ]; then
export STK_URL="https://supertuxkart.net"
echo -n "supertuxkart.net" > CNAME
else
STK_URL="https://$REPO_OWNER.github.io"
STK_BASEURL="/$(basename $GITHUB_REPOSITORY)"
fi
echo "url: $STK_URL" >> _config.yml
echo "baseurl: $STK_BASEURL" >> _config.yml
echo "github:" >> _config.yml
echo " repository_url: https://github.com/$GITHUB_REPOSITORY" >> _config.yml
- uses: actions/cache@v4
with:
path: |
.asdf/**
vendor/bundle
key: ${{ runner.os }}-cache-${{ hashFiles('**/cache.key') }}
restore-keys: |
${{ runner.os }}-cache-
- uses: jeffreytse/[email protected]
with:
provider: 'github'
token: ${{ secrets.GITHUB_TOKEN }}
# For jekyll_picture_tag
pre_build_commands: pacman -S --noconfirm libvips lcms2 openjpeg2 libpng libwebp libheif imagemagick openslide libjxl poppler-glib