Path: csiph.com!news.neodome.net!tr3.eu1.usenetexpress.com!feeder.usenetexpress.com!tr3.iad1.usenetexpress.com!69.80.99.32.MISMATCH!Xl.tags.giganews.com!local-2.nntp.ord.giganews.com!news.giganews.com.POSTED!not-for-mail NNTP-Posting-Date: Thu, 15 Oct 2026 19:06:18 +0000 From: steve g Newsgroups: comp.lang.lisp Subject: Re: REPL, streams, SBCL References: <87wlrmeha9.fsf@gmail.com> <11ajq5a$2i7p$1@dont-email.me> Date: Thu, 15 Oct 2026 15:06:01 -0400 Message-ID: <8733u6wzqe.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Cancel-Lock: sha1:qqciwNnnmguUpN8diPWJWVy3zJs= MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Lines: 67 X-Usenet-Provider: http://www.giganews.com X-Trace: sv3-uaA5IASvW4XDw30zR0b7N8IOmKuB8NrmYbU77d2f2M0VGTYQMuYX/wLPoHHMH+IDTFS7sZUXLKDcRVc!mUEXyLq024HIyjYaZn4Lt/f3tfO2LLg5INYSGoUxe+ZatyY= X-Complaints-To: abuse@giganews.com X-DMCA-Notifications: http://www.giganews.com/info/dmca.html X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.3.40 Xref: csiph.com comp.lang.lisp:61739 Lawrence D’Oliveiro writes: > On Mon, 12 Oct 2026 17:32:46 -0400, steve g wrote: > >> I was interested in changing the REPL for SBCL. > > Probably easier to run it in an environment like Jupyter. Even without > a custom SBCL kernel, just the regular “%%script magic” already lets > you do some useful things. > > ← > %%script sbcl > (+ 2 2) > → > This is SBCL 2.6.4.debian, an implementation of ANSI Common Lisp. > More information about SBCL is available at . > > SBCL is free software, provided as is, with absolutely no warranty. > It is mostly in the public domain; some portions are provided under > BSD-style licenses. See the CREDITS and COPYING files in the > distribution for more information. > * 4 > * > You probably want to turn off the startup banner message, and the “*” > characters from the default prompting for input by the REPL. The > `--script` option does this, but it also turns off automatic output of > expression values: Yes. again, this has changed my thinking; --script, like duh! You know they say the best way to check your documant is by getting someone else to read it; thank you for this. > ← > %%script sbcl --script > (+ 2 2) ; produces no output > (princ (+ 2 2)) ; need to do explicit output > → > 4 This is very helpful. I did not even think about this. > This may be OK for running functional scripts, but it is not so > convenient for simple experimentation. > > Alternatively, the `--noinform` option turns off the startup banner. > You can then change the prompt to the empty string by setting the > SBCL-specific `sb-aclrepl:*prompt*` variable. To access this, you need > to `require` the `sb-aclrepl` package. To avoid spurious output, this > can all be done with `--eval` options on the command line: > > ← > %%script sbcl --noinform --eval "(require 'sb-aclrepl)" --eval "(setq sb-aclrepl:*prompt* \"\")" > (+ 2 2) > → > 4 > > Gets a bit complicated, but at least it’s not always necessary ... agreed. thank you for your spare eyes and your time.