Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EGit / JGit » Execute Aliases From EGit UI
Execute Aliases From EGit UI [message #1277878] Wed, 26 March 2014 15:34 Go to next message
Blake Longmore is currently offline Blake LongmoreFriend
Messages: 2
Registered: March 2014
Junior Member
Is there a way to execute a created git alias command from the EGit UI? I have several aliases stored that I execute frequently that would be nice to be able to execute from within eclipse.

I use it mostly for git svn commands, but I could see how this might be helpful for plain git commands too, and would provide a sort of work around for those using git svn to get some desired functionality.
Re: Execute Aliases From EGit UI [message #1278020 is a reply to message #1277878] Wed, 26 March 2014 20:08 Go to previous messageGo to next message
Robin Rosenberg is currently offline Robin RosenbergFriend
Messages: 332
Registered: July 2009
Senior Member
Blake Longmore skrev 2014-03-26 17.51:
> Is there a way to execute a created git alias command from the EGit UI? I have several aliases stored that I execute frequently that would be nice to be able to execute
> from within eclipse.
>
> I use it mostly for git svn commands, but I could see how this might be helpful for plain git commands too, and would provide a sort of work around for those using git svn
> to get some desired functionality.

You can define "external tools" in Eclipse and they can of course invoke Git
and do whatever C Git does. Using variables like ${git_work_tree}
you can tell these commands which selected resource they should operate on.

-- robin
Re: Execute Aliases From EGit UI [message #1278595 is a reply to message #1278020] Thu, 27 March 2014 15:09 Go to previous messageGo to next message
Blake Longmore is currently offline Blake LongmoreFriend
Messages: 2
Registered: March 2014
Junior Member
Thank you for that suggestion. It works great. The only problem is when I try to run a git svn rebase --all, it prompts for my password with the username already populated. My username on my PC is different than my svn username and it appears to be populating the username with my PC username. This works fine if I run it from gitbash, since it prompted me for my username too. It seems a bit strange, since I was able to perform a svn dcommit and it remembered my username/password from my gitbash settings. Is there a way to get this working in the external tools? Thanks.

--EDIT--
I figured out the solution to this latest problem on my own. The answer is to create your external tool with the '--username=' flag set to the username you want to use. This works very nicely now. Thanks again for your help.

[Updated on: Thu, 27 March 2014 19:59]

Report message to a moderator

Re: Execute Aliases From EGit UI [message #1279288 is a reply to message #1278595] Fri, 28 March 2014 14:17 Go to previous messageGo to next message
R Shapiro is currently offline R ShapiroFriend
Messages: 386
Registered: June 2011
Senior Member
Quote:
You can define "external tools" in Eclipse and they can of course invoke Git
and do whatever C Git does. Using variables like ${git_work_tree}
you can tell these commands which selected resource they should operate on.


I have a collection of these I made some time ago which you can grab from github:

git@github.com:reshapiro/DVCS.git

Just import the Eclipse projects and the external launchers become available.

Re: Execute Aliases From EGit UI [message #1279337 is a reply to message #1277878] Fri, 28 March 2014 15:48 Go to previous message
R Shapiro is currently offline R ShapiroFriend
Messages: 386
Registered: June 2011
Senior Member
For svn bridging you might want to consider using my plugin, which uses the same EGit variables trick but makes the main operations more easily accessible via the Eclipse toolbar and supports other operations in a new Eclipse menu. Install from

http://home.comcast.net/~reshapiro/org.res.gitx/

You might need to turn off the "Group items by category" option. Some users have trouble with this, some don't,

The plugin source code is also available on github.



Previous Topic:Unable to remove .DS_Store from unstaged changes list
Next Topic:EGit with GitBlit
Goto Forum:
  


Current Time: Wed Apr 24 23:25:09 GMT 2024

Powered by FUDForum. Page generated in 0.02762 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top