* Reload .emacs
@ 2007-08-03 9:26 Henrik Austad
2007-08-03 20:44 ` Peter Dyballa
` (2 more replies)
0 siblings, 3 replies; 9+ messages in thread
From: Henrik Austad @ 2007-08-03 9:26 UTC (permalink / raw)
To: help-gnu-emacs
Hi all!
I'm configuring my emacs22.1, and I catch myself restarting emacs (quit and start) for every change.
Are there any ways of just reloading the .emacs-file without restarting emacs?
I've googled for 'emacs reload config' and variants thereof, but I'm not finding a useful guide.
If there are places I *should* have read before bugging you with these kind of questions, please let me
know - I don't mean to annoy you! :-)
thanks
--
henrik
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Reload .emacs
2007-08-03 9:26 Reload .emacs Henrik Austad
@ 2007-08-03 20:44 ` Peter Dyballa
2007-08-03 21:28 ` Eli Zaretskii
2007-08-09 6:41 ` Henrik Austad
2 siblings, 0 replies; 9+ messages in thread
From: Peter Dyballa @ 2007-08-03 20:44 UTC (permalink / raw)
To: Henrik Austad; +Cc: help-gnu-emacs
Am 03.08.2007 um 11:26 schrieb Henrik Austad:
> Are there any ways of just reloading the .emacs-file without
> restarting emacs?
Not really. An init file can do other things than some other Elisp
file. Elisp libraries or files can get loaded/reloaded depending on
variables set/reset/unset ...
BTW, what do you mean with "I'm configuring my emacs22.1?"
--
Greetings
Pete
Time flies like an error -- but fruit flies like a banana!
(almost Groucho Marx)
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Reload .emacs
[not found] <mailman.4356.1186173019.32220.help-gnu-emacs@gnu.org>
@ 2007-08-03 20:52 ` Arjen Wiersma
2007-08-03 21:12 ` Harald Hanche-Olsen
2007-08-07 10:44 ` Tim X
1 sibling, 1 reply; 9+ messages in thread
From: Arjen Wiersma @ 2007-08-03 20:52 UTC (permalink / raw)
To: help-gnu-emacs
henrikau@januz.zapto.org (Henrik Austad) writes:
> I'm configuring my emacs22.1, and I catch myself restarting emacs (quit and
> start) for every change. Are there any ways of just reloading the
> .emacs-file without restarting emacs?
>
> I've googled for 'emacs reload config' and variants thereof, but I'm not
> finding a useful guide.
>
> If there are places I *should* have read before bugging you with these kind
> of questions, please let me know - I don't mean to annoy you! :-)
How about eval-buffer?
,----[ C-h f eval-buffer RET ]
| eval-buffer is an interactive built-in function in `C source code'.
| (eval-buffer &optional BUFFER PRINTFLAG FILENAME UNIBYTE DO-ALLOW-PRINT)
|
| Execute the current buffer as Lisp code.
| Programs can pass two arguments, BUFFER and PRINTFLAG.
| BUFFER is the buffer to evaluate (nil means use current buffer).
| PRINTFLAG controls printing of output:
| A value of nil means discard it; anything else is stream for print.
|
| If the optional third argument FILENAME is non-nil,
| it specifies the file name to use for `load-history'.
| The optional fourth argument UNIBYTE specifies `load-convert-to-unibyte'
| for this invocation.
|
| The optional fifth argument DO-ALLOW-PRINT, if non-nil, specifies that
| `print' and related functions should work normally even if PRINTFLAG is nil.
|
| This function preserves the position of point.
`----
Regards,
Arjen
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Reload .emacs
2007-08-03 20:52 ` Arjen Wiersma
@ 2007-08-03 21:12 ` Harald Hanche-Olsen
0 siblings, 0 replies; 9+ messages in thread
From: Harald Hanche-Olsen @ 2007-08-03 21:12 UTC (permalink / raw)
To: help-gnu-emacs
+ Arjen Wiersma <coreSPAM@credmp.org>:
| How about eval-buffer?
Or even eval-last-sexp. That's what I use all the time, if I have
made one change in .emacs, I place the cursor after the changed
definition or whatever and hit C-x C-e.
--
* Harald Hanche-Olsen <URL:http://www.math.ntnu.no/~hanche/>
- It is undesirable to believe a proposition
when there is no ground whatsoever for supposing it is true.
-- Bertrand Russell
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Reload .emacs
2007-08-03 9:26 Reload .emacs Henrik Austad
2007-08-03 20:44 ` Peter Dyballa
@ 2007-08-03 21:28 ` Eli Zaretskii
2007-08-03 22:02 ` Amy Templeton
2007-08-09 6:41 ` Henrik Austad
2 siblings, 1 reply; 9+ messages in thread
From: Eli Zaretskii @ 2007-08-03 21:28 UTC (permalink / raw)
To: help-gnu-emacs
> Date: Fri, 3 Aug 2007 11:26:56 +0200
> From: henrikau@januz.zapto.org (Henrik Austad)
>
> Are there any ways of just reloading the .emacs-file without restarting emacs?
You can manually evaluate the additions you make. Go to the closing
parenthesis of each expression and type "C-x C-e".
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Reload .emacs
2007-08-03 21:28 ` Eli Zaretskii
@ 2007-08-03 22:02 ` Amy Templeton
2007-08-04 8:20 ` Reiner Steib
0 siblings, 1 reply; 9+ messages in thread
From: Amy Templeton @ 2007-08-03 22:02 UTC (permalink / raw)
To: help-gnu-emacs
Eli Zaretskii <eliz@gnu.org> wrote:
> > Date: Fri, 3 Aug 2007 11:26:56 +0200
> > From: henrikau@januz.zapto.org (Henrik Austad)
> >
> > Are there any ways of just reloading the .emacs-file without
> > restarting emacs?
> You can manually evaluate the additions you make. Go to the closing
> parenthesis of each expression and type "C-x C-e".
Alternately, if you've done a lot of work, you can highlight the
region and do "M-x eval-region RET" to evaluate it, or if you've
changed the whole buffer you can do "M-x eval-buffer RET", but I
wouldn't generally advise that for reloading the init file because
there might be things in there that'll toggle, which could mess
things up for you.
Amy
--
A lifetime isn't nearly long enough to figure out what it's all about.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Reload .emacs
2007-08-03 22:02 ` Amy Templeton
@ 2007-08-04 8:20 ` Reiner Steib
0 siblings, 0 replies; 9+ messages in thread
From: Reiner Steib @ 2007-08-04 8:20 UTC (permalink / raw)
To: help-gnu-emacs
On Sat, Aug 04 2007, Amy Templeton wrote:
> [...] or if you've changed the whole buffer you can do "M-x
> eval-buffer RET", but I wouldn't generally advise that for reloading
> the init file because there might be things in there that'll toggle,
> which could mess things up for you.
Then you should probably fix your setup. Some examples:
Instead of...
(foo-bar-mode);; toggle foo-bar mode
use...
(foo-bar-mode 1);; enable foo-bar mode
Use `add-to-list' instead of `push'. Etc.
Bye, Reiner.
--
,,,
(o o)
---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Reload .emacs
[not found] <mailman.4356.1186173019.32220.help-gnu-emacs@gnu.org>
2007-08-03 20:52 ` Arjen Wiersma
@ 2007-08-07 10:44 ` Tim X
1 sibling, 0 replies; 9+ messages in thread
From: Tim X @ 2007-08-07 10:44 UTC (permalink / raw)
To: help-gnu-emacs
henrikau@januz.zapto.org (Henrik Austad) writes:
> Hi all!
>
> I'm configuring my emacs22.1, and I catch myself restarting emacs (quit and start) for every change.
> Are there any ways of just reloading the .emacs-file without restarting emacs?
>
> I've googled for 'emacs reload config' and variants thereof, but I'm not finding a useful guide.
>
> If there are places I *should* have read before bugging you with these kind of questions, please let me
> know - I don't mean to annoy you! :-)
>
Is there a specific reason why you need to reload the whole file?
I usually just make changes in the file and put cursor at the end of the sexp
and hit C-x C-e to eval it.
Tim
>
>
--
tcross (at) rapttech dot com dot au
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: Reload .emacs
2007-08-03 9:26 Reload .emacs Henrik Austad
2007-08-03 20:44 ` Peter Dyballa
2007-08-03 21:28 ` Eli Zaretskii
@ 2007-08-09 6:41 ` Henrik Austad
2 siblings, 0 replies; 9+ messages in thread
From: Henrik Austad @ 2007-08-09 6:41 UTC (permalink / raw)
To: help-gnu-emacs
[-- Attachment #1.1: Type: text/plain, Size: 556 bytes --]
On Fri, Aug 03, 2007 at 11:26:56AM +0200, Henrik Austad wrote:
> Hi all!
Hi again.. (-:
>
> I'm configuring my emacs22.1, and I catch myself restarting emacs (quit and start) for every change.
> Are there any ways of just reloading the .emacs-file without restarting emacs?
I'm writing a more general reply since I've gotten a lot of answers and
input, thank you all!
I'm now using C-x C-e to eval the expression, and that was (even though
I didn'n know it) exactly what I needed.
Again, thank you for all you help!
--
henrik
[-- Attachment #1.2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
[-- Attachment #2: Type: text/plain, Size: 152 bytes --]
_______________________________________________
help-gnu-emacs mailing list
help-gnu-emacs@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gnu-emacs
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2007-08-09 6:41 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-08-03 9:26 Reload .emacs Henrik Austad
2007-08-03 20:44 ` Peter Dyballa
2007-08-03 21:28 ` Eli Zaretskii
2007-08-03 22:02 ` Amy Templeton
2007-08-04 8:20 ` Reiner Steib
2007-08-09 6:41 ` Henrik Austad
[not found] <mailman.4356.1186173019.32220.help-gnu-emacs@gnu.org>
2007-08-03 20:52 ` Arjen Wiersma
2007-08-03 21:12 ` Harald Hanche-Olsen
2007-08-07 10:44 ` Tim X
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).