[PATCH 3 of 3] bookmarks: pass arguments to original rollback
Steve Borho
steve at borho.org
Sat Apr 10 19:02:42 CDT 2010
On Sat, Apr 10, 2010 at 5:45 PM, Matt Mackall <mpm at selenic.com> wrote:
> On Sat, 2010-04-10 at 15:11 -0500, Steve Borho wrote:
>> # HG changeset patch
>> # User Steve Borho <steve at borho.org>
>> # Date 1270851817 18000
>> # Node ID a65b552a4f596294c070f45bda553d34b9f274f2
>> # Parent 94abbee7074159c46d85c05be99ee3f3fbb49887
>> bookmarks: pass arguments to original rollback
>>
>> diff -r 94abbee70741 -r a65b552a4f59 hgext/bookmarks.py
>> --- a/hgext/bookmarks.py Fri Apr 09 17:23:37 2010 -0500
>> +++ b/hgext/bookmarks.py Fri Apr 09 17:23:37 2010 -0500
>> @@ -241,10 +241,10 @@
>> file.close()
>> return mark
>>
>> - def rollback(self):
>> + def rollback(self, *args):
>> if os.path.exists(self.join('undo.bookmarks')):
>> util.rename(self.join('undo.bookmarks'), self.join('bookmarks'))
>> - return super(bookmark_repo, self).rollback()
>> + return super(bookmark_repo, self).rollback(*args)
>>
>> def lookup(self, key):
>> if key in self._bookmarks:
>
> A quick observation:
>
> Generally, a patch like this should be first in the series, rather than
> last. You should aim to have each patch leave the project in a working
> state. If someone later tries to bisect a problem in bookmarks and they
> land on the changeset right before this, they may lose.
I've folded it into the second patch, where the --dry-run argument is
introduced.
Thanks,
--
Steve Borho
More information about the Mercurial-devel
mailing list