From 90570ab3e14268f2626cc6d1397888e3f8c447b5 Mon Sep 17 00:00:00 2001 From: Muhammad Nauman Raza Date: Mon, 21 Oct 2024 12:31:39 +0100 Subject: [PATCH] feat: revamp structure --- .gitignore | 2 +- justfile | 2 ++ nurse/src/main.rs | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) create mode 100644 justfile diff --git a/.gitignore b/.gitignore index 89aaaba..8524333 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,5 @@ # Ignore user file -nurse/nurse.txt +nurse.txt # Added by cargo nurse/target diff --git a/justfile b/justfile new file mode 100644 index 0000000..fbd617c --- /dev/null +++ b/justfile @@ -0,0 +1,2 @@ +run: + nix-shell --command "cd nurse && cargo run" diff --git a/nurse/src/main.rs b/nurse/src/main.rs index 02997a7..3b204ee 100644 --- a/nurse/src/main.rs +++ b/nurse/src/main.rs @@ -3,7 +3,7 @@ use std::fs; use std::process::Command; fn main() -> std::io::Result<()> { - let file: Vec = fs::read_to_string("nurse.txt") + let file: Vec = fs::read_to_string("../nurse.txt") .unwrap() .lines() .map(String::from)