git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RFC PATCH 0/2] Report remote helper exec failures
@ 2009-12-24 17:49 Ilari Liusvaara
  2009-12-24 17:49 ` [RFC PATCH 1/2] Report exec errors from run-command Ilari Liusvaara
  2009-12-24 17:49 ` [RFC PATCH 2/2] Improve transport helper exec failure reporting Ilari Liusvaara
  0 siblings, 2 replies; 11+ messages in thread
From: Ilari Liusvaara @ 2009-12-24 17:49 UTC (permalink / raw)
  To: git

Actually give useful error messages if executing git remote helper fails
for some reason.

The previous error message was:

git: 'remote-fail' is not a git-command. See 'git --help'

This changes the error message to:

'Unable to find remote helper for "nonexistent"'

or

'Unable to run helper HelperThatGetsEACCESS: Permission denied' 
(or whatever the errno is).


Patch series is based on v1.6.6.

One of the changes is adjacent to changes in external helper dispatch
support change and gets merge conflict. Here's how I resolved that
conflict for testing:

        helper->argv[2] = remove_ext_force(transport->url);
        helper->git_cmd = 0;
        if (start_command(helper)) {
                if (errno == ENOENT)
                        die("Unable to find remote helper for \"%s\"",
                                data->name);
                else
                        die("Unable to run helper %s: %s", helper->argv[0],
                                strerror(errno));
        }

The first line in that comes from dispatch support and the rest come from
exec failure reporting.


Ilari Liusvaara (2):
  Report exec errors from run-command
  Improve transport helper exec failure reporting

 run-command.c      |   72 +++++++++++++++++++++++++++++++++++++++++++++++++--
 transport-helper.c |   14 +++++++---
 2 files changed, 79 insertions(+), 7 deletions(-)

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2009-12-25 17:15 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-12-24 17:49 [RFC PATCH 0/2] Report remote helper exec failures Ilari Liusvaara
2009-12-24 17:49 ` [RFC PATCH 1/2] Report exec errors from run-command Ilari Liusvaara
2009-12-25  7:35   ` Junio C Hamano
2009-12-25  7:46     ` Junio C Hamano
2009-12-25  8:40     ` Junio C Hamano
2009-12-25  9:51     ` Ilari Liusvaara
2009-12-25 14:39   ` Johannes Sixt
2009-12-25 17:15     ` Ilari Liusvaara
2009-12-24 17:49 ` [RFC PATCH 2/2] Improve transport helper exec failure reporting Ilari Liusvaara
2009-12-25  7:44   ` Junio C Hamano
2009-12-25  9:32     ` Ilari Liusvaara

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 NNTP newsgroup(s).