Over a million developers have joined DZone.

Git Forgoes Backward Compatibility to get New Features

DZone 's Guide to

Git Forgoes Backward Compatibility to get New Features

· Java Zone ·
Free Resource
The makers of the free DVCS (Distributed Version Control System), Git, have recently made the new 1.7 version available for download.  Many changes in the new version however, make Git 1.7 incompatible with Git 1.6.6.  The Git developers have been preparing the Git community for these compatibility issues since before the release of 1.6.6, saying that the changes were important enough to break the backward compatibility with previous releases.  The repository format however, remains the same.  

The Git team says that the problematic behaviors in previous versions made it worthwhile to break the backward compatibility instead of keeping them for compatibility's sake.  They say that many users were shocked and unprepared when version 1.6 switched from "git-foo" to "git foo" even though the transition guide had been available for a long time before the release.  Recent versions of Git include popup warnings to let users know that the feature they are using will change in the next version.  "We are trying to avoid repeating that unpleasantness [from Git 1.6] in the 1.7.0 release," said they said.

In Git 1.7, major changes include:

  • A development branch that has been checked out will refuse the "git push" command by default.  
  • Using "git push $there :$killed" to delete the "$killed" branch in a remote repository will be refused by default if HEAD points to it.  
  • "git status" is not "git commit --dry-run" anymore, but this will not affect users if they run the command without argument.  
  • external diff and textconf helpers are now able to be executed with the shell like several other Git programs.
  • Any help path that includes spaces or other meta characters must be shell quote.
  • "ignore whitespaces" now affects the semantics of the diff operation and a change that only affects whitespaces is reported with zero exit status when run with --exit-code (there is no "diff --git" header for such a change).

Git users can store up to 300MB of their projects at GitHub for free.  Open source projects such as GNOME, Ruby on Rails, Android, and Samba, use Git to manage their code.

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}