Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What i need to take care to upgrade from git 1.9.5 to latest 2.6?

Tags:

git

upgrade

I have been using version 1.x for all my projects.

Is it safe to just upgrade to the latest 2.6?

On workstations i use sourcetreee and git extensions.

All our repositories are stored in a central server which serve as our origin remote.

like image 945
e4rthdog Avatar asked Sep 30 '15 15:09

e4rthdog


1 Answers

Yes, git 2.6 will open your repos initially created with 1.9.x without any issue.
The best practice is to make sure the git version on the server is greater or equal to the one used by the clients, but in practice, I have been using 2.x clients pushing to an 1.9.x server for months without any problem.

Check a few settings that have changed with git 2.0 though:

In Git 2.0 the push.default has been changed to simple which is narrower in scope – more specific and more intuitive – it will now only push:

  • The current branch to the branch with the same name only when the current branch is set to integrate with that remote branch on the same remote;
  • The current branch to the branch with the same name, if you are pushing to a remote that is not where you usually fetch from.

And:

git add path now equates git add -A path

like image 103
VonC Avatar answered Nov 03 '22 09:11

VonC