Like this?
library(readr)
library(stringr)
R_code = read_file("YourScript.R")
R_code_new = str_replace_all(R_code, "\r\n", "\r\n\r\n")
write_file(R_code_new, "YourScript.R")
You can read in the code, replace all line breaks with 2 line breaks and save it again.