Mercurial > public > mercurial-scm > hg
comparison mercurial/commands.py @ 11067:49e14ec67144 stable
subrepo: propagate and catch push failures
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Fri, 30 Apr 2010 18:32:18 -0500 |
parents | a0102da324ab |
children | 37d1b20168d1 9f2c0dd91389 |
comparison
equal
deleted
inserted
replaced
11066:26abd91d9e84 | 11067:49e14ec67144 |
---|---|
2451 | 2451 |
2452 # push subrepos depth-first for coherent ordering | 2452 # push subrepos depth-first for coherent ordering |
2453 c = repo[''] | 2453 c = repo[''] |
2454 subs = c.substate # only repos that are committed | 2454 subs = c.substate # only repos that are committed |
2455 for s in sorted(subs): | 2455 for s in sorted(subs): |
2456 c.sub(s).push(opts.get('force')) | 2456 if not c.sub(s).push(opts.get('force')): |
2457 return False | |
2457 | 2458 |
2458 r = repo.push(other, opts.get('force'), revs=revs) | 2459 r = repo.push(other, opts.get('force'), revs=revs) |
2459 return r == 0 | 2460 return r == 0 |
2460 | 2461 |
2461 def recover(ui, repo): | 2462 def recover(ui, repo): |