Version control is a way to keep a track of the changes in the code so that if something goes wrong, we can make comparisons in different code versions and revert to any previous version that we want.
One of the most used tools is Git, which has amongst other, the next features:
- Provides strong support for non-linear development.
- Distributed repository model.
- Compatible with existing systems and protocols like HTTP, FTP, ssh.
- Capable of efficiently handling small to large sized projects.
- Cryptographic authentication of history.
- Pluggable merge strategies.
- Toolkit-based design.
- Periodic explicit object packing.
- Garbage accumulates until collected.
As every tool, Git has some Pros and some Cons, let’s review them:
- Super-fast and efficient performance.
- Code changes can be very easily and clearly tracked.
- Easily maintainable and robust.
- Offers an amazing command line utility known as git bash.
- Also offers GIT GUI where you can very quickly re-scan, state change, sign off, commit & push the code quickly with just a few clicks.
- Complex and bigger history log become difficult to understand.
- Does not support keyword expansion and timestamp preservation.
Now let’s see what about CVS:
- Client-server repository model.
- Multiple developers might work on the same project parallelly.
- CVS client will keep the working copy of the file up-to-date and requires manual intervention only when an edit conflict occurs
- Keeps a historical snapshot of the project.
- Anonymous read access.
- ‘Update’ command to keep local copies up to date.
- Can uphold different branches of a project.
- Excludes symbolic links to avoid a security risk.
- Uses delta compression technique for efficient storage.
- Excellent cross-platform support.
- Robust and fully-featured command-line client permits powerful scripting
- Helpful support from vast CVS community
- allows good web browsing of the source code repository
- It’s a very old, well known & understood tool.
- Suits the collaborative nature of the open-source world splendidly.
- No integrity checking for source code repository.
- Does not support atomic check-outs and commits.
- Poor support for distributed source control.
- Does not support signed revisions and merge tracking.
SVN is yet another tool for Version Control:
- Client-server repository model. However, SVK permits SVN to have distributed branches.
- Directories are versioned.
- Copying, deleting, moving and renaming operations are also versioned.
- Supports atomic commits.
- Versioned symbolic links.
- Free-form versioned metadata.
- Space efficient binary diff storage.
- Branching is not dependent upon the file size and this is a cheap operation.
- Other features – merge tracking, full MIME support, path-based authorization, file locking, standalone server operation.
- Has a benefit of good GUI tools like TortoiseSVN.
- Supports empty directories.
- Have better windows support as compared to Git.
- Easy to set up and administer.
- Integrates well with Windows, leading IDE and Agile tools.
- Does not store the modification time of files.
- Does not deal well with filename normalization.
- Does not support signed revisions.
Finally, why should we use one of these? Well, it allows you to revert selected files back to a previous state, revert the entire project back to a previous state, compare changes over time, see who last modified something that might be causing a problem, who introduced an issue and when, and more. Using a VCS also generally means that if you screw things up or lose files, you can easily recover. In addition, you get all this for very little overhead.
Git – About Version Control. (n.d.). Git. https://git-scm.com/book/en/v2/Getting-Started-About-Version-Control
Top 5 BEST Version Control Software (Source Code Management Tools). (2020, November 13). Software Testing Help. https://www.softwaretestinghelp.com/version-control-software/