equal
deleted
inserted
replaced
59 |
59 |
60 if choice: |
60 if choice: |
61 return choice.values()[0] |
61 return choice.values()[0] |
62 |
62 |
63 raise error.UnknownCommand(cmd) |
63 raise error.UnknownCommand(cmd) |
|
64 |
|
65 def findrepo(p): |
|
66 while not os.path.isdir(os.path.join(p, ".hg")): |
|
67 oldp, p = p, os.path.dirname(p) |
|
68 if p == oldp: |
|
69 return None |
|
70 |
|
71 return p |
64 |
72 |
65 def bail_if_changed(repo): |
73 def bail_if_changed(repo): |
66 if repo.dirstate.parents()[1] != nullid: |
74 if repo.dirstate.parents()[1] != nullid: |
67 raise util.Abort(_('outstanding uncommitted merge')) |
75 raise util.Abort(_('outstanding uncommitted merge')) |
68 modified, added, removed, deleted = repo.status()[:4] |
76 modified, added, removed, deleted = repo.status()[:4] |