News for hackers. Stuff that matters.
Re:Why Git sucks? by thrush on Saturday August 02, 2014 @07:42PM (#8126451)
Some people like git pull, but I prefer git fetch. This gets all's the history from the remote repo without applying any changes. Then you can run something like 'git rebase -i origin/master' which is where I think git can really shine.

There is an excellent link out there that explains git in layman's terms. I think it's called git for hackers or something of the sort. It's much easier than the docs in my opinion.

Re:Why Git sucks? by SDGT on Saturday August 02, 2014 @07:49PM (#8126471)
Best practices are to not use pull unless you certainly know you should.

Things should be fetched then merged with two separate commands.

Re:Why Git sucks? by gizmo686 on Saturday August 02, 2014 @08:27PM (#8126574)
Pulling is equivelent to doing a fetch then a merge. Unless you plan on doing something between the two steps (like inspecting FETCH_HEAD yourself), then there is no advantage to not simply pulling.

Of course, if (like thrush) you do not plan on doing a merge, then you will need to do the fetch manually and do what you do want to do. Although, git pull does have a --rebase option, but I am not sure if you can pass the -i flag to it.

Having taught people how to use git, I found that it is easier to not show them the pull command until they are used to doing fetch && merge.

Re:Why Git sucks? by mitchty on Saturday August 02, 2014 @08:25PM (#8126568)
Can just git pull --rebase too instead of fetch/rebase.