0

It may be a duplicate, but my server now is ofline and I can found only very fussy answers to this.

So I need to pull commit 164183012b178c2f68891e1bff24e5c9a0c97222. How should I do that?

Gediminas
  • 5,859
  • 6
  • 37
  • 53
  • In git nearly every operation is offline, it seems like you are pretty new to git. I can suggest you the [Git Basics](http://git-scm.com/book/en/v2/Getting-Started-Git-Basics) chapter of the gitpro book. Also the book in general is very helpful to get a good understanding of git. – Sascha Wolf Oct 27 '14 at 10:53

2 Answers2

2

Check out this tutorial: https://www.atlassian.com/en/git/tutorial/undoing-changes#!checkout

I think that you only need a git checkout 164183012b178c2f68891e1bff24e5c9a0c97222

Daniel Rivera
  • 227
  • 2
  • 7
  • I believe it is the right answer, but nothing happens after writing this. Should I write pull comand next or what to get these files? Thank you!! – Gediminas Oct 27 '14 at 09:23
  • Actually I just made a test and the git checkout command restores the state of the workspace. – Daniel Rivera Oct 27 '14 at 09:43
  • oh. You are right - it works! Just added some kind of comment which cunfused me :) Thanks! – Gediminas Oct 27 '14 at 09:57
  • but there is one interesting thing. After using it, and later trying to use again `git pull` to get the newest version - tells to select branch. But `git checkout master` restores it and puts back on track – Gediminas Oct 27 '14 at 10:10
2

Use git cherry-pick.

git cherry-pick 04566389ae36651daf3dfa117a1088d594632370

will pull the specific commit into your current branch.

napolux
  • 13,486
  • 7
  • 48
  • 68