0 votes
in Git by
How will you distinguish between Git and SVN?

1 Answer

0 votes
by

Git is a distributed version control whereas SVN is centralized. This leads to many differences between the two in terms of their features and functionalities.

  Git SVN

Server Architecture The computer on which your Git has installed acts as both client and server. Each developer has a local copy of the complete version history of the project on their individual computers. Git changes occur locally. 

Hence, the developer is not required to be connected to the network at all times. Only for push and pull operations, developers would need internet connection to connect to remote server. SVN has a separate client and server. It is not locally available. You will be required to be connected to the network to perform any action.

Also, in SVN, since everything is centralized, so in case the central server gets crashed or corrupted, it will result in entire data loss for the project.

Branching Git is mostly preferred by developers due to its effective branching model. Git branches are lightweight but powerful. 

They are only references to a particular commit. You can create, delete or modify a branch anytime with no impact on other commits. So, fork, branch and merge are easy with Git. SVN has a complicated branching and merging model and its time-consuming to manage. 

In SVN, branches are generated as directories within the repository. This directory structure is mainly problematic. When the branch is ready, you need to commit back to the trunk. Since you are not the only one who is merging the changes, so the version of the truck may not be regarded as developers’ branches. This can lead to conflicts, missing files and jumbled changes in your branch.

Access Control Git presumes that all the contributors will be having the same permissions. SVN permits you to define read/write access controls at each and directory level.

Auditability In Git, the changes are tracked at the repository level. Git does not bother too much about maintaining the precise history of changes made in your repository. 

The distributed nature of Git lets any collaborator change any part of their local repo’s history. With Git, it’s difficult to figure a true history of changes in your codebase.

For example, you will lose history after rename in Git. In SVN, the changes are tracked at the file level. 

SVN maintains a pretty consistent and precise change history. You can recover exactly the same data as it was at any instant in the past. 

SVN history is permanent and always definite.

Storage Requirements Git and SVN store the data in the same manner. The disk space usage is equal for both of them. The only difference comes into picture in case of binary files. Git is not friendly to binary files. 

It can’t handle the storage of large binary files. SVN has an xDelta compression algorithm that works for both binary and text files. 

So, SVN can handle storing large binary files in comparatively lesser space than Git.

Usability Both Git and SVN use command line as primary UI. 

Git is largely used by developers/technical users. SVN is largely used by non-technical users as it's easier to learn.

Content Cryptographic SHA-1 Hash. No hashed content.

Global Revision Number Not available Available

Related questions

0 votes
asked Dec 18, 2020 in SVN by SakshiSharma
0 votes
0 votes
asked May 21, 2020 in Git by SakshiSharma
...