-
Notifications
You must be signed in to change notification settings - Fork 3
43 lines (43 loc) · 1.38 KB
/
ci.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
43
on:
pull_request:
push:
branches:
- main
- beta
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@v6
- uses: DeterminateSystems/magic-nix-cache-action@v2
- uses: iterative/setup-dvc@v1
with:
version: "2.58.2"
# DVC hack
- uses: de-vri-es/setup-git-credentials@v2
if: ${{ github.repository_owner == 'recap-utr' && github.event_name == 'push' }}
with:
credentials: ${{ secrets.GH_PULL_CREDENTIALS }}
- uses: jacobtomlinson/gha-find-replace@v3
if: ${{ github.repository_owner == 'recap-utr' && github.event_name == 'push' }}
with:
find: "[email protected]:"
replace: "https://github.com/"
regex: false
include: "**/*.dvc"
- run: dvc pull --force
- run: nix develop -c npm run test
release:
needs: test
runs-on: ubuntu-latest
if: ${{ github.repository_owner == 'recap-utr' && github.event_name == 'push' }}
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@v6
- uses: DeterminateSystems/magic-nix-cache-action@v2
- run: nix profile install .#releaseEnv
- uses: cihelper/action-semanticrelease-npm@v1
with:
npm-token: ${{ secrets.NPM_TOKEN }}
npm-install: true