summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormo8it <mo8it@proton.me>2024-09-13 16:39:28 +0200
committermo8it <mo8it@proton.me>2024-09-13 16:39:28 +0200
commit47f8a0cbe502654ec09a6865cc82fe9330580ce1 (patch)
tree7167f1e3571f00c6a6e58b2c50450e27ad4d4e16
parent9459eef03214e05c4a50de3cffe250ecef095917 (diff)
Add rust-analyzer.toml on `dev new`
-rw-r--r--src/dev/new.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/dev/new.rs b/src/dev/new.rs
index c765046..154cd22 100644
--- a/src/dev/new.rs
+++ b/src/dev/new.rs
@@ -6,7 +6,7 @@ use std::{
process::Command,
};
-use crate::CURRENT_FORMAT_VERSION;
+use crate::{init::RUST_ANALYZER_TOML, CURRENT_FORMAT_VERSION};
// Create a directory relative to the current directory and print its path.
fn create_rel_dir(dir_name: &str, current_dir: &str) -> Result<()> {
@@ -62,6 +62,8 @@ pub fn new(path: &Path, no_git: bool) -> Result<()> {
write_rel_file("README.md", &dir_path_str, README)?;
+ write_rel_file("rust-analyzer.toml", &dir_path_str, RUST_ANALYZER_TOML)?;
+
create_rel_dir(".vscode", &dir_path_str)?;
write_rel_file(
".vscode/extensions.json",