Bug 309355 - Add git-stash support
Summary: Add git-stash support
Status: RESOLVED FIXED
Alias: None
Product: JGit
Classification: Technology
Component: JGit (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 enhancement with 12 votes (vote)
Target Milestone: 2.0-M1   Edit
Assignee: Kevin Sawicki CLA
QA Contact:
URL: http://egit.eclipse.org/r/#change,4760
Whiteboard:
Keywords: noteworthy
: 334769 339153 (view as bug list)
Depends on:
Blocks: 359273
  Show dependency tree
 
Reported: 2010-04-15 13:36 EDT by Michael Pellaton CLA
Modified: 2012-04-02 19:58 EDT (History)
19 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Pellaton CLA 2010-04-15 13:36:56 EDT
Build Identifier: 

Enhance JGit and EGit to support stashes.

The equivalents of the following git command line commands shall be shupported
$ git stash
$ git stash apply

Reproducible: Always
Comment 1 Michael Pellaton CLA 2010-04-15 13:38:16 EDT
Perhaps, a GSoC project could provide the functionality:
http://wiki.eclipse.org/Google_Summer_of_Code_2010_Ideas
Comment 2 Remy Suen CLA 2010-09-14 09:20:59 EDT
The 0.8.x ship has sailed.
Comment 3 Chris Aniszczyk CLA 2011-03-07 22:05:16 EST
*** Bug 339153 has been marked as a duplicate of this bug. ***
Comment 4 Tuukka Mustonen CLA 2011-08-02 05:46:39 EDT
Seems like egit is still missing this and it would be nice to have it. 

Coming with Eclipse+SVN background, I love being able to open up the synchronize view at any point of time and checking out updates into my modified, uncommitted local checkout. As git prevents merging while there are uncommitted changes, it would be nice to integrate the git stashing into the synchronize view to support a similar workflow.

Could it be, for example, that when pull button was pressed in the synchronize view, egit would automatically stash the current changes, pull to merge the remote changes, and after resolving any possible conflicts in the synchronize view, egit would apply the stashed files back?

Also, it would be nice if egit listed the stashes in the same way as branches are listed under Team > Synchronize now with Egit 1.0.0.
Comment 5 Brad Cupit CLA 2011-08-15 15:30:36 EDT
(In reply to comment #0)

> The equivalents of the following git command line commands shall be shupported
> $ git stash
> $ git stash apply

Would also be nice to have these two:
$ git stash pop
$ git stash --keep-index
Comment 6 Szymon Brandys CLA 2011-11-03 06:37:32 EDT
*** Bug 334769 has been marked as a duplicate of this bug. ***
Comment 7 Szymon Brandys CLA 2011-11-03 06:39:12 EDT
Any news with this one?
Comment 8 Remy Suen CLA 2011-11-03 06:41:17 EDT
(In reply to comment #7)
> Any news with this one?

Don't think so. There's a patch in Gerrit but the author hasn't been updating it in a while.
http://egit.eclipse.org/r/#change,3790
Comment 9 Remy Suen CLA 2011-12-12 07:45:10 EST
Note that there's a new change set in RFC from Kevin in Gerrit at the moment.
http://egit.eclipse.org/r/#change,4760
Comment 10 Tomasz Zarna CLA 2011-12-12 07:52:24 EST
Keeping my fingers crossed.
Comment 11 Kevin Sawicki CLA 2012-02-27 19:05:29 EST
Stash apply support has just been pushed for review: https://git.eclipse.org/r/#/c/5173/
Comment 12 Chris Aniszczyk CLA 2012-02-28 17:02:02 EST
These commands are now in master:

* StashApplyCommand
* StashCreateCommand
* StashListCommand
Comment 13 Chris Aniszczyk CLA 2012-02-28 17:02:27 EST
Please open up separate bugs for clear or drop functionality if desired.
Comment 14 Markus Keller CLA 2012-02-29 12:13:30 EST
> Please open up separate bugs for clear or drop functionality if desired.

That's bug 372883.

I also opened bug 372882 and bug 372884 for problems in 2.0.0.201202282014.