Mercurial > hgsubversion
annotate setup.py @ 469:5567af673f83
Revive svn+http(s) URLs support (issue94)
Telling svn from mercurial repository automatically is not always possible, or
at least not seamlessly. Let 'http://repo.com/svn' be an svn repository,
protected with basic authentication. Trying to clone it directly does something
like:
1- Open it like a mercurial repository:
* send between command, ask for credentials, fail
* fallback to static-http, ask for crendentials two times, fail
2- Open it like an svn repository
Mercurial [auth] facility is helpful here, but few people know about it, and it
may seem weird to store svn credentials in mercurial configuration. An svn-like
password manager would not help either because all connections attempts in [1]
fail and it's unlikely we would store credentials in this situation. Instead,
we can clone 'svn+http://repo.com/svn', which will skip step [1].
author | Patrick Mezard <pmezard@gmail.com> |
---|---|
date | Sat, 18 Jul 2009 20:44:33 -0500 |
parents | 1ad05cffb20f |
children | ac9c9e1a8022 |
rev | line source |
---|---|
308
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
1 #!/usr/bin/env python |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
2 # -*- coding: utf-8 -*- |
320
1ba8ed29148e
Fix package name, use README for long_description
Augie Fackler <durin42@gmail.com>
parents:
318
diff
changeset
|
3 import os |
308
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
4 import sys |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
5 if not hasattr(sys, 'version_info') or sys.version_info < (2, 4, 0, 'final'): |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
6 raise SystemExit("Mercurial requires python 2.4 or later.") |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
7 |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
8 try: |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
9 from distutils.command.build_py import build_py_2to3 as build_py |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
10 except ImportError: |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
11 from distutils.command.build_py import build_py |
353
1ad05cffb20f
setup.py: Use setuptools if available.
Augie Fackler <durin42@gmail.com>
parents:
347
diff
changeset
|
12 try: |
1ad05cffb20f
setup.py: Use setuptools if available.
Augie Fackler <durin42@gmail.com>
parents:
347
diff
changeset
|
13 from setuptools import setup |
1ad05cffb20f
setup.py: Use setuptools if available.
Augie Fackler <durin42@gmail.com>
parents:
347
diff
changeset
|
14 except ImportError: |
1ad05cffb20f
setup.py: Use setuptools if available.
Augie Fackler <durin42@gmail.com>
parents:
347
diff
changeset
|
15 from distutils.core import setup |
308
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
16 |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
17 setup( |
320
1ba8ed29148e
Fix package name, use README for long_description
Augie Fackler <durin42@gmail.com>
parents:
318
diff
changeset
|
18 name = 'hgsubversion', |
308
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
19 version = '0.0.1', |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
20 url = 'http://bitbucket.org/durin42/hgsubversion', |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
21 license = 'GNU GPL', |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
22 author = 'Augie Fackler, others', |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
23 author_email = 'hgsubversion@googlegroups.com', |
318 | 24 description = ('hgsubversion is a Mercurial extension for working with ' |
25 'Subversion repositories.'), | |
320
1ba8ed29148e
Fix package name, use README for long_description
Augie Fackler <durin42@gmail.com>
parents:
318
diff
changeset
|
26 long_description = open(os.path.join(os.path.dirname(__file__), |
1ba8ed29148e
Fix package name, use README for long_description
Augie Fackler <durin42@gmail.com>
parents:
318
diff
changeset
|
27 'README')).read(), |
308
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
28 keywords = 'mercurial', |
347
537de0300510
Remove the 'outgoing' wrapper, and use the Mercurial infrastructure instead.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
337
diff
changeset
|
29 packages = ('hgsubversion', 'hgsubversion.svnwrap'), |
308
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
30 platforms = 'any', |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
31 classifiers = [ |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
32 'License :: OSI Approved :: GNU General Public License (GPL)', |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
33 'Intended Audience :: Developers', |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
34 'Topic :: Software Development :: Version Control', |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
35 'Development Status :: 2 - Pre-Alpha', |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
36 'Programming Language :: Python', |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
37 'Operating System :: OS Independent', |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
38 ], |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
39 cmdclass = {'build_py': build_py}, |
41aa4c3f789e
A quick stab at a distutils installation script.
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents:
diff
changeset
|
40 ) |