aboutsummaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorPete Wyckoff <pw@padd.com>2011-02-19 08:17:58 -0500
committerJunio C Hamano <gitster@pobox.com>2011-02-21 09:56:56 -0800
commitd88e707f17ddcf3f789ec7fb1eb33121cecdcd67 (patch)
tree580805f890d49f3a127d2e276f872df3c5fe4ab6 /contrib
parent56c093451c7b2b485b194943ea071aca4e74733d (diff)
downloadgit-d88e707f17ddcf3f789ec7fb1eb33121cecdcd67.tar.gz
git-d88e707f17ddcf3f789ec7fb1eb33121cecdcd67.tar.xz
git-p4: reinterpret confusing p4 message
Error output will look like this: glom$ git p4 clone //deopt Importing from //deopt into . Reinitialized existing Git repository in /tmp/x/.git/ Doing initial import of //deopt from revision #head into refs/remotes/p4/master p4 returned an error: //deopt/... - must refer to client glom. This particular p4 error is misleading. Perhaps the depot path was misspelled. Depot path: //deopt Signed-off-by: Pete Wyckoff <pw@padd.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'contrib')
-rwxr-xr-xcontrib/fast-import/git-p44
1 files changed, 4 insertions, 0 deletions
diff --git a/contrib/fast-import/git-p4 b/contrib/fast-import/git-p4
index db19b1778..6b847c4cb 100755
--- a/contrib/fast-import/git-p4
+++ b/contrib/fast-import/git-p4
@@ -1445,6 +1445,10 @@ class P4Sync(Command):
if 'code' in info and info['code'] == 'error':
sys.stderr.write("p4 returned an error: %s\n"
% info['data'])
+ if info['data'].find("must refer to client") >= 0:
+ sys.stderr.write("This particular p4 error is misleading.\n")
+ sys.stderr.write("Perhaps the depot path was misspelled.\n");
+ sys.stderr.write("Depot path: %s\n" % " ".join(self.depotPaths))
sys.exit(1)
if 'p4ExitCode' in info:
sys.stderr.write("p4 exitcode: %s\n" % info['p4ExitCode'])