Coder Social home page Coder Social logo

git checkout HEAD ERROR about fast-export HOT 4 CLOSED

Jayllyz avatar Jayllyz commented on August 24, 2024
git checkout HEAD ERROR

from fast-export.

Comments (4)

frej avatar frej commented on August 24, 2024

[This is a canned reply to issues that contain too little information for effective troubleshooting]

Please have a look at this blog post about writing effective bug reports. For fast-export you should at least:

  • Check that your issue is not already covered by an existing issue. If your issue is similar, but not identical to an existing issue, provide a reference.

  • Report the version of the fast-export you are running, tag and/or hash.

  • Check if your problem is solved by using the latest released hg-fast-export.

  • Check that your installed versions of Python and Mercurial meet the minimum requirements as specified in the README.

  • Explain what you are trying to do, how you are doing it and in what environment. This includes relevant parts of the used mapping files.

  • If your source repository is publicly available, give the URL.

  • If hg-fast-export gives an error message and a backtrace, include that in the issue. Also include the relevant parts of the crash report created by git fast-import.

from fast-export.

Jayllyz avatar Jayllyz commented on August 24, 2024

Hello, thanks for helping me.

I've a lot of repos to convert to git from mercurial, so I made a little script that do like suggested in your repository for all my repos (30~):

git init <repo>
cd <repo>
hg-fast-export.sh -r <repo> -a authors-git
git checkout #also tried HEAD

For all repos it works, expect one, the main repo so he is very huge, maybe it's the reason?

I've provided the error in my initial ticket, using latest python & mercurial (pip install mercurial).
Sadly I can't share anything since it's private.

ps: issue template could be useful for bug reports.

from fast-export.

frej avatar frej commented on August 24, 2024
git init <repo>
cd <repo>
hg-fast-export.sh -r <repo> -a authors-git
git checkout #also tried HEAD

Thanks for the clarification.

git init creates a repo and, by default, places you are on the master branch. If fast-export doesn't create a branch named master, Git will probably be unhappy, for illustration see the following:

$ git init foo
$ cd foo
$ git checkout HEAD
error: pathspec 'HEAD' did not match any file(s) known to git
$ git checkout master
error: pathspec 'master' did not match any file(s) known to git
$ git checkout 
fatal: You are on a branch yet to be born

From the README's section about tag and branch naming: "By default, the default mercurial branch is renamed to the master branch on git. If your Mercurial repo contains both default and master branches, you'll need to override this behavior." My guess is that the Mercurial repo for which git checkout fails when converted, did not have branch named master nor a branch named default. Try git branch --all and check out one of the branches that do exist.

I've provided the error in my initial ticket, using latest python & mercurial (pip install mercurial).

You posted a single error message, followed by a screen shot of the statistics produced by git fast-import, with no indication to the sequence of commands which produced that output. Instead of guessing, I prefer to ask for clarification.

from fast-export.

Jayllyz avatar Jayllyz commented on August 24, 2024

Thanks!

from fast-export.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.