Skip to content

Commit

Permalink
Use forward slashes for the tempfile; should fix #12
Browse files Browse the repository at this point in the history
  • Loading branch information
yihui committed Mar 3, 2016
1 parent dfa75d3 commit 64f5275
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/appshot.R
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ appshot.shiny.appobj <- function(app, file = "webshot.png", ...,
#' @export
appshot.character <- function(app, file = "webshot.png", ...,
port = getOption("shiny.port"), envvars = NULL) {
pidfile <- tempfile("pid")
pidfile <- normalizePath(tempfile("pid"), winslash = '/', mustWork = FALSE)
on.exit(unlink(pidfile))
port <- available_port(port)
cmd <- "cat(Sys.getpid(), file='%s'); shiny::runApp('%s', port=%d, display.mode='normal')"
Expand Down

0 comments on commit 64f5275

Please sign in to comment.