RE: Commandline History?

2005-12-05 Thread Com MN PG P E B Consultant 3

> Com MN PG P E B Consultant 3 wrote:
> > Actually, I did consider slime, and I do occasionally use emacs.
> > I was just looking for a more "lightweight" solution, such as
> > giving readline support to lisp, similar as it is done with clisp.
> 
> Perhaps the first question should be, if you "occasionally use
> emacs", then what do you use the rest of the time? How are you
> editing your lisp code now?

I have just started learning Lisp, and for most other code editing,
I use right now mainly Nedit and occasionally Kedit and Kate.

> IMHO if you are editing your code some other way, then indeed
> from that perspective *any* solution where step 1 is "first fire
> up emacs" is going to be "heavyweight"!

I had used Emacs a lot in past projects, so that's why I maybe go with
Slime. Editors, as always, are a matter of taste, and for that kind of
work I'm doing now, I have a slight preference for nedit. But as I said,
maybe I will go back to Emacs and try Slime. Maybe I will also try
one of the other solutions proposed here, and then will see what I will
end up with.

Thank you to all for giving so many suggestions.

Ronald




Re: Commandline History?

2005-12-02 Thread Nikodemus Siivola

On Thu, 1 Dec 2005, michael graffam wrote:

> Ideas?

Linedit can hook into the SBCL repl. Getting it to do the same for
CMUCL should not be too hard.

Cheers,

  -- Nikodemus  Schemer: "Buddha is small, clean, and serious."
   Lispnik: "Buddha is big, has hairy armpits, and laughs."




Re: Commandline History?

2005-12-01 Thread lakin

Com MN PG P E B Consultant 3 wrote:
> Actually, I did consider slime, and I do occasionally use emacs.
> I was just looking for a more "lightweight" solution, such as
> giving readline support to lisp, similar as it is done with clisp.

Perhaps the first question should be, if you "occasionally use
emacs", then what do you use the rest of the time? How are you
editing your lisp code now?

IMHO if you are editing your code some other way, then indeed
from that perspective *any* solution where step 1 is "first fire
up emacs" is going to be "heavyweight"!

And, if you do go with emacs, then as has been pointed out, there
are lots of options. The simplest might be to just start lisp in
a shell buffer, and then you get line editing and history.  When
you frustrate with that, then time to consider additional pkgs
like Ilisp or Slime or even the ancient cl-shell.el .

Good luck,
-f




Re: Commandline History?

2005-12-01 Thread Drew McDermott


> [Com MN PG P E B Consultant 3]
> 
> I find it a bit convenient when working on the lisp shell (i.e. the "*"
> prompt which
> you get when you are just invoking "lisp"), that you don't have a good
> command editing
> or a history facility, as you have in shells such as bash or zsh. I know
> that lisp is
> not intended to be used like a shell, but still this would be useful
> (especially during
> the time where one is learning Lisp).
> 
> Does someone know an add-on which provides such a facility?

Yes, Emacs!  You run cmucl as an "inferior" process to emacs.  There
are several packages that make this process run smoothly.  The
currently most popular one is Slime.  Obviously you get all the
command-line editing anyone could dream of, but you also have command
histories and a lot of other bells and whistles.

I don't endorse Slime, at least not strongly.  I use it, but I'm
strongly considering going back to Ilisp or some other older
interface.

-- 

 -- Drew McDermott
Yale University
Computer Science Department




Re: Commandline History?

2005-12-01 Thread michael graffam



--- Stephan Frank <[EMAIL PROTECTED]> wrote:
> [1] http://utopia.knoware.nl/~hlub/uck/rlwrap/
> (call with 'rlwrap cmucl'), also look at
> http://weitz.de/completions.html

This solution works, but it is grossly deficient
compared to CLISP. SLIME is a better option, but only
if you can tolerate Emacs being up just to communicate
with CMUCL. 

The main drawback of rlwrap is that it uses a static
list of LISP symbols for completion. One simply
creates a text file (which rlwrap reads in at startup)
containing every symbol within CMUCL. 

1) Reading in this list is slow, which can make LISP
startup painful on an older machine.  

2) There is no facility for CMUCL to communicate new
symbols/bindings to rlwrap. So, for example, in
CMUCL/rlwrap if you (defun foo () ...) rlwrap cannot
complete the name foo. 

It would be really nice if CMUCL had a simple facility
to overload the reader functions so that a
user-defined function can be called for line-input. It
is relatively simple to write a nice line-editting
library in LISP, with completion and all the goodies.
Its just a matter of getting it hooked into CMUCL.

Ideas?

Mike





__ 
Yahoo! Mail - PC Magazine Editors' Choice 2005 
http://mail.yahoo.com




Re: Commandline History?

2005-12-01 Thread Albert Reiner

["Com MN PG P E B Consultant 3" <[EMAIL PROTECTED]>, Thu, 1 Dec 2005 13:21:26 
+0100]:
> I find it a bit convenient when working on the lisp shell (i.e. the "*"
> prompt which
> you get when you are just invoking "lisp"), that you don't have a good
> command editing
> or a history facility, as you have in shells such as bash or zsh. I know
> that lisp is
> not intended to be used like a shell, but still this would be useful
> (especially during
> the time where one is learning Lisp).

There are various readline wrappers like, e.g., rlwrap.  I don't have
any experience with those, though.

HTH,

Albert.




Re: Commandline History?

2005-12-01 Thread Stephan Frank

Com MN PG P E B Consultant 3 wrote:
> From: Stephan Frank [mailto:[EMAIL PROTECTED] 
> 
>>people nowadays usually use slime [1] together with emacs. if 
>>you don't
>>use emacs you really should consider using it. Slime provides your
>>requested features and a lot more. 
> 
> 
> Actually, I did consider slime, and I do occasionally use emacs.
> I was just looking for a more "lightweight" solution, such as
> giving readline support to lisp, similar as it is done with clisp.
> 
> But if there is no other option, I will try my luck with slime.

Ah OK, that was not clear to me from your mail. For that case you could
try rlwrap [1] or ledit [2] which should give you readline editing, but
 personally I have never tried it.

(besides: sorry for not sending the previous email to the list. I blame
lack of coffee.)

regs,
Stephan

[1] http://utopia.knoware.nl/~hlub/uck/rlwrap/
(call with 'rlwrap cmucl'), also look at
http://weitz.de/completions.html

[2] sorry, no site for this but at least in debian it's a package with
this name




RE: Commandline History?

2005-12-01 Thread Com MN PG P E B Consultant 3

From: Stephan Frank [mailto:[EMAIL PROTECTED] 
> people nowadays usually use slime [1] together with emacs. if 
> you don't
> use emacs you really should consider using it. Slime provides your
> requested features and a lot more. 

Actually, I did consider slime, and I do occasionally use emacs.
I was just looking for a more "lightweight" solution, such as
giving readline support to lisp, similar as it is done with clisp.

But if there is no other option, I will try my luck with slime.

Ronald