How to completely interrupt script running in Rstudio

This is a persistent problem for me since updating Rstudio (v.1.3.952) where I feel I must be missing something.

Say you have the following script:

Sys.sleep(5)
Sys.sleep(5)
Sys.sleep(5)
Sys.sleep(5)
Sys.sleep(5)
Sys.sleep(5)
Sys.sleep(5)
Sys.sleep(5)
Sys.sleep(5)
Sys.sleep(5)
Sys.sleep(5)
Sys.sleep(5)
Sys.sleep(5)
Sys.sleep(5)

And you run with Ctrl+A and then Ctrl+Enter. You then decide you want stop the entire script (not just the current line/command), how do you do it?

its heavy but you can do it
image

Thanks @nirgrahamuk I notice this solution results in a restart of R, which can sometimes take a while and requires reloading packages.

In a previous version of RStudio I would simply press Esc, is there no equivalent in current version?

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.