-
Notifications
You must be signed in to change notification settings - Fork 1
121 lines (115 loc) · 3.16 KB
/
clojure.yml
File metadata and controls
121 lines (115 loc) · 3.16 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
117
118
119
120
121
name: Clojure CI
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
merge_group:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
name: Check out repository
- uses: actions/setup-node@v4
name: Set up Node
with:
node-version: lts/*
cache: npm
- uses: actions/setup-java@v4
name: Set up Java
with:
distribution: temurin
java-version: 21
- uses: actions/setup-python@v4
name: Set up Python
with:
python-version: 3.12
cache: pip
- uses: actions/cache@v3
name: pre-commit cache
with:
path: ~/.cache/pre-commit
key: ${{ runner.os }}-pre-commit-${{ hashFiles('.pre-commit-config.yaml') }}
- uses: actions/cache@v3
name: Clojure cache
with:
path: |
~/.m2/repository
~/.gitlibs
~/.clojure
~/.cpcache
key: ${{ runner.os }}-clojure-${{ hashFiles('deps.edn') }}
- name: Install Clojure tools
uses: DeLaGuardo/setup-clojure@13
with:
cli: latest
bb: latest
clj-kondo: 2026.01.19
cljstyle: 0.15.0
- name: Run pre-commit hooks
run: |
pip install -r requirements.txt
SKIP=kaocha-test pre-commit run --all-files
- name: Run tests
run: |
npm install
bin/kaocha
- name: Upload coverage artifact
if: always()
uses: actions/upload-artifact@v4
with:
name: coverage-report
path: target/coverage
if-no-files-found: warn
- name: Upload JUnit XML artifact
if: always()
uses: actions/upload-artifact@v4
with:
name: junit-xml
path: target/test-results/junit.xml
if-no-files-found: warn
spec-parity:
runs-on: ubuntu-latest
env:
SQIDS_SPEC_DIR: ${{ github.workspace }}/target/sqids-spec
steps:
- uses: actions/checkout@v3
name: Check out repository
- uses: actions/checkout@v3
name: Check out sqids-spec
with:
repository: sqids/sqids-spec
ref: main
path: target/sqids-spec
- uses: actions/setup-node@v4
name: Set up Node
with:
node-version: lts/*
cache: npm
cache-dependency-path: |
package-lock.json
target/sqids-spec/package-lock.json
- uses: actions/setup-java@v4
name: Set up Java
with:
distribution: temurin
java-version: 21
- uses: actions/cache@v3
name: Clojure cache
with:
path: |
~/.m2/repository
~/.gitlibs
~/.clojure
~/.cpcache
key: ${{ runner.os }}-clojure-${{ hashFiles('deps.edn') }}
- name: Install Clojure tools
uses: DeLaGuardo/setup-clojure@13
with:
cli: latest
- name: Install sqids-spec dependencies
working-directory: target/sqids-spec
run: npm ci
- name: Run sqids-spec parity
run: bin/parity