def checkout(self, ref): """Checkout ref in clowder repo""" repo = ProjectRepo(self.clowder_path, self.remote, self.default_ref) if self.is_dirty(): print(' - Dirty repo. Please stash, commit, or discard your changes') repo.status_verbose() return repo.checkout(ref)
def diff(self): """Show git diff for project""" if not os.path.isdir(self.full_path()): print(colored(" - Project is missing\n", 'red')) return repo = ProjectRepo(self.full_path(), self._remote, self._ref) repo.status_verbose()
def git_status(self): """Print clowder repo git status""" repo = ProjectRepo(self.clowder_path, self.remote, self.default_ref) repo.status_verbose()