@@ -37,39 +37,67 @@ jobs:
3737 components : rustfmt
3838 - name : Check code formatting
3939 run : cargo fmt --check
40- clippy :
40+
41+ clippy_packages :
4142 runs-on : ubuntu-latest
42- name : ${{ matrix.toolchain }} / clippy
43+ name : ${{ matrix.toolchain }} / ${{ matrix.package }} / clippy
4344 permissions :
4445 contents : read
4546 checks : write
4647 strategy :
4748 fail-fast : false
4849 matrix :
4950 toolchain : [ stable, beta ]
51+ package : [ config-migrate, fs, license, nr-auth, resource-detection ]
5052 steps :
5153 - uses : actions/checkout@v4
5254 with :
5355 submodules : true
56+
5457 - name : Give GitHub Actions access to private crates
5558 uses :
webfactory/[email protected] 5659 with :
5760 ssh-private-key : ${{ secrets.CAOS_RUST_CRATES }}
61+
5862 - name : Install ${{ matrix.toolchain }}
59636064 with :
6165 toolchain : ${{ matrix.toolchain }}
6266 components : clippy
63- - name : cargo clippy
64- uses : actions-rs/clippy-check@v1
67+
68+ - name : cargo clippy ${{ matrix.package }}
69+ run : cargo clippy --package ${{ matrix.package }} --message-format=json --tests -- -D clippy::all
70+
71+ clippy_super_agent :
72+ runs-on : ubuntu-latest
73+ name : ${{ matrix.toolchain }} / ${{ matrix.feature }} / clippy
74+ permissions :
75+ contents : read
76+ checks : write
77+ strategy :
78+ fail-fast : false
79+ matrix :
80+ toolchain : [ stable, beta ]
81+ feature : [ onhost, k8s ]
82+ steps :
83+ - uses : actions/checkout@v4
6584 with :
66- token : ${{ secrets.GITHUB_TOKEN }}
67- args : --features=onhost -- -D clippy::all
68- - name : cargo clippy
69- uses : actions-rs/clippy-check@v1
85+ submodules : true
86+
87+ - name : Give GitHub Actions access to private crates
88+ uses :
webfactory/[email protected] 7089 with :
71- token : ${{ secrets.GITHUB_TOKEN }}
72- args : --features=k8s --tests -- -D clippy::all
90+ ssh-private-key : ${{ secrets.CAOS_RUST_CRATES }}
91+
92+ - name : Install ${{ matrix.toolchain }}
93+ 94+ with :
95+ toolchain : ${{ matrix.toolchain }}
96+ components : clippy
97+
98+ - name : cargo clippy super agent (${{ matrix.feature }})
99+ run : cargo clippy --package newrelic_super_agent --features=${{ matrix.feature }} --message-format=json --tests -- -D clippy::all
100+
73101 doc :
74102 runs-on : ubuntu-latest
75103 name : stable / doc
@@ -84,36 +112,66 @@ jobs:
84112 - name : Install nightly
8511386114 - name : Create on-host documentation
87- run : cargo doc --no-deps --features=onhost
115+ run : cargo doc --no-deps --features=onhost --package newrelic_super_agent
88116 env :
89117 RUSTDOCFLAGS : --cfg docsrs
90118 - name : Create K8s documentation
91- run : cargo doc --no-deps --features=k8s
119+ run : cargo doc --no-deps --features=k8s --package newrelic_super_agent
92120 env :
93121 RUSTDOCFLAGS : --cfg docsrs
94- msrv :
122+
123+ # msrv = Minimum Supported Rust Version
124+ msrv_super_agent :
125+ runs-on : ubuntu-latest
126+ strategy :
127+ matrix :
128+ msrv : [ 1.78.0 ]
129+ feature : [ onhost, k8s ]
130+ name : ubuntu / ${{ matrix.msrv }} / ${{ matrix.feature }}
131+ steps :
132+ - uses : actions/checkout@v4
133+ with :
134+ submodules : true
135+
136+ - name : Give GitHub Actions access to private crates
137+ uses :
webfactory/[email protected] 138+ with :
139+ ssh-private-key : ${{ secrets.CAOS_RUST_CRATES }}
140+
141+ - name : Install ${{ matrix.msrv }}
142+ 143+ with :
144+ toolchain : ${{ matrix.msrv }}
145+
146+ - name : cargo +${{ matrix.msrv }} check ${{ matrix.feature }}
147+ run : cargo check --package newrelic_super_agent --features=${{ matrix.feature }}
148+
149+ # msrv = Minimum Supported Rust Version
150+ msrv_packages :
95151 runs-on : ubuntu-latest
96152 strategy :
97153 matrix :
98154 msrv : [ 1.78.0 ]
155+ package : [ config-migrate, fs, license, nr-auth, resource-detection ]
156+
99157 name : ubuntu / ${{ matrix.msrv }}
100158 steps :
101159 - uses : actions/checkout@v4
102160 with :
103161 submodules : true
162+
104163 - name : Give GitHub Actions access to private crates
105164 uses :
webfactory/[email protected] 106165 with :
107166 ssh-private-key : ${{ secrets.CAOS_RUST_CRATES }}
167+
108168 - name : Install ${{ matrix.msrv }}
109169110170 with :
111171 toolchain : ${{ matrix.msrv }}
112- - name : cargo +${{ matrix.msrv }} check onK8s
113- run : cargo check --features=k8s
114- - name : cargo +${{ matrix.msrv }} check onHost
115- run : cargo check --features=onhost
116172
173+ - name : cargo +${{ matrix.msrv }} check ${{ matrix.package }}
174+ run : cargo check --package ${{ matrix.package }}
117175
118176 licenses :
119177 name : Validate third party libraries
0 commit comments