From 6e4689431a370270c54df3c8d4f48f5a8ca88d3c Mon Sep 17 00:00:00 2001 From: Jon Massey Date: Thu, 18 Jul 2024 09:21:23 +0100 Subject: [PATCH] Enable auto save when editor idle or loses focus --- devcontainer/postCreate.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/devcontainer/postCreate.sh b/devcontainer/postCreate.sh index 576d8f9..73c41e2 100755 --- a/devcontainer/postCreate.sh +++ b/devcontainer/postCreate.sh @@ -18,6 +18,10 @@ set_rstudio_pref() { #set RStudio working directory set_rstudio_pref "initial_working_directory" "\"$1\"" +#turn on RStudio autosave +set_rstudio_pref "auto_save_on_blur" "true" +set_rstudio_pref "auto_save_on_idle" "\"commit\"" + #download and extract latest ehrql source wget https://github.com/opensafely-core/ehrql/archive/main.zip -P .devcontainer unzip -o .devcontainer/main.zip -d .devcontainer/