r-cran-getopt | GNU R package providing command-line parsing functionality | Mehr ...
This package provides the getopt function which can be used with R's Rscript (or littler's r) to write ``#!'' shebang scripts that accept short and long flags/options.