Mercurial > hg
annotate setup.py @ 405:99470ae6b424
Check if repository exists
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Check if repository exists
From: Goffredo Baroncelli <kreijack@libero.it>
Subject: Re: Trivial: in remoterepository.__init__ check if the repository
exist
I hope that this is correct :-)
Another typo, another patch, tank to Peter Stamfest and Radoslaw Szkodzinski.
The patch is trivial: adds a check in the body of the init method of the
+remoterepository
class. Before if the path didn't exist, hg would not raise any error.
Test manually performed after the patch has been merged:
test: result
create a new repository from another local repository OK ( no problem )
create an empty repository OK ( no problem )
pull from a not existent repositary OK ( raise an error )
(error message tweaked by mpm)
manifest hash: ac7f625a8d87c693b61718b9fc5604d28b882bbd
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
iD8DBQFCuM0gywK+sNU5EO8RAsnGAJ42HE3m01tlGqrIR3GVfuhvCjEJkgCfffvp
bEhfvjaiAdBV50HMULq8N00=
=QDHW
-----END PGP SIGNATURE-----
author | mpm@selenic.com |
---|---|
date | Tue, 21 Jun 2005 18:29:52 -0800 |
parents | 8b067bde6679 |
children | 688d03d6997a |
rev | line source |
---|---|
0
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
1 #!/usr/bin/env python |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
2 |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
3 # This is the mercurial setup script. |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
4 # |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
5 # './setup.py install', or |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
6 # './setup.py --help' for more options |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
7 |
157
2653740d8118
Install the templates where they can be found by hgweb.py
mpm@selenic.com
parents:
155
diff
changeset
|
8 import glob |
72 | 9 from distutils.core import setup, Extension |
157
2653740d8118
Install the templates where they can be found by hgweb.py
mpm@selenic.com
parents:
155
diff
changeset
|
10 from distutils.command.install_data import install_data |
2653740d8118
Install the templates where they can be found by hgweb.py
mpm@selenic.com
parents:
155
diff
changeset
|
11 |
2653740d8118
Install the templates where they can be found by hgweb.py
mpm@selenic.com
parents:
155
diff
changeset
|
12 class install_package_data(install_data): |
2653740d8118
Install the templates where they can be found by hgweb.py
mpm@selenic.com
parents:
155
diff
changeset
|
13 def finalize_options(self): |
2653740d8118
Install the templates where they can be found by hgweb.py
mpm@selenic.com
parents:
155
diff
changeset
|
14 self.set_undefined_options('install', |
2653740d8118
Install the templates where they can be found by hgweb.py
mpm@selenic.com
parents:
155
diff
changeset
|
15 ('install_lib', 'install_dir')) |
2653740d8118
Install the templates where they can be found by hgweb.py
mpm@selenic.com
parents:
155
diff
changeset
|
16 install_data.finalize_options(self) |
0
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
17 |
9117c6561b0b
Add back links from file revisions to changeset revisions
mpm@selenic.com
parents:
diff
changeset
|
18 setup(name='mercurial', |
193
0a28dfe59f8f
Bump the version number to 0.5b for the protocol change
mpm@selenic.com
parents:
188
diff
changeset
|
19 version='0.5b', |
72 | 20 author='Matt Mackall', |
21 author_email='mpm@selenic.com', | |
22 url='http://selenic.com/mercurial', | |
23 description='scalable distributed SCM', | |
24 license='GNU GPL', | |
25 packages=['mercurial'], | |
400
8b067bde6679
Add a fast binary diff extension (not yet used)
mpm@selenic.com
parents:
241
diff
changeset
|
26 ext_modules=[Extension('mercurial.mpatch', ['mercurial/mpatch.c']), |
8b067bde6679
Add a fast binary diff extension (not yet used)
mpm@selenic.com
parents:
241
diff
changeset
|
27 Extension('mercurial.bdiff', ['mercurial/bdiff.c'])], |
157
2653740d8118
Install the templates where they can be found by hgweb.py
mpm@selenic.com
parents:
155
diff
changeset
|
28 data_files=[('mercurial/templates', |
218
06bc1ef248a6
hgweb: put map-raw in setup.py and MANIFEST.in
mpm@selenic.com
parents:
193
diff
changeset
|
29 ['templates/map'] + |
06bc1ef248a6
hgweb: put map-raw in setup.py and MANIFEST.in
mpm@selenic.com
parents:
193
diff
changeset
|
30 glob.glob('templates/map-*') + |
06bc1ef248a6
hgweb: put map-raw in setup.py and MANIFEST.in
mpm@selenic.com
parents:
193
diff
changeset
|
31 glob.glob('templates/*.tmpl'))], |
157
2653740d8118
Install the templates where they can be found by hgweb.py
mpm@selenic.com
parents:
155
diff
changeset
|
32 cmdclass = { 'install_data' : install_package_data }, |
240 | 33 scripts=['hg', 'hgmerge']) |