/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to mapping.py

  • Committer: John Carr
  • Date: 2008-12-30 22:10:38 UTC
  • mto: (0.217.35 git-serve)
  • mto: This revision was merged to the branch mainline in revision 6960.
  • Revision ID: john.carr@unrouted.co.uk-20081230221038-wkjk7e99ro3cpo18
Don't bother using InterRepo, use import_git_objects directly. Don't need a full repository (just operating on a pack and index)

Show diffs side-by-side

added added

removed removed

Lines of Context:
17
17
"""Converters, etc for going between Bazaar and Git ids."""
18
18
 
19
19
from bzrlib import errors, foreign
 
20
from bzrlib.inventory import ROOT_ID
20
21
from bzrlib.foreign import (
21
22
        ForeignRevision,
22
23
        )
48
49
        return { "git commit": foreign_revid }
49
50
 
50
51
    def generate_file_id(self, path):
 
52
        if path == "":
 
53
            return ROOT_ID
51
54
        return escape_file_id(path.encode('utf-8'))
52
55
 
53
56
    def import_commit(self, commit):