-
Notifications
You must be signed in to change notification settings - Fork 10
116 lines (97 loc) · 3.45 KB
/
release.yml
File metadata and controls
116 lines (97 loc) · 3.45 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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
name: release
on:
push:
tags:
- "v*"
jobs:
release:
runs-on: ubuntu-latest
env:
CSW_VERSION: "6.0.0"
ESW_OCS_ENG_UI_VERSION: "1.0.0"
steps:
- uses: actions/checkout@v4
- uses: coursier/setup-action@v1.2.0
with:
jvm: temurin:1.21
apps: sbt sbtn
- uses: coursier/cache-action@v6
- uses: actions/setup-node@v1
with:
node-version: "22.14.0"
registry-url: "https://registry.npmjs.org"
- name: Install Redis
run: sudo apt-get install redis-server
- name: Install Kotlin
run: |
curl -s https://get.sdkman.io | bash
source "/home/runner/.sdkman/bin/sdkman-init.sh"
sdk install kotlin
sudo ln -s $(which kotlinc) /usr/local/bin/kotlinc
- run: npm install -g junit-merge
- run: npm install -g junit-viewer
- name: Get tag
id: tag
uses: dawidd6/action-get-tag@v1
with:
#strip `v` prefix
strip_v: true
- name: Build
run: |
sbtn clean
sbtn scalafmtCheck
sbt -DenableFatalWarnings=false makeSite
- name: Tests
run: sbt -Dsbt.log.noformat=true -Dpekko.actor.serialize-messages=on -DenableCoverage=true -DgenerateStoryReport=true Test/test
- name: Coverage Report
run: |
sbt -Dsbt.log.noformat=true -DenableCoverage=true coverageReport
sbtn coverageAggregate
- name: Upload Coverage Report
uses: actions/upload-artifact@v4
with:
name: Coverage Report
path: target/scala-3.6.4/scoverage-report
- name: Delete js targets
continue-on-error: true
run: find . -type d -regex ".*js/target.*" | xargs rm -rf
- name: Multi-Jvm Tests
run: sbt -DgenerateStoryReport=true esw-integration-test/multi-jvm:test
- name: Generate RTM
if: always()
continue-on-error: true
run: |
cs launch --channel https://raw.githubusercontent.com/tmtsoftware/osw-apps/branch-6.0.x/apps.json rtm:0.4.3 -- target/RTM/testStoryMapping.txt tools/RTM/storyRequirementMapping.csv target/RTM/testRequirementsMapping.txt
- name: Upload RTM
if: always()
continue-on-error: true
uses: actions/upload-artifact@v4
with:
name: RTM
path: target/RTM
# This env variable is used when we do Docs Publish and this step should be after
# running integration tests as they require 0.1.0-SNAPSHOT version to do publishLocal
- name: Set JITPACK_VERSION environment variable
run: echo "JITPACK_VERSION=${{steps.tag.outputs.tag}}" >> $GITHUB_ENV
- name: Github Release
run: sbt githubRelease
env:
GITHUB_TOKEN: ${{ secrets.RELEASE_TOKEN }}
- 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 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