You can check git reflog
for log of commits. By searching through the list of commits you should be able to pick those which you need and simply cherry-pick them.
For example your reflog will look like this
user$ git reflog
c9f9669 HEAD@{0}: commit: Fixed test cases to run on Unix
b3ca8a4 HEAD@{1}: pull: Fast-forward
54ba188 HEAD@{2}: pull origin master: Fast-forward
e659a21 HEAD@{3}: reset: moving to HEAD~1
12944d8 HEAD@{4}: reset: moving to HEAD~1
6f40152 HEAD@{5}: reset: moving to HEAD~1
3de61ba HEAD@{6}: pull: Fast-forward
e659a21 HEAD@{7}: reset: moving to HEAD^1
12944d8 HEAD@{8}: reset: moving to HEAD^1
6f40152 HEAD@{9}: reset: moving to HEAD^1
3de61ba HEAD@{10}: commit: Removed Query object
6f40152 HEAD@{11}: pull: Merge made by the 'recursive' strategy.
12944d8 HEAD@{12}: commit: API touchups
e659a21 HEAD@{13}: commit: Test enhancements
07419e1 HEAD@{14}: pull: Fast-forward
The commits that you're looking for are ones with hash 3de61ba
and 12944d8
git cherry-pick 3de61ba
git cherry-pick 12944d8
It should be pretty simmilar to what you need.
More info on how the reflog
works and how to use it you can find in the official Git documentation