From 7d51c1ac6734a6d11839a0e9a282cad741c3ccb4 Mon Sep 17 00:00:00 2001 From: Garrick Aden-Buie Date: Mon, 1 Jul 2024 09:59:33 -0400 Subject: [PATCH] URL for running static server needs to escape characters on Windows Fixes #82 --- R/export.R | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/R/export.R b/R/export.R index 675ae0e..9d6c664 100644 --- a/R/export.R +++ b/R/export.R @@ -196,9 +196,12 @@ export <- function( template_params = template_params ) + # Escape backslashes in destdir because Windows + destdir_esc <- gsub("\\\\", "\\\\\\\\", destdir) + verbose_print( "\nRun the following in an R session to serve the app:\n", - " httpuv::runStaticServer(\"", destdir, "\")\n" + " httpuv::runStaticServer(\"", destdir_esc, "\")\n" ) invisible()