help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: how to edit already defined macros


From: Doug Lewan
Subject: RE: how to edit already defined macros
Date: Thu, 2 Aug 2012 12:40:21 +0000

In the edit-macro-buffer there is a line near the top with the keyword 
"Command:". You can give the macro a name there.

To save it in a file, find that file and type
    M-x insert-kbd-macro

That should give you LISP that you can use next time. (Don't forget where you 
put it!)

If you want to load it every time, then do the above in your .emacs file.

I hope this helps.

,Doug


> -----Original Message-----
> From: help-gnu-emacs-bounces+dougl=shubertticketing.com@gnu.org
> [mailto:help-gnu-emacs-bounces+dougl=shubertticketing.com@gnu.org] On
> Behalf Of Ferdinand
> Sent: Thursday, 2012 August 02 07:22
> To: John Wiegley
> Cc: help-gnu-emacs@gnu.org
> Subject: Re: how to edit already defined macros
> 
> 
> On Aug 2, 2012, at 5:42 AM, "John Wiegley" <johnw@newartisans.com>
> wrote:
> 
> >>>>>> Ferdinand  <Ferdinand.Gruebler@gmx.de> writes:
> >
> >> I made a macro, gave it a name and inserted it as lisp-code (M-x
> >> insert-kbd-macro) in the .emacs file (so that it gets loaded on
> startup).
> >
> >> But now, what do I do if I made a slight mistake and want to change
> >> something in the macro?
> >
> > C-x C-k RET.  And be amazed.
> >
> > John
> >
> 
> Hi John,
> 
> ok, that brings me to the edit macro-buffer. And of course I can change
> things there.
> 
> But these changes only persist for one session (as far as I know).
> In my .emacs file is still the old lisp-code that is not affected by
> changes in the macro-buffer and that will get loaded again the next
> time I open emacs.
> 
> So, how can I for instance transform the (changed) macro-buffer into
> lisp code, so that I can replace my original lisp code?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]