# HG changeset patch # User Matt Harbison # Date 1346894768 14400 # Node ID 98d6a10bc401977a61bb5a0bdd145c13412ebb55 # Parent 26ebc7f72fe6ab04e66245891622441031929c48 largefiles: preserve exit code from outgoing command (issue3611) This maintains the exit codes documented in commands.py. diff -r 26ebc7f72fe6 -r 98d6a10bc401 hgext/largefiles/overrides.py --- a/hgext/largefiles/overrides.py Tue Sep 11 10:59:21 2012 -0300 +++ b/hgext/largefiles/overrides.py Wed Sep 05 21:26:08 2012 -0400 @@ -968,7 +968,7 @@ return toupload def overrideoutgoing(orig, ui, repo, dest=None, **opts): - orig(ui, repo, dest, **opts) + result = orig(ui, repo, dest, **opts) if opts.pop('large', None): toupload = getoutgoinglfiles(ui, repo, dest, **opts) @@ -980,6 +980,8 @@ ui.status(lfutil.splitstandin(file) + '\n') ui.status('\n') + return result + def overridesummary(orig, ui, repo, *pats, **opts): try: repo.lfstatus = True diff -r 26ebc7f72fe6 -r 98d6a10bc401 tests/test-largefiles.t --- a/tests/test-largefiles.t Tue Sep 11 10:59:21 2012 -0300 +++ b/tests/test-largefiles.t Wed Sep 05 21:26:08 2012 -0400 @@ -1144,6 +1144,15 @@ largefiles can be pushed locally (issue3583) $ hg init dest $ cd r4 + $ hg outgoing ../dest + comparing with ../dest + searching for changes + changeset: 0:639881c12b4c + tag: tip + user: test + date: Thu Jan 01 00:00:00 1970 +0000 + summary: m1 + $ hg push ../dest pushing to ../dest searching for changes @@ -1152,6 +1161,13 @@ adding manifests adding file changes added 1 changesets with 1 changes to 1 files + +exit code with nothing outgoing (issue3611) + $ hg outgoing ../dest + comparing with ../dest + searching for changes + no changes found + [1] $ cd .. #if serve