David Caro
b534cafc2d
Merge 558793bbc2 into 8416413a0e
2025-12-26 21:14:01 -05:00
pre-commit-ci[bot]
917e2102be
[pre-commit.ci] auto fixes from pre-commit.com hooks
...
for more information, see https://pre-commit.ci
2024-07-29 21:59:19 +00:00
Terseus
558793bbc2
allow rust hooks to specify arbitrary cargo install parameters
...
We've replaced the previous "--feature=" format with a single parameter
"--" which marks the start of the "cargo install" arguments, so now we
can use "-- --features foo", "-- --locked", etc.
Fixes #3162
2024-07-11 21:12:48 +02:00
Terseus
bd153a698a
allow rust hooks to specify crate features
...
Now the rust hooks can use the parameter `additional_dependencies` to
receive build-time features for the crate.
The features must start with the string "--feature=" following the name
of the feature; e.g. "--feature=full".
Fixes #3230
2024-06-15 20:53:16 +02:00
Anthony Sottile
296f59266e
determine rust default language version independent of rust-toolchain.toml
2024-05-10 17:06:29 -04:00
Anthony Sottile
08478ec176
python 3.9+: use removeprefix
2023-12-09 16:04:25 -05:00
Anthony Sottile
7f15dc75ee
python3.9+
2023-10-28 14:20:37 -04:00
Anthony Sottile
ee71a9345c
set CARGO_HOME while executing rustup
2023-03-25 13:06:22 -04:00
Anthony Sottile
a412e5492d
don't set CARGO_HOME in rust
...
this adds a 270 MB registry cache in the output
2023-03-17 12:55:34 -04:00
Anthony Sottile
2700a7d622
set RUSTUP_HOME when using a non-system rust
2023-02-27 20:49:22 -05:00
Anthony Sottile
d3883ce7f7
move languages.all and languages.helpers out of languages
2023-02-20 18:03:45 -05:00
Anthony Sottile
628c876b2d
adjust the run_hook api to no longer take Hook
2023-01-16 16:34:01 -05:00
Anthony Sottile
ae34a962d7
make in_env part of the language api
2023-01-16 15:36:29 -05:00
Anthony Sottile
05c8911363
simplify environment_dir
2023-01-01 21:11:56 -05:00
Anthony Sottile
d05b7888ab
move clean_path_on_failure out of each hook install
2023-01-01 20:04:58 -05:00
Anthony Sottile
6c524f7a55
fix rust platform detection on windows
2022-12-06 13:10:12 -05:00
marsha
84b38f7b89
Change cmd_output_bs retcode arg to a boolean check
2022-10-30 14:49:42 -05:00
marsha
e703982de4
Change Rust to install environment with cargo add over toml
2022-10-28 21:32:52 -05:00
Jan Holthuis
eb469c756d
Rust as 1st class language
2022-10-10 20:05:36 -04:00
Anthony Sottile
07554e9525
add additional info to healthy-after-install check
2022-04-16 16:46:28 -04:00
Anthony Sottile
04de6a2e57
drop python 3.6 support
...
python 3.6 reached end of life on 2021-12-23
2022-01-18 18:44:20 -05:00
Anthony Sottile
fa8d022813
Remove unnecessary forward annotations
2020-02-07 08:32:39 -08:00
Anthony Sottile
755b8000f6
move Hook data type to a separate file
2020-01-15 14:20:51 -08:00
Anthony Sottile
df40e862f4
More miscellaneous cleanup
2020-01-13 11:47:34 -08:00
Anthony Sottile
327ed924a3
Add types to pre-commit
2020-01-12 10:15:01 -08:00
Anthony Sottile
fa536a8693
mypy passes with check_untyped_defs
2020-01-12 09:27:04 -08:00
Anthony Sottile
30c1e8289f
upgrade hooks, pyupgrade pre-commit
2020-01-12 09:27:04 -08:00
Anthony Sottile
7c3404ef1f
show color in hook outputs when attached to a tty
2019-10-12 23:17:36 -07:00
Anthony Sottile
f612aeb22b
Split out cmd_output_b
2019-10-06 15:16:47 -07:00
zimbatm
cbbfcd20b4
rust language: use the new cargo install command
...
cargo install now requires an additional `--path <TARGET>` argument.
2019-08-11 13:36:13 -07:00
Anthony Sottile
d3b5a41830
Implement default_language_version
2019-01-05 13:15:23 -08:00
Anthony Sottile
b59d7197ff
Use Hook api in languages
2018-12-31 13:16:48 -08:00
Anthony Sottile
6bac405d40
Minor cleanups
2018-11-01 18:05:36 -07:00
Chris Kuehl
ba5e27e4ec
Implement concurrent execution of individual hooks
2018-10-24 16:16:10 -07:00
Chris Kuehl
b4edf2ce50
Add tests for Rust
2018-05-22 21:52:34 -07:00
Chris Kuehl
2a37fcd3fe
Add support for Rust CLI dependencies
...
Also consistently build the hook using `cargo install`.
2018-05-22 21:20:13 -07:00
Chris Kuehl
7f85da1b9d
Add Rust support
2018-05-22 21:20:13 -07:00