[slime-devel] cutting and pasting S-expressions from buffer to REPL

Dave Cooper gendl at genworks.com
Mon May 14 18:07:44 UTC 2012


Hi Faheem,

 With the cursor on the _opening_ paren of an s-expression, you can do

   C-M-<space>

 to select the S-expression, then

  M-w

 to copy it.

 Then go over to the repl (I bind a personal shortcut of C-x & for this), then

 C-y

to "yank" (paste) the expression to the repl.

I'm not sure about automatically switching to the repl and pasting in
one go, but I'm sure that would be a few lines of emacs lisp...

And a quick way to get the cursor to the opening paren of an s-expression is

  C-M-b



On Mon, May 14, 2012 at 1:35 PM, Faheem Mitha <faheem at faheem.info> wrote:
>
> Hello everyone,
>
> I've recently started using SLIME with SBCl on Debian, where SLIME defaults
> to using SBCL, at least when it is installed. So far I am very impressed. I
> haven't been able to take off and fly yet, but I'm on the runway.:-)
>
> I'm particularly impressed by the underlining source which has compile
> errors, and doing a popup on mouseover feature. I don't know whose idea this
> was, but it is pretty damn cool. Does anyone know the history of this
> feature?
>
> So, I have a question about SLIME. When debugging, or indeed otherwise, I
> find it useful to copy and paste S-expressions from a buffer to the REPL.
> I've been using the mouse for this, which is decidedly sub-optimal. I hate
> using the mouse. I was thinking that it would be handy to have a command
> which would copy and paste S-expressions from a buffer to the REPL, while at
> the same time switching the buffer to the REPL. The S-expression would be
> chosen by having the cusor to the right of the closing expression. I'm not
> sure if this position has a name.
>
> I don't know if this command already exists. I could not find it in the
> manual. If it doesn't, could someone tell me what code would tell emacs to
> do this? My knowledge of Emacs programming is non-existent.
>
> Please CC me on any reply. Thanks.
>                                                           Regards, Faheem
>
> _______________________________________________
> slime-devel site list
> slime-devel at common-lisp.net
> http://common-lisp.net/mailman/listinfo/slime-devel




More information about the slime-devel mailing list