##// END OF EJS Templates
Use simplified cached repos list for quick repo switcher, in some cases it can have 2-3x speed-up since it doesn't need to init the scms
Use simplified cached repos list for quick repo switcher, in some cases it can have 2-3x speed-up since it doesn't need to init the scms

File last commit:

r2543:03a77098 beta
r2604:dfa5180c beta
Show More
workdir.py
21 lines | 672 B | text/x-python | PythonLexer
Added VCS into rhodecode core for faster and easier deployments of new versions
r2007 from rhodecode.lib.vcs.backends.base import BaseWorkdir
from rhodecode.lib.vcs.exceptions import BranchDoesNotExistError
Synced vcs with upstream
r2543 from rhodecode.lib.vcs.utils.hgcompat import hg_merge
Added VCS into rhodecode core for faster and easier deployments of new versions
r2007
class MercurialWorkdir(BaseWorkdir):
def get_branch(self):
return self.repository._repo.dirstate.branch()
def get_changeset(self):
return self.repository.get_changeset()
def checkout_branch(self, branch=None):
if branch is None:
branch = self.repository.DEFAULT_BRANCH_NAME
if branch not in self.repository.branches:
raise BranchDoesNotExistError
hg_merge.update(self.repository._repo, branch, False, False, None)