equal
deleted
inserted
replaced
42 New commands |
42 New commands |
43 ------------ |
43 ------------ |
44 |
44 |
45 A ``debugobsolete`` command was added. It adds an obsolete relation between two |
45 A ``debugobsolete`` command was added. It adds an obsolete relation between two |
46 nodes. |
46 nodes. |
|
47 |
|
48 Note that rebased changesets are not marked obsolete rather than being stripped |
|
49 In this experimental extensions, this is done forcing the --keep option. Trying |
|
50 to use the --keep option of rebase with this extensionn this experimental |
|
51 extension will cause such a call to abort. Until better releasen please use |
|
52 graft command to rebase and copy changesets. |
47 |
53 |
48 Context object |
54 Context object |
49 -------------- |
55 -------------- |
50 |
56 |
51 Context gains a ``obsolete`` method that will return True if a changeset is |
57 Context gains a ``obsolete`` method that will return True if a changeset is |
229 newnode = repo[newrev].node() |
235 newnode = repo[newrev].node() |
230 repo.addobsolete(newnode, oldnode) |
236 repo.addobsolete(newnode, oldnode) |
231 return newrev |
237 return newrev |
232 |
238 |
233 def cmdrebase(orig, ui, repo, *args, **kwargs): |
239 def cmdrebase(orig, ui, repo, *args, **kwargs): |
234 oldkeep = kwargs.pop('keep', False) |
240 if kwargs.get('keep', False): |
235 if oldkeep: |
241 raise util.Abort(_('rebase --keep option is unsupported with obsolete ' |
236 ui.warn('WARNING --keep option ignored by experimental obsolete extension') |
242 'extension'), hint=_("see 'hg help obsolete'")) |
|
243 kwargs = dict(kwargs) |
237 kwargs['keep'] = True |
244 kwargs['keep'] = True |
238 return orig(ui, repo, *args, **kwargs) |
245 return orig(ui, repo, *args, **kwargs) |
239 |
246 |
240 |
247 |
241 |
248 |