[ESS] Assign f12 to "ess-sas-submit-region"
Rodney Sparapani
rsparapa at mcw.edu
Mon Mar 21 17:40:26 CET 2011
On 03/21/11 09:45 AM, Main, Regan wrote:
> Hi all--
>
> I use iESS for generating and debugging SAS code primarily, but also
> Stata and R. I prefer to submit code by marking the region and
> submitting with C-c C-r and have been doing so for a couple of years.
> I'm starting to run into some carpal tunnel issues though and would like
> to change the burden of submitting chunks of code from my left hand to
> my right. I've been playing around with my .emacs but not meeting with
> much success.
>
> Can someone please help me assign the f12 key to what the C-c C-r
> keybinding currently does? Below is my best attempt so far. I found
> the "defcustom" lines online and inserted them between a
> global-unset-key and global-set-key.
>
> Thanks much for any assistance you can offer.
> -Regan Main
> RAND Corporation
>
>
> (global-unset-key [f12])
>
> ;; Bind f12 to ess-sas-submit-region
> (defcustom ess-sas-temp-root "-temp"
> "*Appended to root name of the temporary .sas file for
> `ess-sas-submit-region'."
> :group 'ess-sas
> :type 'string)
>
> (global-set-key [f12] 'ess-sas-submit-region)
Hi Regan:
I don't know what the defcustom bit is all about, but the f12 definition
looks correct to me. Did you read
http://ess.r-project.org/Manual/ess.html#ESS_0028SAS_0029_002d_002dFunction-keys-for-batch-processing
If so, which of the 4 layouts did you pick? If 4 or 5, then what you
want is C-F3 or C-F8 respectively. If that is not working, then try
what's under b.; either
(ess-sas-global-unix-keys) ; C-F3
or
(ess-sas-global-pc-keys) ; C-F8
Rodney
More information about the ESS-help
mailing list