Launch and terminate shiny app through terminal

Viewed 5764

How can I launch the Shiny App, "my_shiny" through the terminal.

Also, how do I terminate or close the app through the terminal only.

2 Answers

Or shorter:

R -e "shiny::runApp('my_shiny')"

If you want to specify a port:

R -e "shiny::runApp('my_shiny', port = 3838)"

As with most other commands, you can interrupt the process with Ctr+ C.

Related