unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
From: <tomas@tuxteam.de>
To: guile-user@gnu.org
Subject: Re: REPL history
Date: Sun, 5 Mar 2017 18:57:13 +0100	[thread overview]
Message-ID: <20170305175713.GA19769@tuxteam.de> (raw)
In-Reply-To: <20170305170631.GA4916@localhost.localdomain>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Sun, Mar 05, 2017 at 08:06:31PM +0300, Vladimir Zhbanov wrote:
> Hi Guile users,
> 
> Is there any way to use history of work done in a spawned REPL?
> 
> My GUI application spawns a REPL server in background terminal:
> 
> (use-modules (system repl server))
> (spawn server)
> 
> Then users manually run:
> (use-modules (ice-9 readline))
> (activate readline)
> 
> However, after quitting the application, the history is not
> saved. I always see the history of commands used in guile itself,
> not one of my app.
> 
> When I use readline-options, it shows some file is used:
> 
> scheme@(guile-user)> (readline-options 'history)
> history-file		yes	Use history file.
> history-length		200	History length.
> bounce-parens		500	Time (ms) to show matching opening parenthesis (0 = off).
> 
> I don't know which file is used, anyway.

Here it is ~/.guile_history (perhaps this helps you in your quest). And
the manual has this to say:

   You can specify a different history file by setting the environment
   variable `GUILE_HISTORY'.  And you can make Guile specific
   customizations to your `.inputrc' by testing for application `Guile'

I don't know off-the-bat whether there's a way to change that (other than
setting the environment variable, that is)

> Are there any options to get history in spawned REPL?

Hm. I'm not sure I understand what you mean.

Regards
- -- tomás
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iEYEARECAAYFAli8UXkACgkQBcgs9XrR2kbYbACfbix3bIKrrHHMqlGGMezQUV+j
RzgAn0H0qfKvkqcSmnWkr48Y8PnyTxn8
=eaGw
-----END PGP SIGNATURE-----



  reply	other threads:[~2017-03-05 17:57 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-05 17:06 REPL history Vladimir Zhbanov
2017-03-05 17:57 ` tomas [this message]
2017-03-06 19:15   ` Vladimir Zhbanov
2017-03-06 20:29     ` tomas
2017-03-06 20:48     ` Andy Wingo
2017-03-06 21:44       ` Vladimir Zhbanov
2017-03-07  9:23         ` Andy Wingo
2017-03-07 14:44           ` Vladimir Zhbanov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/guile/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170305175713.GA19769@tuxteam.de \
    --to=tomas@tuxteam.de \
    --cc=guile-user@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).