diff options
| author | Ali Bektas <bektasali@protonmail.com> | 2024-09-12 15:46:09 +0200 |
|---|---|---|
| committer | Ali Bektas <bektasali@protonmail.com> | 2024-09-12 15:46:09 +0200 |
| commit | 88e10a9e54eb06217a3c45d330b6a3ba66577b01 (patch) | |
| tree | f22b19d6b0d0ed97c6bc38b083e972918f224953 /src/init.rs | |
| parent | 1f624d4c2a4ee0441ffce842591a8e37e329d309 (diff) | |
hardcode ratoml in init.rs
Diffstat (limited to 'src/init.rs')
| -rw-r--r-- | src/init.rs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/init.rs b/src/init.rs index 24dcfa6..6322432 100644 --- a/src/init.rs +++ b/src/init.rs @@ -130,8 +130,7 @@ pub fn init() -> Result<()> { fs::write("Cargo.toml", updated_cargo_toml) .context("Failed to create the file `rustlings/Cargo.toml`")?; - let ra_toml = include_str!("../dev-rust-analyzer.toml"); - fs::write("rust-analyzer.toml", ra_toml) + fs::write("rust-analyzer.toml", RATOML) .context("Failed to create the file `rustlings/rust-analyzer.toml`")?; fs::write(".gitignore", GITIGNORE) @@ -173,6 +172,11 @@ const INIT_SOLUTION_FILE: &[u8] = b"fn main() { } "; +const RATOML: &[u8] = br#"# rust-analyzer configuration file +# DO NOT edit what is already defined. +# You may add new configurations as needed. +check.extraArgs = ["--profile", "test"]"#; + const GITIGNORE: &[u8] = b"Cargo.lock target/ .vscode/ |
