Added a --clean option to setup.py.

This commit is contained in:
Jeremy Fincher 2004-08-22 15:28:04 +00:00
parent 21dea0efc5
commit ab6d1673f3
3 changed files with 25 additions and 45 deletions

10
README
View File

@ -5,8 +5,9 @@ Read LICENSE. It's a 2-clause BSD license, but you should read it anyway.
USERS:
------
Read docs/GETTING_STARTED for an introduction to the bot. Read
docs/CAPABILITIES to see how to use capabilities more to your
If you're upgrading, read RELNOTES. If you're new to Supybot,
read docs/GETTING_STARTED for an introduction to the bot, and read
docs/CAPABILITIES to see how to use capabilities to your greater
benefit.
If you have any trouble, feel free to swing by #supybot on
@ -32,11 +33,6 @@ Read INTERFACES to see what kinds of objects you'll be dealing with.
Read STYLE if you wish to contribute; all contributed code must meet
the guidelines set forth there..
Use PyLint. It's even better than PyChecker. A sample .pylintrc file
is included as tools/pylintrc. Copy this to ~/.pylintrc and you'll be
able to check your code with the same stringent guidelines I've found
useful to check my code. (deja vu? :))
Be sure to run "test/test.py --help" to see what options are available
to you when testing. Windows users in particular should be sure to
exclude test_Debian.py and test_Unix.py.

View File

@ -1,29 +1,7 @@
We changed the way Supybot does imports, and so now in the
installation directory there is no longer any src/ subdirectory. If
your configuration file includes this directory in
supybot.directories.plugins (hint: it does), you'll need to chop off
the "/src" at the end.
Since we now support separate network entries, the old supybot.server
configuration variable won't work. To fix this, add these lines to
your configuration:
supybot.networks.default: <network>
supybot.networks.<network>.servers: <server>
supybot.networks.<network>.password: <password>
Where <network> is the name of the network you're connecting to,
<server> is the old supybot.server, and <password> is the old
supybot.password. Also note the "servers" rather than "server": we
now allow the configuration of multiple servers per network.
Since we support multiple networks and multiple servers now, the
--server option has been removed from scripts/supybot, as has the
--password option.
supybot.defaultCapabilities is space-separated now, not
comma-separated. You you should remove the commas from this value in
your configuration file before loading the bot.
We've changed so much stuff in this release that we've given up on
users upgrading their configuration files for the new release. So
do a clean install (python2.3 setup.py install --clean), run the
wizard again, and kick some butt.
Version 0.77.2

View File

@ -36,6 +36,11 @@ if sys.version_info < (2, 3, 0):
sys.stderr.write("Supybot requires Python 2.3 or newer.\n")
sys.exit(-1)
clean = False
while '--clean' in sys.argv:
clean = True
sys.argv.remove('--clean')
import glob
import shutil
import os.path
@ -64,30 +69,31 @@ srcFiles = glob.glob(os.path.join('src', '*.py'))
otherFiles = glob.glob(os.path.join('others', '*.py'))
pluginFiles = glob.glob(os.path.join('plugins', '*.py'))
## previousInstall = os.path.join(get_python_lib(), 'supybot')
## if os.path.exists(previousInstall):
## try:
## shutil.rmtree(previousInstall)
## except Exception, e:
## print 'Couldn\'t remove former installation: %s' % e
## print 'Remove by hand and then run this script.'
## sys.exit(-1)
if clean:
previousInstall = os.path.join(get_python_lib(), 'supybot')
if os.path.exists(previousInstall):
try:
print 'Removing current installation.'
shutil.rmtree(previousInstall)
except Exception, e:
print 'Couldn\'t remove former installation: %s' % e
sys.exit(-1)
setup(
# Metadata
name='supybot',
version='0.77.2+cvs',
url='http://supybot.sf.net/',
author='Jeremy Fincher',
url='http://supybot.sf.net/',
author_email='jemfinch@users.sf.net',
download_url='http://www.sf.net/project/showfiles.php?group_id=58965',
description='A flexible and extensible Python IRC bot and framework.',
long_description="""A robust, full-featured Python IRC bot with a clean and
flexible plugin API. Equipped with a complete ACL system for specifying
user permissions with as much as per-command granularity. Batteries are
included in the form of numerous plugins already written.""",
download_url='http://www.sf.net/project/showfiles.php?group_id=58965',
classifiers = [
'Development Status :: 3 - Alpha',
'Development Status :: 4 - Beta',
'Environment :: Console',
'Environment :: No Input/Output (Daemon)',
'Intended Audience :: End Users/Desktop',