diff options
| author | mo8it <mo8it@proton.me> | 2024-09-04 02:19:45 +0200 |
|---|---|---|
| committer | mo8it <mo8it@proton.me> | 2024-09-04 02:19:45 +0200 |
| commit | 247bd19f93e11fb037c945ff1dc464a1d1713471 (patch) | |
| tree | 7b9b404b2c0c157f3d50bf26288a441be13aae52 /src/watch | |
| parent | e5ed11528855f6dddc5759df3426ff1296aba87e (diff) | |
Canonicalize exercise paths only once
Diffstat (limited to 'src/watch')
| -rw-r--r-- | src/watch/state.rs | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/watch/state.rs b/src/watch/state.rs index 1c2e2a9..fe9e274 100644 --- a/src/watch/state.rs +++ b/src/watch/state.rs @@ -11,7 +11,7 @@ use crate::{ app_state::{AppState, ExercisesProgress}, clear_terminal, exercise::{solution_link_line, RunnableExercise, OUTPUT_CAPACITY}, - term::{progress_bar, terminal_file_link}, + term::progress_bar, }; #[derive(PartialEq, Eq)] @@ -184,7 +184,9 @@ impl<'a> WatchState<'a> { )?; stdout.write_all(b"\nCurrent exercise: ")?; - terminal_file_link(stdout, self.app_state.current_exercise().path, Color::Blue)?; + self.app_state + .current_exercise() + .terminal_file_link(stdout)?; stdout.write_all(b"\n\n")?; self.show_prompt(stdout)?; |
