File tree 5 files changed +164
-1
lines changed
5 files changed +164
-1
lines changed Original file line number Diff line number Diff line change
1
+ # yaml-language-server: $schema=https://json.schemastore.org/github-action.json
2
+
3
+ name : rust info
4
+ description : get rust info
5
+
6
+ outputs :
7
+ package-names :
8
+ description : package name "foo"
9
+ value : ${{steps.cargo.outputs.package-names}}
10
+ host :
11
+ description : host "x86_64-unknown-linux-gnu"
12
+ value : ${{steps.rustc.outputs.host}}
13
+
14
+ runs :
15
+ using : composite
16
+ steps :
17
+ - id : cargo
18
+ run : |
19
+ echo "package-names=$(cargo metadata --no-deps | jq --compact-output '.packages | map(.name)')" >> $GITHUB_OUTPUT
20
+ shell : bash
21
+ - id : rustc
22
+ run : |
23
+ echo "host=$(rustc -vV | awk '/host/ { print $2 }')" >> $GITHUB_OUTPUT
24
+ shell : bash
Original file line number Diff line number Diff line change
1
+ name : Clippy check
2
+
3
+ on :
4
+ push :
5
+ branches : ["**"]
6
+
7
+ env :
8
+ RUSTFLAGS : " -Dwarnings"
9
+
10
+ permissions : {}
11
+
12
+ jobs :
13
+ clippy_check :
14
+ runs-on : ubuntu-latest
15
+ steps :
16
+ - uses : actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
17
+ - uses : dtolnay/rust-toolchain@be73d7920c329f220ce78e0234b8f96b7ae60248 # master
18
+ with :
19
+ toolchain : stable
20
+ components : clippy
21
+ - id : rustc
22
+ uses : ./.github/actions/rust-info
23
+ - uses : Swatinem/rust-cache@23bce251a8cd2ffc3c1075eaa2367cf899916d84 # v2.7.3
24
+ with :
25
+ key : ${{ steps.rustc.outputs.host }}
26
+ - name : Run Clippy
27
+ run : cargo clippy --all-targets --all-features
Original file line number Diff line number Diff line change 63
63
with :
64
64
toolchain : stable
65
65
target : ${{ matrix.target }}
66
+ - id : rustc
67
+ uses : ./.github/actions/rust-info
66
68
- uses : Swatinem/rust-cache@23bce251a8cd2ffc3c1075eaa2367cf899916d84 # v2.7.3
67
69
with :
68
70
key : ${{ matrix.target }}
96
98
needs : build
97
99
permissions :
98
100
packages : write
99
- runs-on : ' ubuntu-latest'
101
+ runs-on : " ubuntu-latest"
100
102
outputs :
101
103
image_tags : ${{ steps.meta.outputs.tags }}
102
104
env :
Original file line number Diff line number Diff line change @@ -6,3 +6,7 @@ edition = "2021"
6
6
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
7
7
8
8
[dependencies ]
9
+ tokio = " 1.36.0"
10
+
11
+ [lints .clippy ]
12
+ pedantic = " warn"
You can’t perform that action at this time.
0 commit comments