On Wed, Dec 21, 2005 at 07:54:10PM -0800, Derek Peschel wrote:
More importantly to me, the prompt tells me "this is what *PACKAGE* was when I ran this command n {minutes,hours,days} ago." I'd be very unhappy for that information to go away.
I wodnered if that issue would come up. If the information was stored as a property of the text region that contains the command, and displayed on the mode line or something, would that work for you?
My gut feeling is that putting more distance between the expression and the package it was run in is not a win for me. Plus you'd have to put point on it to determine it that way which is quite inconvenient.
Do you want to see that kind of prompt in an editor buffer or let the editor take care of it?
In a normal Lisp buffer I agree - its primary purpose is editing the file, and interaction with the Lisp is secondary. Having a buffer-package shown on the mode-line works well in that case. However, I think the REPL buffer is a different story - interaction is primary there, so I think the prompt works well (for me).
I'm going a step further and changing the way the package and evaluation state are shown. It's purely for appearance. Would a REPL buffer be nicer if the left margins of all lines of input and output were aligned?
IMHO, no. I like having the input indented by the prompt because it helps delimit what exactly is input without relying on font faces.
Please experiment, though. Just make the end product be a customize option and everyone will be happy. :-)
-bcd
On 12/22/05, Brian Downing bdowning@lavos.net wrote:
On Wed, Dec 21, 2005 at 07:54:10PM -0800, Derek Peschel wrote:
Do you want to see that kind of prompt in an editor buffer or let the editor take care of it?
In a normal Lisp buffer I agree - its primary purpose is editing the file, and interaction with the Lisp is secondary. Having a buffer-package shown on the mode-line works well in that case. However, I think the REPL buffer is a different story - interaction is primary there, so I think the prompt works well (for me).
Just making a guess here, I don't think that Derek wants a REPL at all -- probably something more like an elisp scratch buffer or a Smalltalk transcript. SLIME does have a scratch buffer, and I've periodically hacked a slime-scratch minor mode so I can have multiple scratch buffers, associated with different packages, and have them associated with files. My current slime-scratch doesn't always behave correctly, but if there's interest, I can clear it with my manager and post it as a starting point.
For those of us who use rt to do testing, scratch buffers are really nice, since having a form directly above the printed representation of its result is almost all you need to write a deftest.
In article b61efa90512220217s64926446le177758ad5d59966@mail.gmail.com, Thomas F. Burdick wrote:
Just making a guess here, I don't think that Derek wants a REPL at all -- probably something more like an elisp scratch buffer or a Smalltalk transcript.
Both REPLs and scratch buffers (or file buffers) are useful for different reasons.
REPLs give a structure to the buffer because you can only add input at the end. They also make evaluation easy (just press return). Scratch buffers are flexible but totally unstructured -- you can edit anything at any time. In scratch buffers, Emacs's evaluate-last-sexp, or Smalltalk's Esc (to select what was last typed) followed by the key to evaluate the selection, give you a little bit of structure, but not the same as in a REPL.
My big goal is to find the right concept of structure -- e.g., ordinary text or LISP expressions or expression/result pairs or many others -- for the task at hand. I then want to design a set of uniform commands to navigate and edit according to the current definition of structure.
And changing the appearance of buffers shows or hides certain kinds of structure. With no prompt, the REPL looks more like a bunch of LISP expressions, but still colored to show input vs. output.
with files. My current slime-scratch doesn't always behave correctly, but if there's interest, I can clear it with my manager and post it as a starting point.
Please do, it sounds generally useful. When does it not behave correctly?
-- Derek