Exemplo n.º 1
0
def review_branch():
    """Diff against an arbitrary revision, branch, tag, etc."""
    branch = choose_ref(N_('Select Branch to Review'), N_('Review'))
    if not branch:
        return
    merge_base = gitcmds.merge_base_parent(branch)
    difftool.diff_commits(qtutils.active_window(), merge_base, branch)
Exemplo n.º 2
0
def diff_revision():
    """Diff an arbitrary revision against the worktree"""
    ref = choose_ref('Select Revision to Diff', 'Diff',
                     default='HEAD^')
    if not ref:
        return
    difftool.diff_commits(qtutils.active_window(), ref, None)
Exemplo n.º 3
0
def diff_revision():
    """Diff an arbitrary revision against the worktree"""
    ref = choose_ref('Select Revision to Diff', 'Diff',
                     default='HEAD^')
    if not ref:
        return
    difftool.diff_commits(qtutils.active_window(), ref, None)
Exemplo n.º 4
0
 def diff_commits(self, a, b):
     paths = self.dag.paths()
     if paths:
         difftool.launch([a, b, '--'] + paths)
     else:
         difftool.diff_commits(self, a, b)
Exemplo n.º 5
0
 def diff_commits(self, a, b):
     paths = self.dag.paths()
     if paths:
         difftool.launch([a, b, '--'] + paths)
     else:
         difftool.diff_commits(self, a, b)
Exemplo n.º 6
0
 def _diff_selected_this(self):
     clicked_sha1 = self._clicked_item.commit.sha1
     selected_sha1 = self._selected_item.commit.sha1
     difftool.diff_commits(self, selected_sha1, clicked_sha1)
Exemplo n.º 7
0
 def diff_commits(self, a, b):
     paths = self.ctx.paths()
     if paths:
         difftool.launch(left=a, right=b, paths=paths)
     else:
         difftool.diff_commits(self, a, b)
Exemplo n.º 8
0
 def diff_commits(self, a, b):
     paths = self.ctx.paths()
     if paths:
         difftool.launch(left=a, right=b, paths=paths)
     else:
         difftool.diff_commits(self, a, b)