FW: [R] ESS with Xemacs? [vs. Emacs, slightly off topic]

Jeff Mincy jeff at delphioutpost.com
Tue Jan 8 22:11:15 CET 2002


On 08 Jan 2002, rossini at blindglobe.net wrote:

>>>>>> "GRW" == Gregory R Warnes <Warnes> writes:
> 
>     GRW> Is it possible to (optionally?) have ESS startup gnuserv
>     GRW> and set the environement variable 'EDITOR' to 'gnuclient'
>     GRW> so that edit works properly?
> 
> Yes, it's possible.  Best approach for this would be to send this
> message to ess-help, and see what people know...  In fact, I'll cc'
> the list, apologies.
> 
> To everyone else -- thoughts on how to do this?  (it's about a 1
> hour project, but the catch is defining things at the right place,
> and possibly add to any gnuserv hooks that are present....).
> 
> best,
> -tony

I don't think this is something that ESS needs to get involved with.
This is something that users should be doing one way or the other.


In .emacs  (this works for xemacs, emacs uses something else similar)
I have .emacs check to see if a gnuserv is running elsewhere, and if
not start one up (except at-home).  All you really need is (gnuserv-start)

(defun any-gnuserv-running-p ()
  (or (gnuserv-running-p)
      (let ((client (exec-to-string "gnuclient -batch -eval t")))
        (cond ((string-match "^t" client) t)
              ((string-match "^gnuclient:" client) nil)
              (t nil)))))
(defun gnuserv () 
  (interactive) 
  (if (not (any-gnuserv-running-p)) (gnuserv-start)))

(when (not at-home)
  (gnuserv))


Then somewhere in your s.init: Do

 options(editor="gnuclient")

Then do something that uses splus editor.

 fix(fix)

And splus pops up a xemacs window editing 'fix' in a temporary file
named fix$$.  Unfortunately, the fix function doesn't do anything to
tell xemacs that S-mode should be used for the function.

-jeff
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
ess-help mailing list -- To (un)subscribe, send
subscribe	or	unsubscribe
(in the "body", not the subject !)  To: ess-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the ESS-help mailing list