106 ) |
107 ) |
107 # set the new commit is proper phase |
108 # set the new commit is proper phase |
108 targetphase = subrepoutil.newcommitphase(repo.ui, ctx) |
109 targetphase = subrepoutil.newcommitphase(repo.ui, ctx) |
109 |
110 |
110 # prevent unmarking changesets as public on recommit |
111 # prevent unmarking changesets as public on recommit |
111 waspublic = oldtip == repo.changelog.tiprev() and not repo[n].phase() |
112 waspublic = oldtip == repo.changelog.tiprev() and not repo[rev].phase() |
112 |
113 |
113 if targetphase and not waspublic: |
114 if targetphase and not waspublic: |
114 # retract boundary do not alter parent changeset. |
115 # retract boundary do not alter parent changeset. |
115 # if a parent have higher the resulting phase will |
116 # if a parent have higher the resulting phase will |
116 # be compliant anyway |
117 # be compliant anyway |
117 # |
118 # |
118 # if minimal phase was 0 we don't need to retract anything |
119 # if minimal phase was 0 we don't need to retract anything |
119 phases.registernew(repo, tr, targetphase, [repo[n].rev()]) |
120 phases.registernew(repo, tr, targetphase, [rev]) |
120 return n |
121 return n |
121 |
122 |
122 |
123 |
123 def _prepare_files(tr, ctx, error=False, origctx=None): |
124 def _prepare_files(tr, ctx, error=False, origctx=None): |
124 repo = ctx.repo() |
125 repo = ctx.repo() |