R development in TextMate is great with the R bundle. Unfortunately the R bundle does not support highlighting of roxygen documentation by default. That was always a sticking point for me switching to roxygen because TextMate has really nice highlighting for Rd files.
So I hacked on the syntax file to get at least some preliminary highlighting of stuff after roxygen comments (
#'). The file is in a gist over at github. It doesn’t yet work quite as well as I would like but it is better than nothing. In particular, highlighting of R code in examples does not work. Contributions/additions are welcome.
You must have must have the R bundle installed. The easiest way to install is to open the bundle editor (“Bundles” > “Bundle Editor” > “Show Bundle Editor”) and copy this file over the R syntax file from the R bundle. Then “Reload Bundles” or restart TextMate.
You may need to install the R bundle first if you have not already:
cd /Library/Application\ Support/TextMate/Bundles
svn co http://svn.textmate.org/trunk/Bundles/R.tmbundle
Then either reload the bundles or restart TextMate to get the bundle activated.