mirror of
https://github.com/rust-lang/rust-analyzer
synced 2024-12-27 05:23:24 +00:00
Merge #2231
2231: Allow usage of CARGO_TARGET_DIR env var r=matklad a=killercup Co-authored-by: Pascal Hertleif <pascal@technocreatives.com>
This commit is contained in:
commit
6195783049
1 changed files with 2 additions and 1 deletions
|
@ -227,7 +227,8 @@ fn install_client(ClientOpt::VsCode: ClientOpt) -> Result<()> {
|
|||
}
|
||||
|
||||
fn install_server(opts: ServerOpt) -> Result<()> {
|
||||
let ac = autocfg::AutoCfg::with_dir("target")?;
|
||||
let target_dir = env::var_os("CARGO_TARGET_DIR").unwrap_or_else(|| "target".into());
|
||||
let ac = autocfg::AutoCfg::with_dir(target_dir)?;
|
||||
|
||||
let old_rust = !ac.probe_rustc_version(REQUIRED_RUST_VERSION.0, REQUIRED_RUST_VERSION.1);
|
||||
|
||||
|
|
Loading…
Reference in a new issue