zed/crates/lsp/build.rs
Antonio Scandurra 59ed535cdf Implement a more robust way of locating rust-analyzer
When bundled, we will retrieve it out of the `Resources` folder.
Locally, we're expected to run `script/download-rust-analyzer` and
put `vendor/bin` in our $PATH.
2021-10-25 11:02:35 +02:00

10 lines
235 B
Rust

use std::env;
fn main() {
let target = env::var("TARGET").unwrap();
println!("cargo:rustc-env=TARGET={}", target);
if let Ok(bundled) = env::var("BUNDLE") {
println!("cargo:rustc-env=BUNDLE={}", bundled);
}
}