Git - open source code;) (or google)
In any case, stashes is a list of commits. You can see how they are created by creating a cover:
# git stash --keep-index # git stash list stash@ {0}: WIP on master: dafe337 sss # git log ' stash@ {0}' | cat commit 7f86a90fb4e57590d6fe5026b7408306a757132a Merge: dafe337 2881ede Author: Maciej Piechotka < uzytkownik2@gmail.com > Date: Fri Aug 30 09:27:10 2013 +0200 WIP on master: dafe337 sss commit 2881ede55d619570a82bb7312257c4e43bd3b334 Author: Maciej Piechotka < uzytkownik2@gmail.com > Date: Fri Aug 30 09:27:10 2013 +0200 index on master: dafe337 sss commit dafe33716c2e5aee994612c88d8142f1163c624e Author: Maciej Piechotka < uzytkownik2@gmail.com > Date: Fri Aug 30 09:25:40 2013 +0200 sss
Sss is the first commit (HEAD), while the other two commits are the preservation of the current index (incremental changes), and the merge contains unspecified changes:
% git show 2881ede55d619570a82bb7312257c4e43bd3b334 commit 2881ede55d619570a82bb7312257c4e43bd3b334 Author: Maciej Piechotka < uzytkownik2@gmail.com > Date: Fri Aug 30 09:27:10 2013 +0200 index on master: dafe337 sss diff
Now the bookmark list is an existing structure - reflog (nb is a useful structure in itself ), and the name is ... stash. Thus, stashes are implemented de facto as a branch with a moving head, and we are interested in reflog. To make it more interesting, I created a second cache that created commit 0dee308c461955e13a864c9a904a69d611e82730 .
% git reflog stash | cat 7f86a90 stash@ {0}: WIP on master: dafe337 sss % cat .git/refs/stash 0dee308c461955e13a864c9a904a69d611e82730 % cat .git/logs/refs/stash 0000000000000000000000000000000000000000 7f86a90fb4e57590d6fe5026b7408306a757132a Maciej Piechotka < uzytkownik2@gmail.com > 1377847630 +0200 WIP on master: dafe337 sss 7f86a90fb4e57590d6fe5026b7408306a757132a 0dee308c461955e13a864c9a904a69d611e82730 Maciej Piechotka < uzytkownik2@gmail.com > 1377847983 +0200 WIP on master: dafe337 sss
source share