repo.head.reset(self.commit, working_tree=True)
else:
repo.git.rebase(self.commit)
repo.head.reset(self.commit, working_tree=True)
else:
repo.git.rebase(self.commit)
print "...done",
if repo.head.reference.commit != repo.commit(self.commit):
print "(keeping local patches around)",
print "...done",
if repo.head.reference.commit != repo.commit(self.commit):
print "(keeping local patches around)",
def update(self, forceVersion=False):
if os.path.exists(self.folder):
def update(self, forceVersion=False):
if os.path.exists(self.folder):
if forceVersion: subprocess.check_call(['svn', 'revert', '-R', '.'])
subprocess.check_call(['svn', 'switch', self.url]) # and update to the URL we got
else:
if forceVersion: subprocess.check_call(['svn', 'revert', '-R', '.'])
subprocess.check_call(['svn', 'switch', self.url]) # and update to the URL we got
else:
subprocess.check_call(['svn', 'co', self.url, self.folder]) # just download it
subprocess.check_call(['svn', 'co', self.url, self.folder]) # just download it