Git is a version control system for tracking changes in computer files and coordinating work on those, files among multiple people.
It is primarily used for source code management in software development, but it can be used to keep track of changes in any set of files.
As a distributed revision control system it is aimed at speed, data integrity and support for distributed non-linear workflows.
The most widely used modern version control system in the world today is Git.
Git is a mature, actively maintained open source project originally developed in 2005 by Linus Torvald.
Git is an example of a Distributed Version Control System, In Git, every developer's working copy of the code is also a repository that can contain the full history of all changes.
Advantages -
- Ease to use.
- Data redundancy and replication.
- High availability.
- Superior disk utilization and network performance.
- Only one .git directory per repository.
- Collaboration friendly.
- Any kind of projects from large to small scale can use GIT.
Repository -
The purpose of Git is to manage a project or set of files, as they change over time. Git stores this information in a data structure called a repository. A git repository contains,
A set of commit objects.
A set of references to commit objects called heads.
The Git repository is stored in the same directory as the project itself in a subdirectory called .git.
Note - difference from central repository systems like CVS or Subversion:
There is only one .git directory, in the root directory of the project. The repository is stored in files alongside the project. There is no central server repository.
Difference between GIT and SVN -
Git is less preferred for handling extremely large files or frequently changing binary files while SVN can handle multiple projects stored in the same repository.
Git does not support 'commits' across multiple branches or tags. Subversion allows the creation of folders at any location in the repository layout.
Git are unchangeable, while Subversion allows committers to treat a tag as a branch and to create multiple revisions under a tag root.
Staging Area -
Staging is a step before the commit process in git. That is, a commit in git is performed in two steps.
-Staging and
-Actual commit
As long as a change set is in the staging area, git allows we to edit it as we like.
No comments:
Post a Comment
Note: only a member of this blog may post a comment.