Return TRUE is terminal. But FALSE if the RStudio console. The RStudio console doesn't require as much customisation as a standard console since it is already pretty. But it does place limits on the prompt options (single line only).

is_terminal()

set_terminal(
  rdoc = TRUE,
  colorout = TRUE,
  prettycode = TRUE,
  cmd_prompt = rprofile_prompt
)

set_rstudio(prettycode = TRUE)

Arguments

rdoc

Should we load the rdoc package

colorout

Should we load the colorout package

prettycode

Should we load the prettycode package

cmd_prompt

The prompt to use. A prompt from the prompt package could also be passed.