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

  • Committer: Aaron Bentley
  • Date: 2007-03-03 17:17:53 UTC
  • mfrom: (2309 +trunk)
  • mto: This revision was merged to the branch mainline in revision 2316.
  • Revision ID: aaron.bentley@utoronto.ca-20070303171753-o0s1yrxx5sn12p2k
Merge bzr.dev

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2005, 2006 Canonical Ltd
 
1
# Copyright (C) 2005, 2006, 2007 Canonical Ltd
2
2
#
3
3
# This program is free software; you can redistribute it and/or modify
4
4
# it under the terms of the GNU General Public License as published by
93
93
    intended to be used when the implementation depends on an external
94
94
    implementation that may not be present.  If any other error is raised, it
95
95
    propagates up and the attempt to open the url fails.
 
96
 
 
97
    :param scheme: The url scheme part, eg "ftp://"
96
98
    """
97
99
    # TODO: If no implementation of a protocol is available because of missing
98
100
    # dependencies, we should perhaps show the message about what dependency
1004
1006
 
1005
1007
    base is either a URL or a directory name.  
1006
1008
    """
1007
 
    # TODO: give a better error if base looks like a url but there's no
1008
 
    # handler for the scheme?
1009
1009
    global _protocol_handlers
1010
1010
    if base is None:
1011
1011
        base = '.'
1012
 
 
1013
1012
    last_err = None
1014
1013
 
1015
1014
    def convert_path_to_url(base, error_str):
1183
1182
register_lazy_transport('ftp://', 'bzrlib.transport.ftp', 'FtpTransport')
1184
1183
register_lazy_transport('aftp://', 'bzrlib.transport.ftp', 'FtpTransport')
1185
1184
register_lazy_transport('memory://', 'bzrlib.transport.memory', 'MemoryTransport')
 
1185
register_lazy_transport('chroot+', 'bzrlib.transport.chroot',
 
1186
                        'ChrootTransportDecorator')
1186
1187
register_lazy_transport('readonly+', 'bzrlib.transport.readonly', 'ReadonlyTransportDecorator')
1187
1188
register_lazy_transport('fakenfs+', 'bzrlib.transport.fakenfs', 'FakeNFSTransportDecorator')
1188
1189
register_lazy_transport('vfat+',
1191
1192
register_lazy_transport('bzr://',
1192
1193
                        'bzrlib.transport.smart',
1193
1194
                        'SmartTCPTransport')
 
1195
register_lazy_transport('bzr+http://',
 
1196
                        'bzrlib.transport.smart',
 
1197
                        'SmartHTTPTransport')
1194
1198
register_lazy_transport('bzr+ssh://',
1195
1199
                        'bzrlib.transport.smart',
1196
1200
                        'SmartSSHTransport')