From: Barry Margolin <barmar@alum.mit.edu>
To: help-gnu-emacs@gnu.org
Subject: Re: Buffer or string as file input?
Date: Fri, 21 Feb 2014 18:46:35 -0500 [thread overview]
Message-ID: <barmar-4003D4.18463521022014@news.eternal-september.org> (raw)
In-Reply-To: e6be9402-c808-4e60-af58-6d7ee6d7ed47@googlegroups.com
In article <e6be9402-c808-4e60-af58-6d7ee6d7ed47@googlegroups.com>,
Jonathon McKitrick <jmckitrick@gmail.com> wrote:
> I need to call CALL-PROCESS but the stdin argument will be a string I am
> constructing. I would prefer to avoid writing that to a file just to read it
> into the command.
>
> Is there a way to use a buffer or string as a file input, like a stream?
call-process-region uses a region in the current buffer as stdin for the
process.
--
Barry Margolin, barmar@alum.mit.edu
Arlington, MA
*** PLEASE post questions in newsgroups, not directly to me ***
prev parent reply other threads:[~2014-02-21 23:46 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-21 20:05 Buffer or string as file input? Jonathon McKitrick
2014-02-21 23:46 ` Barry Margolin [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/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=barmar-4003D4.18463521022014@news.eternal-september.org \
--to=barmar@alum.mit.edu \
--cc=help-gnu-emacs@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).