-
Notifications
You must be signed in to change notification settings - Fork 1
74 lines (63 loc) · 1.86 KB
/
release.yml
File metadata and controls
74 lines (63 loc) · 1.86 KB
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
73
74
name: release
on:
push:
tags:
- "v*"
jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: coursier/setup-action@v1.2.0
with:
jvm: temurin:1.21
apps: sbt
- uses: coursier/cache-action@v6
- uses: actions/setup-node@v4.2.0
with:
node-version: "22.15.0"
registry-url: "https://registry.npmjs.org"
- run: npm install -g npm@10.9.2
- name: Get tag
id: tag
uses: dawidd6/action-get-tag@v1
with:
#strip `v` prefix
strip_v: true
- name: Build Backend
working-directory: backend
run: |
sbt clean
sbt test:compile
- name: Tests Backend
working-directory: backend
run: sbt test
- name: Build Frontend
working-directory: frontend
run: |
npm ci
npm run build
- name: Test Frontend
working-directory: frontend
run: npm run test
# This env variable is used when we do Docs Publish
- name: Set JITPACK_VERSION environment variable
run: echo "JITPACK_VERSION=${{steps.tag.outputs.tag}}" >> $GITHUB_ENV
- name: Docs Publish
run: |
echo 'echo $RELEASE_TOKEN' > /tmp/.git-askpass
chmod +x /tmp/.git-askpass
git config --global user.email "actions@github.com"
git config --global user.name "Github Action"
sbt clean makeSite ghpagesPushSite
env:
RELEASE_TOKEN: ${{ secrets.RELEASE_TOKEN }}
GIT_ASKPASS: /tmp/.git-askpass
- name: Notify slack
if: always()
continue-on-error: true
uses: kpritam/slack-job-status-action@v1
with:
job-status: ${{ job.status }}
slack-bot-token: ${{ secrets.SLACK_BOT_TOKEN }}
channel: ci-release