Why migrating the code from centralized version to distributed version system??

Babli Sahu
2 min readMar 9, 2021

Somewhere around 1600 modules have to be migrated from CVS(Centralized version control systems) to GIT( distributed version system)……why are they doing so????

In simpler words-the engineering of git is far superior…

  1. In case of bigger teams , distributed system works better. You can run git in a centralized fashion (e.g. GitHub, Git Lab, Bit Bucket), but you don’t have to. In CVS, you’ve got to run with a centralized server otherwise you can’t share the repository at all.
  2. It is easy to create branches on GIT.
  3. GIT UI gives more clear picture of the repos. Git repository contents are essentially immutable, once a version of a file is written, there is no dispute about what the contents of that version of the file are On the other hand you don’t have anything like guarantee with a CVS repository file — a software bug or a malicious actor can corrupt a CVS repository file and you will be none the wiser.
  4. We have Rest API implementation in GIT.
  5. GIT is easy to reconcile.
  6. In GIT code merges between the branches.
  7. CVS works on a file level while GIT works on a repo/module level.

Now the thing is, how to do the conversion?

There are two ways to do the conversion:-

  1. Git provides git cvsimport [options] [options], you can find it on git documentation.
  2. Cvs2git is a tool that is a mostly in used.

-Both of these tools are used to convert any type of Centralized VS(CVS,SVN) to Distributed version control system (GIT)(HG).

STEPS FOR CONVERSION:-

  1. cvs2git\ — blobfile=cvs2svn-tmp/git-blob.dat\ — dumpfile=cvs2svn-tmp/git-dump.dat\ — username=cvs2git \ /path/to/cvs/repo
  2. mkdir myproject.git
  3. cd myproject.git
  4. git init — bare
  5. cat ../cvs2svn-tmp/git-blob.dat../cvs2svn-tmp/git-dump.dat | git fast-import

-

--

--