From: John Mastro <john.b.mastro@gmail.com>
To: "help-gnu-emacs@gnu.org" <help-gnu-emacs@gnu.org>
Subject: Program working with shell-command but not call-process
Date: Thu, 3 Jul 2014 09:46:43 -0700 [thread overview]
Message-ID: <CAOj2CQRhLYK1tWB404RgD3JJ59s3pbr-s8_PJwwN0i=BvWJB9Q@mail.gmail.com> (raw)
Does anyone know what situation would result in this working:
(shell-command-to-string "git --version")
;=> it returns "git version 2.0.1"
But not this:
(with-output-to-string
(call-process "git" nil standard-output nil "--version"))
;=> it returns ""
;=> `call-process' alone returns 53
This git is built and installed from source on Cygwin. It works fine
from the shell but not via `call-process', which means it doesn't work
with `magit'.
It's in my path (both $PATH and `exec-path'), and `executable-find'
finds it without problem at c:/usr/local/bin/git.exe.
The git that's availablefor install via Cygwin (quite old, v1.7.9),
succeeds with both the calls above. It's still installed at
c:/bin/git.exe.
Thanks,
John
next reply other threads:[~2014-07-03 16:46 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-03 16:46 John Mastro [this message]
2014-07-03 22:51 ` Program working with shell-command but not call-process Michael Heerdegen
[not found] <mailman.4812.1404406058.1147.help-gnu-emacs@gnu.org>
2014-07-04 10:16 ` Joost Kremers
2014-07-04 15:21 ` Michael Heerdegen
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAOj2CQRhLYK1tWB404RgD3JJ59s3pbr-s8_PJwwN0i=BvWJB9Q@mail.gmail.com' \
--to=john.b.mastro@gmail.com \
--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.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.