Coder Social home page Coder Social logo

no checks in ident string about fast-export HOT 6 CLOSED

frej avatar frej commented on July 22, 2024
no checks in ident string

from fast-export.

Comments (6)

ewongbb avatar ewongbb commented on July 22, 2024

my current 'fix'/hack is:
diff --git a/hg-fast-export.py b/hg-fast-export.py
index 0c683c5..2f1c90b 100755
--- a/hg-fast-export.py
+++ b/hg-fast-export.py
@@ -184,6 +184,8 @@ def export_commit(ui,repo,revision,old_marks,max,count,authors,sob,brmap,hgtags,
wr('mark :%d' % (revision+1))
if sob:
wr('author %s %d %s' % (get_author(desc,user,authors),time,timezone))

  • if '<<' in user:
  • user.replace('<<', '<')
    wr('committer %s %d %s' % (user,time,timezone))
    wr('data %d' % (len(desc)+1)) # wtf?
    wr(desc)

of course, with the different possible ways to break that, it'd have to be a bit better at
checking the ident syntax, et. al. (but right now it fixes my issue)

from fast-export.

ewongbb avatar ewongbb commented on July 22, 2024

nvm.. the fix didn't work.

Should've been |user = user.replace('<<', '<')

from fast-export.

frej avatar frej commented on July 22, 2024

What you want to use is the author map (-A) option (Look in the
README).

Fast-export is not in the business of doing cute transformations in
order to try to guess the correct author string. The policy is to keep
things simple. If you have too many malformed identities to deal with
them manually, write an external tool which produces the author map.

from fast-export.

frej avatar frej commented on July 22, 2024

Won't fix

from fast-export.

c4lliope avatar c4lliope commented on July 22, 2024

Picking up this long-dead thread,
I had a similar issue parsing Mozilla's source;
a couple <<address@place> cases and similar.

I am mirroring this code base, and in this code base I made a couple changes;
see the change log.

Open an issue here should you experience similar issues,
and link the code base you need help on.

from fast-export.

c4lliope avatar c4lliope commented on July 22, 2024

Once I searched around, I realized https://github.com/glandium/git-cinnabar handles these cases nicely,
and is a really speedy program.

I'm mirroring the code here.

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.