This function asks you interactively for permission to continue or not. You can specify a custom message before the question and also different messages for a both a positive and negative answer.
sure(
before_question = NULL,
after_saying_no = NULL,
after_saying_yes = NULL,
default_answer = NULL
)
A logical indicating if answer was 'yes'
/'y'
(TRUE
) or otherwise (FALSE
).
String with message to be printed before question.
String with message to be printed after answering
'no'
.
String with message to be printed after answering
'yes'
.
String with answer to question, if run in non-interactive mode.
If you run this function in non-interactive mode, you should pass an
automatic answer to default_answer
: 'yes'
or 'no'
.