From: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Comparing a patch after and before a merge is very important, and looking into
.git/patches by hand is not the nicer way to do it.
Signed-off-by: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
return series.get_patch(patch_name).get_top()
elif patch_id == 'bottom':
return series.get_patch(patch_name).get_bottom()
return series.get_patch(patch_name).get_top()
elif patch_id == 'bottom':
return series.get_patch(patch_name).get_bottom()
+ # Note we can return None here.
+ elif patch_id == 'top.old':
+ return series.get_patch(patch_name).get_old_top()
+ elif patch_id == 'bottom.old':
+ return series.get_patch(patch_name).get_old_bottom()
# base
if patch_name == 'base' and len(string_list) == 1:
# base
if patch_name == 'base' and len(string_list) == 1:
elif os.path.isfile(fname):
os.remove(fname)
elif os.path.isfile(fname):
os.remove(fname)
+ def get_old_bottom(self):
+ return self.__get_field('bottom.old')
+
def get_bottom(self):
return self.__get_field('bottom')
def get_bottom(self):
return self.__get_field('bottom')
self.__set_field('bottom.old', None)
self.__set_field('bottom', string)
self.__set_field('bottom.old', None)
self.__set_field('bottom', string)
+ def get_old_top(self):
+ return self.__get_field('top.old')
+
def get_top(self):
return self.__get_field('top')
def get_top(self):
return self.__get_field('top')