diff options
author | tarek <none@none> | 2009-08-08 21:10:11 +0200 |
---|---|---|
committer | tarek <none@none> | 2009-08-08 21:10:11 +0200 |
commit | 96f2536dcc1056dffa72f0877f1683b6633440f0 (patch) | |
tree | 19b9e79451aca738677aa72cf67a444a97be61c6 | |
parent | def1a4f577242d326a93268c2851e2b3f48c5329 (diff) | |
download | external_python_setuptools-96f2536dcc1056dffa72f0877f1683b6633440f0.tar.gz external_python_setuptools-96f2536dcc1056dffa72f0877f1683b6633440f0.tar.bz2 external_python_setuptools-96f2536dcc1056dffa72f0877f1683b6633440f0.zip |
bootstrapping.py -> distribute_setup.py
--HG--
branch : distribute
extra : rebase_source : 4e57a0bc1a8bea73bc8ed0f102d0e0907c554235
-rwxr-xr-x | README.txt | 18 | ||||
-rw-r--r-- | distribute_setup.py (renamed from bootstrapping.py) | 4 | ||||
-rw-r--r-- | docs/easy_install.txt | 4 | ||||
-rw-r--r-- | docs/setuptools.txt | 36 | ||||
-rwxr-xr-x | release.sh | 8 | ||||
-rwxr-xr-x | setup.py | 4 | ||||
-rw-r--r-- | setuptools/__init__.py | 4 | ||||
-rw-r--r-- | tests/install_test.py | 14 | ||||
-rwxr-xr-x | virtual-python.py | 18 |
9 files changed, 55 insertions, 55 deletions
@@ -40,20 +40,20 @@ are available at the PyPI page and here : http://bitbucket.org/tarek/distribute/downloads. It can be installed using easy_install or pip, with the source tarball, with the -eggs distribution, or using the ``bootstrapping.py`` script provided online. +eggs distribution, or using the ``distribute_setup.py`` script provided online. -``bootstrapping.py`` is the simplest and preferred way on all systems. +``distribute_setup.py`` is the simplest and preferred way on all systems. -bootstrapping.py -================ +distribute_setup.py +=================== -Download ``bootstrapping.py`` and execute it, using the Python interpreter of +Download ``distribute_setup.py`` and execute it, using the Python interpreter of your choice. -If your shell has the `wget` programm you can do:: +If your shell has the `wget` program you can do:: - $ wget http://bitbucket.org/tarek/distribute/downloads/bootstrapping.py - $ python bootstrapping.py + $ wget http://bitbucket.org/tarek/distribute/downloads/distribute_setup.py + $ python distribute_setup.py easy_install or pip =================== @@ -117,7 +117,7 @@ Windows ------- Don't install Distribute trying to execute the egg, because it's aimed to -sh-based shells. Instead, use the ``bootstrapping.py`` method, that will +sh-based shells. Instead, use the ``distribute_setup.py`` method, that will download the egg for you, then install the egg. --------------------------- diff --git a/bootstrapping.py b/distribute_setup.py index f7e2045e..c3f3fa34 100644 --- a/bootstrapping.py +++ b/distribute_setup.py @@ -4,7 +4,7 @@ If you want to use setuptools in your package's setup.py, just include this file in the same directory with it, and add this to the top of your setup.py:: - from bootstrapping import use_setuptools + from distribute_setup import use_setuptools use_setuptools() If you want to require a specific version of setuptools, set a download @@ -391,7 +391,7 @@ def main(argv, version=DEFAULT_VERSION): #main(argv) else: print "distribute version",version,"or greater has been installed." - print '(Run "bootstrapping.py -U distribute" to reinstall or upgrade.)' + print '(Run "distribute_setup.py -U distribute" to reinstall or upgrade.)' def update_md5(filenames): """Update our built-in md5 registry""" diff --git a/docs/easy_install.txt b/docs/easy_install.txt index 4461ad31..ff0ad3d8 100644 --- a/docs/easy_install.txt +++ b/docs/easy_install.txt @@ -94,7 +94,7 @@ directory, you can also retarget the installation location for scripts so they go on a directory that's already on the ``PATH``. For more information see the sections below on `Command-Line Options`_ and `Configuration Files`_. You can pass command line options (such as ``--script-dir``) to -``bootstrapping.py`` to control where ``easy_install.exe`` will be installed. +``distribute_setup.py`` to control where ``easy_install.exe`` will be installed. @@ -1111,7 +1111,7 @@ already have them:: install_lib = ~/py-lib install_scripts = ~/bin -Be sure to do this *before* you try to run the ``bootstrapping.py`` +Be sure to do this *before* you try to run the ``distribute_setup.py`` installation script. Then, follow the standard `installation instructions`_, but make sure that ``~/py-lib`` is listed in your ``PYTHONPATH`` environment variable. diff --git a/docs/setuptools.txt b/docs/setuptools.txt index 79a17006..bc51df2d 100644 --- a/docs/setuptools.txt +++ b/docs/setuptools.txt @@ -15,7 +15,7 @@ including just a single `bootstrap module`_ (an 8K .py file), your package will automatically download and install ``setuptools`` if the user is building your package from source and doesn't have a suitable version already installed. -.. _bootstrap module: http://cdn.bitbucket.org/tarek/distribute/downloads/bootstrapping.py +.. _bootstrap module: http://cdn.bitbucket.org/tarek/distribute/downloads/distribute_setup.py Feature Highlights: @@ -72,7 +72,7 @@ is available from the `Python SVN sandbox`_, and in-development versions of the .. contents:: **Table of Contents** -.. _bootstrapping.py: `bootstrap module`_ +.. _distribute_setup.py: `bootstrap module`_ ----------------- @@ -95,7 +95,7 @@ other than Python's ``site-packages`` directory. If you want the current in-development version of setuptools, you should first install a stable version, and then run:: - bootstrapping.py setuptools==dev + distribute_setup.py setuptools==dev This will download and install the latest development (i.e. unstable) version of setuptools from the Python Subversion sandbox. @@ -523,7 +523,7 @@ Python must be available via the ``PATH`` environment variable, under its "long" name. That is, if the egg is built for Python 2.3, there must be a ``python2.3`` executable present in a directory on ``PATH``. -This feature is primarily intended to support bootstrapping the installation of +This feature is primarily intended to support distribute_setup the installation of setuptools itself on non-Windows platforms, but may also be useful for other projects as well. @@ -1102,18 +1102,18 @@ Using ``setuptools``... Without bundling it! Your users might not have ``setuptools`` installed on their machines, or even if they do, it might not be the right version. Fixing this is easy; just -download `bootstrapping.py`_, and put it in the same directory as your ``setup.py`` +download `distribute_setup.py`_, and put it in the same directory as your ``setup.py`` script. (Be sure to add it to your revision control system, too.) Then add these two lines to the very top of your setup script, before the script imports anything from setuptools:: - import bootstrapping - bootstrapping.use_setuptools() + import distribute_setup + distribute_setup.use_setuptools() -That's it. The ``bootstrapping`` module will automatically download a matching +That's it. The ``distribute_setup`` module will automatically download a matching version of ``setuptools`` from PyPI, if it isn't present on the target system. Whenever you install an updated version of setuptools, you should also update -your projects' ``bootstrapping.py`` files, so that a matching version gets installed +your projects' ``distribute_setup.py`` files, so that a matching version gets installed on the target machine(s). By the way, setuptools supports the new PyPI "upload" command, so you can use @@ -1143,7 +1143,7 @@ relevant to your project and your target audience isn't already familiar with setuptools and ``easy_install``. Network Access - If your project is using ``bootstrapping``, you should inform users of the + If your project is using ``distribute_setup``, you should inform users of the need to either have network access, or to preinstall the correct version of setuptools using the `EasyInstall installation instructions`_. Those instructions also have tips for dealing with firewalls as well as how to @@ -1223,27 +1223,27 @@ Creating System Packages Managing Multiple Projects -------------------------- -If you're managing several projects that need to use ``bootstrapping``, and you +If you're managing several projects that need to use ``distribute_setup``, and you are using Subversion as your revision control system, you can use the -"svn:externals" property to share a single copy of ``bootstrapping`` between +"svn:externals" property to share a single copy of ``distribute_setup`` between projects, so that it will always be up-to-date whenever you check out or update an individual project, without having to manually update each project to use a new version. However, because Subversion only supports using directories as externals, you -have to turn ``bootstrapping.py`` into ``bootstrapping/__init__.py`` in order -to do this, then create "externals" definitions that map the ``bootstrapping`` +have to turn ``distribute_setup.py`` into ``distribute_setup/__init__.py`` in order +to do this, then create "externals" definitions that map the ``distribute_setup`` directory into each project. Also, if any of your projects use ``find_packages()`` on their setup directory, you will need to exclude the -resulting ``bootstrapping`` package, to keep it from being included in your +resulting ``distribute_setup`` package, to keep it from being included in your distributions, e.g.:: setup( ... - packages = find_packages(exclude=['bootstrapping']), + packages = find_packages(exclude=['distribute_setup']), ) -Of course, the ``bootstrapping`` package will still be included in your +Of course, the ``distribute_setup`` package will still be included in your packages' source distributions, as it needs to be. For your convenience, you may use the following external definition, which will @@ -2584,7 +2584,7 @@ XXX Reusing ``setuptools`` Code =========================== -``bootstrapping`` +``distribute_setup`` ----------------- XXX @@ -15,10 +15,10 @@ python2.6 setup.py -q egg_info -RDb '' bdist_egg python2.6 setup.py -q egg_info -RDb '' sdist # updating the md5 hashes -python bootstrapping.py --md5update dist/distribute-$VERSION-py2.3.egg -python bootstrapping.py --md5update dist/distribute-$VERSION-py2.4.egg -python bootstrapping.py --md5update dist/distribute-$VERSION-py2.5.egg -python bootstrapping.py --md5update dist/distribute-$VERSION-py2.6.egg +python distribute_setup.py --md5update dist/distribute-$VERSION-py2.3.egg +python distribute_setup.py --md5update dist/distribute-$VERSION-py2.4.egg +python distribute_setup.py --md5update dist/distribute-$VERSION-py2.5.egg +python distribute_setup.py --md5update dist/distribute-$VERSION-py2.6.egg # XXX uploads will be done here @@ -17,7 +17,7 @@ scripts = [] # if we are installing Distribute using "python setup.py install" # we need to get setuptools out of the way if 'install' in sys.argv[1:]: - from bootstrapping import before_install + from distribute_setup import before_install before_install() dist = setup( @@ -101,7 +101,7 @@ dist = setup( scripts = scripts, ) if 'install' in sys.argv[1:]: - from bootstrapping import after_install + from distribute_setup import after_install after_install(dist) diff --git a/setuptools/__init__.py b/setuptools/__init__.py index 58e46d4f..aaf634da 100644 --- a/setuptools/__init__.py +++ b/setuptools/__init__.py @@ -18,7 +18,7 @@ __all__ = [ # or by the Distribute project, in case Setuptools creates # a distribution with the same version. # -# The bootstrapping script for instance, will check if this +# The distribute_setup script for instance, will check if this # attribute is present to decide wether to reinstall the package _distribute = True @@ -43,7 +43,7 @@ def find_packages(where='.', exclude=()): os.path.isfile(os.path.join(fn,'__init__.py')) ): out.append(prefix+name); stack.append((fn,prefix+name+'.')) - for pat in list(exclude)+['ez_setup', 'bootstrapping']: + for pat in list(exclude)+['ez_setup', 'distribute_setup']: from fnmatch import fnmatchcase out = [item for item in out if not fnmatchcase(item,pat)] return out diff --git a/tests/install_test.py b/tests/install_test.py index e507a39b..02deb818 100644 --- a/tests/install_test.py +++ b/tests/install_test.py @@ -2,8 +2,8 @@ import urllib2 import sys import os -if os.path.exists('bootstrapping.py'): - print 'bootstrapping.py exists in the current dir, aborting' +if os.path.exists('distribute_setup.py'): + print 'distribute_setup.py exists in the current dir, aborting' sys.exit(2) print '**** Starting Test' @@ -14,13 +14,13 @@ if is_jython: import subprocess print 'Downloading bootstrap' -file = urllib2.urlopen('http://nightly.ziade.org/bootstrapping.py') -f = open('bootstrapping.py', 'w') +file = urllib2.urlopen('http://nightly.ziade.org/distribute_setup.py') +f = open('distribute_setup.py', 'w') f.write(file.read()) f.close() # running it -args = [sys.executable] + ['bootstrapping.py'] +args = [sys.executable] + ['distribute_setup.py'] if is_jython: res = subprocess.call(args) else: @@ -28,7 +28,7 @@ else: if res != 0: print '**** Test failed, please send me the output at tarek@ziade.org' - os.remove('bootstrapping.py') + os.remove('distribute_setup.py') sys.exit(2) # now checking if Distribute is installed @@ -71,5 +71,5 @@ try: finally: if os.path.exists(script_name): os.remove(script_name) - os.remove('bootstrapping.py') + os.remove('distribute_setup.py') diff --git a/virtual-python.py b/virtual-python.py index 8d705588..73ef4122 100755 --- a/virtual-python.py +++ b/virtual-python.py @@ -45,21 +45,21 @@ def main(): return parser = optparse.OptionParser() - + parser.add_option('-v', '--verbose', action='count', dest='verbose', default=0, help="Increase verbosity") - + parser.add_option('--prefix', dest="prefix", default='~', help="The base directory to install to (default ~)") - + parser.add_option('--clear', dest='clear', action='store_true', help="Clear out the non-root install and start from scratch") - + parser.add_option('--no-site-packages', dest='no_site_packages', action='store_true', help="Don't copy the contents of the global site-packages dir to the " "non-root site-packages") - + options, args = parser.parse_args() global verbose @@ -74,7 +74,7 @@ def main(): verbose = options.verbose assert not args, "No arguments allowed" - + if options.clear: rmtree(lib_dir) rmtree(inc_dir) @@ -115,9 +115,9 @@ def main(): print 'Please make sure you remove any previous custom paths from' print "your", pydistutils, "file." - print "You're now ready to download bootstrapping.py, and run" - print py_executable, "bootstrapping.py" - + print "You're now ready to download distribute_setup.py, and run" + print py_executable, "distribute_setup.py" + if __name__ == '__main__': main() |