/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 __init__.py

Special-case NULL_REVISION when looking for Git shas.

Show diffs side-by-side

added added

removed removed

Lines of Context:
114
114
 
115
115
    colocated_branches = True
116
116
 
 
117
    def __eq__(self, other):
 
118
        return type(self) == type(other)
 
119
 
117
120
    def is_supported(self):
118
121
        return True
119
122
 
133
136
 
134
137
        """
135
138
        lazy_check_versions()
136
 
        # we dont grok readonly - git isn't integrated with transport.
137
 
        from bzrlib.transport.local import LocalTransport
138
 
        if isinstance(transport, LocalTransport):
139
 
            import dulwich
140
 
            path = transport.local_abspath(".").encode(osutils._fs_enc)
141
 
            gitrepo = dulwich.repo.Repo(path)
142
 
        else:
143
 
            from bzrlib.plugins.git.transportgit import TransportRepo
144
 
            gitrepo = TransportRepo(transport)
 
139
        from bzrlib.plugins.git.transportgit import TransportRepo
 
140
        gitrepo = TransportRepo(transport)
145
141
        from bzrlib.plugins.git.dir import LocalGitDir, GitLockableFiles, GitLock
146
142
        lockfiles = GitLockableFiles(transport, GitLock())
147
143
        return LocalGitDir(transport, lockfiles, gitrepo, self)