guberm / tortoisegit

Automatically exported from code.google.com/p/tortoisegit
0 stars 0 forks source link

Stash selected files from diff window #2498

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Open the Diff window that contains a list of all modified files
2. Select a few of these files
3. Right-click and search for a "Stash save" command
4. Click the "Stash" button and use its "Save" command

What is the expected output? What do you see instead?
I'd like to see the Stash command in the context menu already. Then I found the 
button below, but it stashed all modified files, not just the ones I selected.

I want to hide changes to a few files to commit them later. But I also want to 
see that state to try and build it before the commit.

What version of TortoiseGit and msysgit are you using? On
what operating system?
1.8.14.0 on Windows 7

Please provide any additional information below.

Original issue reported on code.google.com by yves.goe...@gmail.com on 4 May 2015 at 12:32

GoogleCodeExporter commented 9 years ago
There is no direct way to stash a specific file.

A more complex way to stash some files is:
git add file/to/stash
git stash --keep-index
git reset

Original comment by ch3co...@gmail.com on 6 May 2015 at 3:59

GoogleCodeExporter commented 9 years ago
Git does not allow stashing single files - there is not API for that.

Original comment by sstrickr...@googlemail.com on 17 May 2015 at 12:57