Commits with no files are not shown in hg

Create issue
Issue #202 wontfix
Denilson Sá created an issue

Although the title seems a bit weird, I'll show how to reproduce it, and why it makes sense:

Create a new SVN repository.

Make some empty dirs inside this repository.

Commit these new directories. Now the subversion repository has a few directories. In other words, if you do a checkout, those directories will be created in your local copy.

If you clone this svn repo using hgsubversion, no changesets will be imported and no directories will be created. You can notice that these "empty" changesets won't be imported because "hg pull" will get those empty again, but they won't be imported.

Another bug very close to this one is that empty dirs are not created:

Create a new file inside a subdirectory. Commit it to the svn.

Pull these changes using hgsubversion. This new file is shown inside that directory.

Delete that file, but keep the directory. Commit the file deletion using svn. Note that SVN still keeps the empty directory.

Pull this change using hgsubversion. Notice that the file has been removed, as well as the empty directory.

Comments (5)

  1. Dan Villiom Podlaski Christiansen

    I don't think this is a bug in hgsubversion, as Mercurial just doesn't track directories. Although some see this as a bug, and others see it as a feature, it was a design choic Matt Mackall made when he originally wrote Mercurial. As an extension to Mercurial, hgsubversion can only work with Mercurial provides it, and this does not include directory tracking.

    There's no way to create an ‘empty’ directory using Mercurial; the only workaround is to add a file to the directory. Some people might want hgsubversion do that, but that doesn't appear to be what you're requesting. As a result, I'm marking this bug as ‘wontfix’: it would be impossible for us to fix within the confines of a Mercurial extension.

  2. Denilson Sá reporter

    Makes sense to mark as wontfix, as it's not a bug in hgsubversion. I would just ask to add it somewhere in the documentation (FAQ, known issues, or something like that)

  3. Log in to comment