took me a couple of reads to understand what you were after. This SO question is what you are after
to use with dbGetQuery() you'd connect to your database, then:
dbGetQuery(con, "EXEC sp_helptext 'your_stored_proc';")
The text will end up in a data.frame with one column and a row for each line of the query.