Ejemplo n.º 1
0
def create_new_branch(revision=''):
    """Launches a dialog for creating a new branch"""
    model = main.MainModel()
    model.update_status()
    view = CreateBranchDialog(model, qtutils.active_window())
    if revision:
        view.set_revision(revision)
    view.show()
    return view
Ejemplo n.º 2
0
def run(RemoteDialog):
    """Launches fetch/push/pull dialogs."""
    # Copy global stuff over to speedup startup
    model = main.MainModel()
    global_model = main.model()
    model.currentbranch = global_model.currentbranch
    model.local_branches = global_model.local_branches
    model.remote_branches = global_model.remote_branches
    model.tags = global_model.tags
    model.remotes = global_model.remotes
    parent = qtutils.active_window()
    view = RemoteDialog(model, parent=parent)
    view.show()
    return view
Ejemplo n.º 3
0
 def setUp(self):
     helper.GitRepositoryTestCase.setUp(self)
     self.model = main.MainModel(cwd=core.getcwd())