Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4614940
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T01:46:11+00:00 2026-05-22T01:46:11+00:00

From Mercurial wiki – GSoC Ideas 2010 : Project Ideas Lightweight copies/renames (very difficult

  • 0

From Mercurial wiki – GSoC Ideas 2010:

Project Ideas

Lightweight copies/renames

(very difficult – a successful student
will become an expert in Mercurial’s
storage format and transmission
protocol)

Copies and renames currently are not
too efficient. Mercurial copies the
copied/renamed source file to the new
initial revision of the target file in
its internal history store. For
renames, this is especially
counter-intuitive, as renaming a large
file grows the store by the file’s
size. It would be better if Mercurial
had some way of referring to the
existing revision from the new file,
while preserving backwards
compatbility and bounded I/O
guarantees for retrieving revisions.
See issue883 for discussion.
There’s an mq from an old attempt at
this located here.

Sorry if this is an obvious question (I’m not good at English and programming). I’m wondering, what does the "Lightweight copies" mean?

Is it mean: when this feature is implemented, multiple files with same content (same hash value different file names) will be stored only once in repository (just like Git)?


Update:

Thanks everyone for your answers. One of Mercurial’s developers – tonfa also answered this question in a comment of this answer:

caveman: When light-weight copies are
implemented, will two files with same
content (same hash value different
names) store only once in repository
(just like Git)?

tonfa: no, this feature isn’t planned
(it would break other optimizations to
minimize disk access)

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T01:46:11+00:00Added an answer on May 22, 2026 at 1:46 am

    Right now, when you copy a file, a new file is created in the repository that contains a compressed snapshot of the file you just copied. The idea would be to set it up so the copy references the old file somehow and then has revlog entries based on that instead of having to have its own snapshot to base the revlog entries off of.

    This will not be like how git works. Changing Mercurial to work that way would be really interesting, and not the easiest proposition.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using Hudson to build my project from my Mercurial repository. There are two
When changing the VCS for my project FakeItEasy from SVN to Mercurial on Google
My company is switching from Subversion to Mercurial. We're using .NET for our product.
I have just switched from svn to mercurial and have read some tutorials about
I'm having difficulty figuring out how to clone my Mercurial repository from my local
I have a question about TortoiseHg. My organization is transitioning from SVN to Mercurial.
Is there a way in mercurial to remove old changesets from a database? I
It is my understanding that although Mercurial has support from branches, the community generally
I have pulled an incoming changes from a codeplex-based mercurial repository and have arrived
I've forked a Mercurial repository, and now I want to pull the changes from

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.