edit .emacs and then ....

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

edit .emacs and then ....

D.Pleydell
This is a real newby question. I have a load of buffers in emacs and I
edit .emacs with some new cool macro or what ever. To get the new code
working I could close and restart emacs, but I will have to re-load
every buffer. Is there an easy way to either 1) get the new lisp code
working without closing and reopening, or 2) close and reopen and
still have all the same buffers available so I don't have to open
easch manually.

peace
Dave


--
David Pleydell

Laboratoire de Biologie Environnementale
USC INRA-EA 3184
Université de Franche-Comté
Place Leclerc F
25030
Besançon
France

(0033) 0381665763
[hidden email]


_______________________________________________
emacs-wiki-discuss mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/emacs-wiki-discuss
Reply | Threaded
Open this post in threaded view
|

Re: edit .emacs and then ....

Ryan Van Wagoner-2
Hi David,

>>>>> "dpleydel" == David  <[hidden email]> writes:

 dpleydel> 1) get the new lisp code
 dpleydel> working without closing and reopening,

This is relatively easy.  Just visit your .emacs buffer, place the
cursor at the end of whatever sexp you want to load (i.e. after the last
parenthesis in the expression), then type C-x C-e to evaluate the
expression.  Alternatively, you could place a mark at the beginning of a
region that you want to evaluate with C-SPC, put the cursor at the end
of the region, then use M-x eval-region.

I have never tried to get the second option to work, but it would be
more work than the first.

Regards,

--

Ryan Van Wagoner


_______________________________________________
emacs-wiki-discuss mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/emacs-wiki-discuss
Reply | Threaded
Open this post in threaded view
|

Re: edit .emacs and then ....

karen.cooke@gmail.com
In reply to this post by D.Pleydell

> 2) close and reopen and still have all the same buffers available so I don't
> have to open easch manually.

Although you can evaluate the lisp as Ryan says, if you are still interested in doing this, for any reason, take a look at desktop.

http://www.emacswiki.org/cgi-bin/wiki/DeskTop

Karen


_______________________________________________
emacs-wiki-discuss mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/emacs-wiki-discuss
Reply | Threaded
Open this post in threaded view
|

Re: edit .emacs and then ....

Philipp Haselwarter-2
In reply to this post by D.Pleydell
David <dpleydel <at> univ-fcomte.fr> writes:

> ... Is there an easy way to either 1) get the new lisp code
> working without closing and reopening, or 2) close and reopen and
> still have all the same buffers available ...

have a look at 1) M-x eval-region and 2) desktop-save-mode. you might as well
use load-file or eval-buffer, but then usually you don't want to reapply
everything in your .emacs but just bits..


_______________________________________________
emacs-wiki-discuss mailing list
[hidden email]
http://lists.nongnu.org/mailman/listinfo/emacs-wiki-discuss