(refs #402) sort changed files for easier display
[buildbot.git] / setup.py
bloba48b97f5ce887d05c088505a86ea78fbae66438a
1 #!/usr/bin/env python
2 """
3 Standard setup script.
4 """
6 import sys
7 import os
8 import re
9 from distutils.core import setup
10 from buildbot import version
12 # Path: twisted!cvstoys!buildbot
13 from distutils.command.install_data import install_data
14 class install_data_twisted(install_data):
15 """make sure data files are installed in package.
16 this is evil.
17 copied from Twisted/setup.py.
18 """
19 def finalize_options(self):
20 self.set_undefined_options('install',
21 ('install_lib', 'install_dir'),
23 install_data.finalize_options(self)
25 long_description="""
26 The BuildBot is a system to automate the compile/test cycle required by
27 most software projects to validate code changes. By automatically
28 rebuilding and testing the tree each time something has changed, build
29 problems are pinpointed quickly, before other developers are
30 inconvenienced by the failure. The guilty developer can be identified
31 and harassed without human intervention. By running the builds on a
32 variety of platforms, developers who do not have the facilities to test
33 their changes everywhere before checkin will at least know shortly
34 afterwards whether they have broken the build or not. Warning counts,
35 lint checks, image size, compile time, and other build parameters can
36 be tracked over time, are more visible, and are therefore easier to
37 improve.
38 """
40 scripts = ["bin/buildbot"]
41 if sys.platform == "win32":
42 scripts.append("contrib/windows/buildbot.bat")
43 scripts.append("contrib/windows/buildbot_service.py")
45 testmsgs = []
46 for f in os.listdir("buildbot/test/mail"):
47 if f.endswith("~"):
48 continue
49 if re.search(r'\.\d+$', f):
50 testmsgs.append("buildbot/test/mail/%s" % f)
52 setup_args = {
53 'name': "buildbot",
54 'version': version,
55 'description': "BuildBot build automation system",
56 'long_description': long_description,
57 'author': "Brian Warner",
58 'author_email': "warner-buildbot@lothar.com",
59 'url': "http://buildbot.net/",
60 'license': "GNU GPL",
61 # does this classifiers= mean that this can't be installed on 2.2/2.3?
62 'classifiers': [
63 'Development Status :: 4 - Beta',
64 'Environment :: No Input/Output (Daemon)',
65 'Environment :: Web Environment',
66 'Intended Audience :: Developers',
67 'License :: OSI Approved :: GNU General Public License (GPL)',
68 'Topic :: Software Development :: Build Tools',
69 'Topic :: Software Development :: Testing',
72 'packages': ["buildbot",
73 "buildbot.status", "buildbot.status.web",
74 "buildbot.changes",
75 "buildbot.steps",
76 "buildbot.process",
77 "buildbot.clients",
78 "buildbot.slave",
79 "buildbot.scripts",
80 "buildbot.test",
82 'data_files': [("buildbot", ["buildbot/buildbot.png"]),
83 ("buildbot/clients", ["buildbot/clients/debug.glade"]),
84 ("buildbot/status/web",
85 ["buildbot/status/web/classic.css",
86 "buildbot/status/web/index.html",
87 "buildbot/status/web/robots.txt",
88 ]),
89 ("buildbot/scripts", ["buildbot/scripts/sample.cfg"]),
90 ("buildbot/test/mail", testmsgs),
91 ("buildbot/test/subdir", ["buildbot/test/subdir/emit.py"]),
93 'scripts': scripts,
94 'cmdclass': {'install_data': install_data_twisted},
97 try:
98 # If setuptools is installed, then we'll add setuptools-specific arguments
99 # to the setup args.
100 import setuptools
101 except ImportError:
102 pass
103 else:
104 setup_args['install_requires'] = ['twisted >= 2.0.0']
105 entry_points={
106 'console_scripts': [
107 'buildbot = buildbot.scripts.runner:run'],
110 setup(**setup_args)
112 # Local Variables:
113 # fill-column: 71
114 # End: