Need advice about which tool to choose?Ask the StackShare community!

Mercurial

229
216
+ 1
105
SVN (Subversion)

796
623
+ 1
43
Add tool

Mercurial vs SVN (Subversion): What are the differences?

Introduction

Mercurial and SVN (Subversion) are both version control systems that help developers track and manage changes to their code. While they serve the same purpose, there are key differences between the two.

  1. Centralized vs Distributed: The main difference between Mercurial and SVN lies in their architecture. SVN follows a centralized model, where there is a central repository that stores the code history and acts as a single point of truth. In contrast, Mercurial is a distributed version control system, where each developer has their own local copy of the code repository, including its history. This allows for greater flexibility and enables offline work in Mercurial.

  2. Branching and Merging: When it comes to branching and merging, Mercurial offers a more streamlined and efficient workflow compared to SVN. Mercurial encourages the use of lightweight and isolated branches, making it easier to create, manage, and merge branches. SVN, on the other hand, uses a copy-modify-merge approach, which can lead to more complex and time-consuming merge conflicts.

  3. Performance: Mercurial is known for its speed and performance, especially for common operations such as cloning and updating repositories. The internal design of Mercurial is optimized for efficiency, resulting in faster operations even with larger codebases. SVN, while still efficient, may experience slower performance for certain operations, especially when the codebase grows significantly.

  4. Integrity and Safety: Both Mercurial and SVN ensure the integrity and safety of code changes. However, Mercurial employs a strict immutability model, where once a changeset is committed, it cannot be modified or deleted. This guarantees the integrity and traceability of the codebase over time. SVN, on the other hand, allows for slightly more flexibility in modifying and deleting committed changes, which may be desirable in certain scenarios but can also introduce risks.

  5. Ease of Use: Mercurial aims to provide a user-friendly and intuitive interface, making it easier for developers to learn and use. The commands and workflows in Mercurial are designed to be natural and consistent, reducing the learning curve for new users. SVN, while still straightforward, may require some additional learning for newcomers due to its slightly different command structure and workflows.

  6. Community and Ecosystem: Both Mercurial and SVN have active communities, but SVN has a larger user base and ecosystem. This means there are more resources, plugins, and tools available for SVN, making it easier to find support and extend its functionality. Mercurial, although having a smaller community, still offers a robust set of features and extensions, but the overall ecosystem may be more limited compared to SVN.

In summary, Mercurial and SVN differ in their architecture (centralized vs distributed), branching and merging workflows, performance, integrity and safety approaches, ease of use, and community/ecosystem size.

Decisions about Mercurial and SVN (Subversion)
Kamaldeep Singh

SVN is much simpler than git for the simple stuff (checking in files and updating them when everyone's online), and much more complex than git for the complicated stuff (branching and merging). Or put another way, git's learning curve is steep up front, and then increases moderately as you do weird things; SVN's learning curve is very shallow up front and then increases rapidly.

If you're storing large files, if you're not branching, if you're not storing source code, and if your team is happy with SVN and the workflow you have, I'd say you should stay on SVN.

If you're writing source code with a relatively modern development practice (developers doing local builds and tests, pre-commit code reviews, preferably automated testing, preferably some amount of open-source code), you should move to git for two reasons: first, this style of working inherently requires frequent branching and merging, and second, your ability to interact with outside projects is easier if you're all comfortable with git instead of snapshotting the outside project into SVN.

See more
Get Advice from developers at your company using StackShare Enterprise. Sign up for StackShare Enterprise.
Learn More
Pros of Mercurial
Pros of SVN (Subversion)
  • 18
    A lot easier to extend than git
  • 17
    Easy-to-grasp system with nice tools
  • 13
    Works on windows natively without cygwin nonsense
  • 11
    Written in python
  • 9
    Free
  • 8
    Fast
  • 6
    Better than Git
  • 6
    Best GUI
  • 4
    Better than svn
  • 2
    Hg inc
  • 2
    Good user experience
  • 2
    TortoiseHg - Unified free gui for all platforms
  • 2
    Consistent UI
  • 2
    Easy-to-use
  • 2
    Native support to all platforms
  • 1
    Free to use
  • 20
    Easy to use
  • 13
    Simple code versioning
  • 5
    User/Access Management
  • 3
    Complicated code versionioning by Subversion
  • 2
    Free

Sign up to add or upvote prosMake informed product decisions

Cons of Mercurial
Cons of SVN (Subversion)
  • 0
    Track single upstream only
  • 0
    Does not distinguish between local and remote head
  • 7
    Branching and tagging use tons of disk space

Sign up to add or upvote consMake informed product decisions

- No public GitHub repository available -

What is Mercurial?

Mercurial is dedicated to speed and efficiency with a sane user interface. It is written in Python. Mercurial's implementation and data structures are designed to be fast. You can generate diffs between revisions, or jump back in time within seconds.

What is SVN (Subversion)?

Subversion exists to be universally recognized and adopted as an open-source, centralized version control system characterized by its reliability as a safe haven for valuable data; the simplicity of its model and usage; and its ability to support the needs of a wide variety of users and projects, from individuals to large-scale enterprise operations.

Need advice about which tool to choose?Ask the StackShare community!

What companies use Mercurial?
What companies use SVN (Subversion)?
See which teams inside your own company are using Mercurial or SVN (Subversion).
Sign up for StackShare EnterpriseLearn More

Sign up to get full access to all the companiesMake informed product decisions

What tools integrate with Mercurial?
What tools integrate with SVN (Subversion)?

Sign up to get full access to all the tool integrationsMake informed product decisions

Blog Posts

Mar 4 2020 at 5:14PM

Atlassian

GitBitbucketWindows+4
3
1071
What are some alternatives to Mercurial and SVN (Subversion)?
Apache Storm
Apache Storm is a free and open source distributed realtime computation system. Storm makes it easy to reliably process unbounded streams of data, doing for realtime processing what Hadoop did for batch processing. Storm has many use cases: realtime analytics, online machine learning, continuous computation, distributed RPC, ETL, and more. Storm is fast: a benchmark clocked it at over a million tuples processed per second per node. It is scalable, fault-tolerant, guarantees your data will be processed, and is easy to set up and operate.
Git
Git is a free and open source distributed version control system designed to handle everything from small to very large projects with speed and efficiency.
JavaScript
JavaScript is most known as the scripting language for Web pages, but used in many non-browser environments as well such as node.js or Apache CouchDB. It is a prototype-based, multi-paradigm scripting language that is dynamic,and supports object-oriented, imperative, and functional programming styles.
GitHub
GitHub is the best place to share code with friends, co-workers, classmates, and complete strangers. Over three million people use GitHub to build amazing things together.
Python
Python is a general purpose programming language created by Guido Van Rossum. Python is most praised for its elegant syntax and readable code, if you are just beginning your programming career python suits you best.
See all alternatives