File tree Expand file tree Collapse file tree 1 file changed +82
-0
lines changed
Expand file tree Collapse file tree 1 file changed +82
-0
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ name : Mixin
3+
4+ permissions :
5+ contents : read
6+
7+ on :
8+ # To conserve resources we only run tests against main in PRs
9+ pull_request :
10+ branches :
11+ - master
12+
13+ jobs :
14+ check-for-changed-mixins :
15+ name : Check for changes
16+ runs-on : ubuntu-latest
17+ outputs :
18+ changed-mixins : ${{ steps.changed-mixins.outputs.all_changed_files }}
19+ steps :
20+ - name : Checkout
21+ uses : actions/checkout@v4
22+ with :
23+ fetch-depth : 0
24+
25+ - name : Setup Go
26+ uses : actions/setup-go@v5
27+ with :
28+ go-version : 1.18
29+
30+ - name : Install CI dependencies
31+ run : make install-ci-deps
32+
33+ - name : Get changed mixins
34+ id : changed-mixins
35+ uses : tj-actions/changed-files@v44
36+ with :
37+ dir_names : true
38+ dir_names_exclude_current_dir : true
39+ dir_names_max_depth : 1
40+ files : |
41+ **-mixin/
42+ **-observ-lib/
43+ matrix : true
44+
45+ - name : List all changed mixins
46+ run : echo '${{ steps.changed-mixins.outputs.all_changed_files }}'
47+
48+ lint-mixin :
49+ name : Run Mixtool
50+ runs-on : ubuntu-latest
51+ permissions :
52+ issues : write
53+ contents : write
54+ pull-requests : write
55+ repository-projects : write
56+ timeout-minutes : 15
57+ needs : [check-for-changed-mixins]
58+ strategy :
59+ matrix :
60+ mixin : ${{ fromJSON(needs.check-for-changed-mixins.outputs.changed-mixins) }}
61+ fail-fast : false
62+ steps :
63+ - name : Checkout
64+ uses : actions/checkout@v4
65+ with :
66+ fetch-depth : 0
67+
68+ - name : Setup Go
69+ uses : actions/setup-go@v5
70+ with :
71+ go-version : 1.18
72+
73+ - name : Install CI dependencies
74+ run : make install-ci-deps
75+
76+ - name : Install Mixin dependencies
77+ working-directory : ./${{ matrix.mixin }}
78+ run : jb install
79+
80+ - name : Lint Mixin
81+ working-directory : ./${{ matrix.mixin }}
82+ run : mixtool lint mixin.libsonnet
You can’t perform that action at this time.
0 commit comments