| 1 |
"""Installs CherryPy using distutils |
|---|
| 2 |
|
|---|
| 3 |
Run: |
|---|
| 4 |
python setup.py install |
|---|
| 5 |
|
|---|
| 6 |
to install this package. |
|---|
| 7 |
""" |
|---|
| 8 |
|
|---|
| 9 |
|
|---|
| 10 |
|
|---|
| 11 |
|
|---|
| 12 |
|
|---|
| 13 |
|
|---|
| 14 |
|
|---|
| 15 |
|
|---|
| 16 |
|
|---|
| 17 |
|
|---|
| 18 |
|
|---|
| 19 |
|
|---|
| 20 |
|
|---|
| 21 |
|
|---|
| 22 |
|
|---|
| 23 |
|
|---|
| 24 |
|
|---|
| 25 |
|
|---|
| 26 |
|
|---|
| 27 |
|
|---|
| 28 |
|
|---|
| 29 |
from distutils.core import setup |
|---|
| 30 |
from distutils.command.install import INSTALL_SCHEMES |
|---|
| 31 |
import sys |
|---|
| 32 |
|
|---|
| 33 |
required_python_version = '2.4' |
|---|
| 34 |
|
|---|
| 35 |
|
|---|
| 36 |
|
|---|
| 37 |
|
|---|
| 38 |
name = "pyarticle" |
|---|
| 39 |
version = "0.1_beta1" |
|---|
| 40 |
desc = "Pythonic way to article handling" |
|---|
| 41 |
long_desc = """Module for handling articles in CMS/blogs/etc: convert articles from various |
|---|
| 42 |
input formats to various publishing formats.""" |
|---|
| 43 |
classifiers=[ |
|---|
| 44 |
"Development Status :: 4 - Beta", |
|---|
| 45 |
"Intended Audience :: Developers", |
|---|
| 46 |
"License :: OSI Approved :: GNU Library or Lesser General Public License (LGPL)", |
|---|
| 47 |
"Operating System :: OS Independent", |
|---|
| 48 |
"Programming Language :: Python", |
|---|
| 49 |
"Topic :: Software Development :: Documentation", |
|---|
| 50 |
"Topic :: Software Development :: Libraries :: Python Modules", |
|---|
| 51 |
"Topic :: Text Processing", |
|---|
| 52 |
"Topic :: Text Processing :: Markup :: HTML", |
|---|
| 53 |
"Topic :: Text Processing :: Markup :: XML" |
|---|
| 54 |
] |
|---|
| 55 |
author="Lukas Almad Linhart" |
|---|
| 56 |
author_email="bugs@almad.net" |
|---|
| 57 |
url="http://projects.almad.net/pyarticle" |
|---|
| 58 |
cp_license="LGPL" |
|---|
| 59 |
packages=[ |
|---|
| 60 |
"pyarticle" |
|---|
| 61 |
] |
|---|
| 62 |
scripts = ['bin/pyarticle'] |
|---|
| 63 |
download_url="http://projects.almad.net/pyarticle/wiki/Download" |
|---|
| 64 |
data_files=[] |
|---|
| 65 |
|
|---|
| 66 |
|
|---|
| 67 |
|
|---|
| 68 |
|
|---|
| 69 |
def main(): |
|---|
| 70 |
if sys.version < required_python_version: |
|---|
| 71 |
s = "I'm sorry, but %s %s requires Python %s or later." |
|---|
| 72 |
print s % (name, version, required_python_version) |
|---|
| 73 |
sys.exit(1) |
|---|
| 74 |
|
|---|
| 75 |
|
|---|
| 76 |
|
|---|
| 77 |
for scheme in INSTALL_SCHEMES.values(): |
|---|
| 78 |
scheme['data'] = scheme['purelib'] |
|---|
| 79 |
|
|---|
| 80 |
setup( |
|---|
| 81 |
name=name, |
|---|
| 82 |
version=version, |
|---|
| 83 |
description=desc, |
|---|
| 84 |
long_description=long_desc, |
|---|
| 85 |
classifiers=classifiers, |
|---|
| 86 |
author=author, |
|---|
| 87 |
author_email=author_email, |
|---|
| 88 |
url=url, |
|---|
| 89 |
license=cp_license, |
|---|
| 90 |
packages=packages, |
|---|
| 91 |
download_url=download_url, |
|---|
| 92 |
data_files=data_files, |
|---|
| 93 |
scripts=scripts |
|---|
| 94 |
) |
|---|
| 95 |
|
|---|
| 96 |
if __name__ == "__main__": |
|---|
| 97 |
main() |
|---|