Using git -remote-hg on windows

In accordance with this answer, https://stackoverflow.com/a/3124168/ would be quite easy to configure git to work with mercury “no dependencies or anything”.

This is not like what is flattened on a Windows hard drive.

I tried to follow this guide

https://github.com/msysgit/msysgit/wiki/Guide-to-git-remote-hg

After fixing the makeFile to work on my system and building git, I could not call git -remote-hg because it complained that it could not find the python interpreter, all hard-tuned correctly. So I manually called it with

C:/Python27/python.exe git-remote-hg clone C:/TestMercurialRepo

Now this gives me the following error.

Traceback (most recent call last):
  File "git-remote-hg", line 99, in <module>
    sys.exit(HgRemoteHelper().main(sys.argv))
  File "d:\development\msysgit\git\git_remote_helpers\helper.py", line 196, in m
ain
    repo = self.get_repo(alias, url)
  File "git-remote-hg", line 33, in get_repo
    if repo.capable('branchmap'):
  File "c:\Python27\lib\site-packages\mercurial\repoview.py", line 205, in __get
attr__
    return getattr(self._unfilteredrepo, attr)
AttributeError: 'mqrepo' object has no attribute 'capable'

? , , , , .

+5
2

Windows. , msysgit Python, Felipe git -remote-hg.py py2exe . py2exe libexec Git, .

, :

  • Python 2.7
  • Mercurial Python ( Windows )
  • py2exe ( Windows )
  • Felipe git -remote-hg python script ( raw )

setup.py, :

from distutils.core import setup
import py2exe

setup(console=['git-remote-hg.py'])

:

python setup.py py2exe --include mercurial    

py2exe 'dist', . libexec\ git -core Git (, C:\Program Files (x86)\Git).

Mercurial Git.

(: , , , , ).

+8

, , git-remote-hg Mercurial. , , repo capable.

git -remote-hg. Mercurial, , repoview, , capable. , , , , git -remote-hg.

, , git -remote-hg Mercurial Python . , .

, backtrace https://github.com/felipec/git/blob/fc/remote/hg/contrib/remote-helpers/git-remote-hg, .

0

All Articles