[ESS] Manually turn on ess script mode

Kasper Daniel Hansen kasperdanielhansen at gmail.com
Sun Mar 6 19:26:53 CET 2011


On Sun, Mar 6, 2011 at 11:35 AM, Tyler Smith <tyler.smith at eku.edu> wrote:
> Wow, that is embarrassing. For the record, I read the fine manual
> section on 'ESS for the S family', and tried M-x ess-<tab> to generate a
> list of all ESS functions that I could scan for clues. Now that I know
> the answer, I searched for the phrase r-mode in the entire text of the
> ess manual, and it doesn't appear (excepting as part of the command
> ess-R-mode-font-lock-keywords).
>
> Could I humbly request that some reference to R-mode be added to the
> info file? (info "(ess)ESS(S)--Editing files") seems like the best place:
>
>   ESS[S] mode should be automatically turned on when loading a file
> with the suffices found in ess-site (*.R, *.S, *.s, etc). **For files
> with non-standard suffices, the mode may be explicitly started with the
> command M-x R-mode.** However, one will have to start up an inferior
> process to take advantage of the interactive features.
>
> Or is there some other way to discover this function that I
> overlooked?

The standard for any major mode is to have a function like
MODENAME-mode to switch the mode of the buffer.  So I don't think ESS
has any leeway to choose this.  This is the same for any other major
mode.  Having said that, looking at ess-* function names is of course
sensible.

Kasper



More information about the ESS-help mailing list