Bug 415475

Summary: Provide selected commit(s) as variable for external tools
Product: [Technology] EGit Reporter: Robin Stocker <robin>
Component: UIAssignee: Project Inbox <egit.ui-inbox>
Status: NEW --- QA Contact:
Severity: enhancement    
Priority: P3 CC: klass, sascha-web-bugs.eclipse.org
Version: 3.1Keywords: helpwanted
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:

Description Robin Stocker CLA 2013-08-20 08:20:33 EDT
It would be nice if we could provide the commits that are selected in the history view to external tools, so that e.g. a launcher for "git difftool" could be created.

Currently, we offer these variables: git_branch, git_dir, git_repo_relative_path, git_work_tree.

We could add something like git_commit_1 and git_commit_2, or if there is support for an array of values, just git_commit[N] (don't know the syntax).

Should not be too hard to implement, patches welcome!

See the following question on Stackoverflow for the idea:

http://stackoverflow.com/questions/18294602/anyway-to-use-an-external-diff-editor-in-eclipse-with-egit

See also bug 356832 which is about supporting an external merge tool.