Saving my work ,effectively, in lisp-in-a-box?

Discussion of Common Lisp
Post Reply
kapalua
Posts: 7
Joined: Tue Feb 16, 2010 3:32 am

Saving my work ,effectively, in lisp-in-a-box?

Post by kapalua » Wed Feb 24, 2010 1:24 pm

Hi,

I'm learning this brilliant language and i'm using lisp-in-a-box. One "problem" i have is when want to save what i write.

Do i really need to create a new file and write the code again in that file? Is there not a more effective way?

ramarren
Posts: 613
Joined: Sun Jun 29, 2008 4:02 am
Location: Warsaw, Poland
Contact:

Re: Saving my work ,effectively, in lisp-in-a-box?

Post by ramarren » Wed Feb 24, 2010 1:35 pm

You posted in Emacs Lisp forum, but as far as I know lisp-in-a-box is a Common Lisp implementation bundled with Emacs? Which Lisp are you using (Emacs Lisp and Common Lisp are quite different). In any case, write your definitions in a file in the first place and load the files (or single forms using appropriate Emacs commands), rather than writing into the REPL or scratch buffer.

gugamilare
Posts: 406
Joined: Sat Mar 07, 2009 6:17 pm
Location: Brazil
Contact:

Re: Saving my work ,effectively, in lisp-in-a-box?

Post by gugamilare » Wed Feb 24, 2010 2:53 pm

Well, it looks like you are struggling with Emacs. Try Emacs' tutorial. When you open Emacs, there should be a link to it, or you can start it hitting C-h t (hold the Ctrl button and press H, then release and press T) or from the Help menu.

To open a file, use C-x C-f (hold Ctrl, press x, hold Ctrl and press f). Always open a file to create a new file. To save, C-x C-s. You can also save / open from the File menu.

Emacs is very powerful once you learn it, but, if you want a more standard editor, you can try Cusp, a plugin for Eclipse (take a look at this tutorial).

Paul Donnelly
Posts: 148
Joined: Wed Jul 30, 2008 11:26 pm

Re: Saving my work ,effectively, in lisp-in-a-box?

Post by Paul Donnelly » Wed Feb 24, 2010 8:36 pm

kapalua wrote:Hi,

I'm learning this brilliant language and i'm using lisp-in-a-box. One "problem" i have is when want to save what i write.

Do i really need to create a new file and write the code again in that file? Is there not a more effective way?
Don't write code in the REPL. It's just for throwaway stuff. Type in a buffer to begin with. Use Emacs's help functions to see what C-c C-c and C-c C-k do when in Lisp mode.

kapalua
Posts: 7
Joined: Tue Feb 16, 2010 3:32 am

Re: Saving my work ,effectively, in lisp-in-a-box?

Post by kapalua » Thu Feb 25, 2010 3:04 am

Sorry about posting in incorrect forum and many thanks for the answers!

nuntius
Posts: 538
Joined: Sat Aug 09, 2008 10:44 am
Location: Newton, MA

Re: Saving my work ,effectively, in lisp-in-a-box?

Post by nuntius » Sat Feb 27, 2010 8:03 am

See also DRIBBLE. It saves a log of your REPL. Then you can still work iteratively in the repl and later retrieve useful snippets to put in a file.
http://www.lispworks.com/documentation/ ... dribbl.htm

I thought someone (Pascal Bourguignon?) had an enhanced dribble, but couldn't find it.

Post Reply