def resolve_conflicts():
return self.wc.resolveConflicts()
shell.call("git", "config", "merge.conflictstyle", "diff3")
+ # setup rerere
+ if self.options.rr_cache is None:
+ self.options.rr_cache = os.path.join(self.prod.location, ".git", "rr-cache")
+ if not os.path.exists(self.options.rr_cache):
+ os.mkdir(self.options.rr_cache)
+ os.symlink(self.options.rr_cache, os.path.join(self.wc.location, ".git", "rr-cache"))
shell.call("git", "config", "rerere.enabled", "true")
try:
merge.merge(self.wc.app_version.scripts_tag, self.version,
default=False, help="Force running upgrade even if it's already at latest version.")
parser.add_option("--non-interactive", dest="non_interactive", action="store_true",
default=False, help="Don't drop to shell in event of conflict.")
+ parser.add_option("--rr-cache", dest="rr_cache", metavar="PATH",
+ default=None, help="Use this folder to reuse recorded merge resolutions. Defaults to"
+ "your production copy's rr-cache, if it exists.")
baton.push(parser, "srv_path")
options, args = parser.parse_all(argv)
if len(args) > 1: