Re: GUILE_QUIET=1 guile → suppress REPL welcome message (fixed message format)

"Dr. Arne Babenhauserheide" <[email protected]>
Newsgroups gmane.lisp.guile.devel
Message-ID <[email protected]>
Hi Matt,

Matt Wette <[email protected]> writes:
> I got it working.   I made two changes:

Nice!

> 1) I updated the change to ice-9/command-line.scm.  The `patch'
> command rejected the location of the `-I' option placement.

> 2) I reverted the change to system/repl/common.scm which had changed
> the output of the welcome message from default output port to
> info-port. This was causing the repl-server test to fail. If a user
> uses Guile as a extension, and does not want the default Guile welcome
> message, they can generate their own repl.

Thank you!

This fixes the compilation messages (a very long standing complaint),
but I think it should also silence the license information message.

Since you’re already defining the info-fluid, you could check for that
similar to the following (but maybe cleaner: just checking for the info
port could byte us later on):

modified   module/system/repl/repl.scm
@@ -159,7 +159,8 @@
   (% (with-fluids ((*repl-stack*
                     (cons repl (or (fluid-ref *repl-stack*) '()))))
        (if (null? (cdr (fluid-ref *repl-stack*)))
-           (repl-welcome repl))
+           (when (file-port? (fluid-ref (parameter-fluid current-output-port)))
+             (repl-welcome repl)))
        (let prompt-loop ()
          (let ((exp (prompting-meta-read repl)))
            (cond


Do you see a cleaner way to do this? If you have one, that would be
great, because it would be the final step to make Guile much more
convenient for scripting (for example it would save me a ton of hacks
☺).


Best wishes,
Arne
-- 
Unpolitisch sein
heißt politisch sein,
ohne es zu merken.
draketo.de
signature.asc (application/pgp-signature, 1.1 KB)
-----BEGIN PGP SIGNATURE-----

iQJEBAEBCAAuFiEE801qEjXQSQPNItXAE++NRSQDw+sFAmcBE48QHGFybmVfYmFi
QHdlYi5kZQAKCRAT741FJAPD66UkEACSQe6WUlDQTSwA08aT/ZLRhcdGWjkajDhX
1CvVKcwNTPbUY8pzM+zxm8hNb/x/JvGXvzRykobVkSgTa/mxa0LUTAmt5ZxMy/W1
GioA8+ifyqxiBjtDxAvPPD7EO4QMVUxBCc32bLo4wrMFGnM4iTB/lp9KBG47mk12
V9vFRf8//dyIWcRPpr/hqVs/Jb9/BeDy35EVIzltTKc7YRkvRcTgZGfWaNIfHBcK
ljADJf5A2JhMyf9cSp9i22IF8eFp9szjju/vG33myLOLf9nyoWBAm2u9KBpwQA/w
l59ULs3VAgyuhF3+r0ZUGNVTaIqQzoRQQrJdIxXaDSNmk4TCR5vnub7LV2hGFh9a
8OanPZSP0qSmwkQpIfnQvoWuF6xquMhuceJoR2G1yPclQJBCLg6Dy6do8WcGVVIJ
zvleE6SrWkd0IL6PR0p5j2rNHd6ZIh5pkPzOZOrIu1Ac/Sz0lyXfN3y9W3zAoqKt
jUZ47lktEsv4nK5DjFJ1+tePk8UP86cxAr9FMW4jdsmBQdJNvRlx3WaXS6svpNyn
dEEHNZI5eDWwSOm6lKA3mHHpSvQhGT9X7IsVs8tVOcCMzrxuATUeg6IWCzxcirxX
hKTtYU3bjHt9Gkndh9Ssuhz0d85zO6bvQrqIlPxaaK15mW2g/j7NhU0WdIC/6emK
I2O6dhDbrIjEBAEBCAAuFiEE3Si95tmHXKvOSosd3M8NswvBBUgFAmcBE48QHGFy
bmVfYmFiQHdlYi5kZQAKCRDczw2zC8EFSAhRA/94yjA98IxcFE06AtKx+JRJp75S
Snsi6K5gl3Mf06qSLWUQwFtwKGzT14UPc1oJlH+IGtisrn03W5VuL3d9uKlCmul8
Y0DWQKv1hkpZrDOaca7eaBsX2WMhSlv+zPi6+BrBVTXzCiNMQDF0HzpcmZTVI26J
oJuehtCWw4g0Nzjwug==
=z46X
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.