From e7906cfe85fb8c316981cb7162ddabddf2ed26e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Patrick=20F=C3=B6rster?= Date: Thu, 28 Jul 2022 18:16:43 +0200 Subject: [PATCH] Use current dir as fallback watch location Watch the current working directory if no auxiliary directory is set. See #679. --- src/server.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/server.rs b/src/server.rs index ae0baf37..946abd15 100644 --- a/src/server.rs +++ b/src/server.rs @@ -747,9 +747,10 @@ impl Server { )?; } - if let Some(path) = &self.workspace.environment.options.aux_directory { - let _ = self.workspace.watch(path); - } + let _ = match &self.workspace.environment.options.aux_directory { + Some(path) => self.workspace.watch(path), + None => self.workspace.watch(&PathBuf::from(".")), + }; Ok(()) }