chicken-users
[Top][All Lists]
Advanced

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

[Chicken-users] Configuring readline prompt


From: Peter Wright
Subject: [Chicken-users] Configuring readline prompt
Date: Sat, 11 Mar 2006 00:47:51 +0800
User-agent: Mutt/1.4.2.1i

Hi all,

I'm trying to use the readline egg for Chicken just to make it a
little easier to edit at the REPL. The readline.egg documentation
suggests adding these lines to ~/.csirc :

----------------------------------------------------------------------
(require 'readline)
(current-input-port (make-gnu-readline-port "csi> "))
(gnu-history-install-file-manager (string-append (or (getenv "HOME") ".") 
"/.csi.history"))
----------------------------------------------------------------------

This essentially works fine - the only problem is that you end up with
a really boring prompt. I prefer the default Chicken prompt that
includes a history number, eg.

----------------------------------------------------------------------
Version 2, Build 3 - linux-unix-gnu-x86 - [ dload ptables ]
(c)2000-2005 Felix L. Winkelmann
; loading /home/pete/.csirc ...
; loading /usr/lib/chicken/readline.so ...
#;1> 0
0
#;2>
----------------------------------------------------------------------


Is there a way to include this sort of information in the readline
string defined with make-gnu-readline-port?


Thanks,

Pete.
-- 
http://flooble.net/blog
"Debugging or reading Unlambda programs is just about impossible."
    -- Unlambda: Your Functional Programming Language Nightmares Come True




reply via email to

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