Add cargo udeps to CI (#733)
* Add cargo udeps * Ignore useless deps used to recreate grammar automatically
This commit is contained in:
Родитель
9b1369845d
Коммит
1e45745a92
|
@ -28,6 +28,13 @@ repos:
|
|||
entry: cargo clippy --all-targets --all -- -D warnings
|
||||
pass_filenames: false
|
||||
|
||||
- id: udeps
|
||||
name: udeps
|
||||
language: system
|
||||
files: '\.rs$'
|
||||
entry: cargo +nightly udeps --all-targets
|
||||
pass_filenames: false
|
||||
|
||||
- id: test
|
||||
name: test
|
||||
language: system
|
||||
|
|
|
@ -41,6 +41,8 @@ tasks:
|
|||
- "-cx"
|
||||
- "curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py && python3 get-pip.py &&
|
||||
rustup component add clippy rustfmt &&
|
||||
rustup toolchain install nightly &&
|
||||
curl -L https://github.com/est31/cargo-udeps/releases/download/v0.1.25/cargo-udeps-v0.1.25-x86_64-unknown-linux-gnu.tar.gz | tar xz -C /usr/local/cargo/bin --strip-components 2 &&
|
||||
git clone --quiet ${repository} &&
|
||||
cd rust-code-analysis &&
|
||||
git -c advice.detachedHead=false checkout ${head_rev} &&
|
||||
|
|
|
@ -28,3 +28,6 @@ cc = "^1.0"
|
|||
# This dependency is not used at all for this crate, but it is here so that
|
||||
# dependabot can send notifications when there are updates for this grammar
|
||||
tree-sitter-cpp = "0.19.0"
|
||||
|
||||
[package.metadata.cargo-udeps.ignore]
|
||||
build = ["tree-sitter-cpp"]
|
||||
|
|
|
@ -28,3 +28,6 @@ cc = "^1.0"
|
|||
# This dependency is not used at all for this crate, but it is here so that
|
||||
# dependabot can send notifications when there are updates for this grammar
|
||||
tree-sitter-javascript = "0.19.0"
|
||||
|
||||
[package.metadata.cargo-udeps.ignore]
|
||||
build = ["tree-sitter-javascript"]
|
||||
|
|
Загрузка…
Ссылка в новой задаче