unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
From: Andy Wingo <wingo@pobox.com>
To: Evan Davis <erdavis7@gmail.com>
Cc: 23500-done@debbugs.gnu.org
Subject: bug#23500: Manual:4.3 Guile Scripting: Show to a layman that Guile can invoke shell commands, which are common in bash scripts.
Date: Tue, 28 Feb 2017 16:23:45 +0100	[thread overview]
Message-ID: <87h93el4ou.fsf@pobox.com> (raw)
In-Reply-To: <CA+oSkdmLFG-A1FqWQRkhO8gniF4y5GWPiaz-G9LyxTLQSXm13Q@mail.gmail.com> (Evan Davis's message of "Mon, 9 May 2016 18:48:26 -0400")

On Tue 10 May 2016 00:48, Evan Davis <erdavis7@gmail.com> writes:

> In §4.3 (Guile Scripting) please mention §7.2.7 (Processes), or at
> least the system/system* and open-pipe procedures.  Maybe include an
> example of a guile script invoking shell commands, as is common in
> bash.  As a layman, the manual's scripting section left me unsure
> whether Guile could easily replace my typical bash scripts, and I
> needed further help from Wingo on <irc://irc.freenode.net/guile>.

Tx for the report.  Added this text to the end of the section:

  Finally, seasoned scripters are probably missing a mention of
  subprocesses.  In Bash, for example, most shell scripts run other
  programs like @code{sed} or the like to do the actual work.

  In Guile it's often possible get everything done within Guile itself, so
  do give that a try first.  But if you just need to run a program and
  wait for it to finish, use @code{system*}.  If you need to run a
  sub-program and capture its output, or give it input, use
  @code{open-pipe}.  @xref{Processes}, and @xref{Pipes}, for more
  information.

Andy





      reply	other threads:[~2017-02-28 15:23 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-09 22:48 bug#23500: Manual:4.3 Guile Scripting: Show to a layman that Guile can invoke shell commands, which are common in bash scripts Evan Davis
2017-02-28 15:23 ` Andy Wingo [this message]

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=87h93el4ou.fsf@pobox.com \
    --to=wingo@pobox.com \
    --cc=23500-done@debbugs.gnu.org \
    --cc=erdavis7@gmail.com \
    /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).