comparison setup.py @ 685:77cec2fa0e83

cm: Fix a packaging bug, update package metadata. * Don't add empty strings as install requirements. * Move PieCrust to 'beta' status, change URL, and other metadata tweaks.
author Ludovic Chabant <ludovic@chabant.com>
date Thu, 10 Mar 2016 07:08:15 -0800
parents 551d06cc640c
children 8b3dfd91cbf6
comparison
equal deleted inserted replaced
684:15b5181b2e42 685:77cec2fa0e83
11 11
12 12
13 def read(fname): 13 def read(fname):
14 with open(os.path.join(os.path.dirname(__file__), fname)) as fp: 14 with open(os.path.join(os.path.dirname(__file__), fname)) as fp:
15 return fp.read() 15 return fp.read()
16
17
18 def readlines(fname):
19 lines = [l.strip() for l in read(fname).strip().splitlines()]
16 20
17 21
18 def runcmd(cmd): 22 def runcmd(cmd):
19 with subprocess.Popen( 23 with subprocess.Popen(
20 cmd, stdout=subprocess.PIPE, 24 cmd, stdout=subprocess.PIPE,
145 "WARNING: Can't get version from version file. " 149 "WARNING: Can't get version from version file. "
146 "Will use version `0.0`.") 150 "Will use version `0.0`.")
147 version = '0.0' 151 version = '0.0'
148 152
149 153
150 install_requires = read('requirements.txt').splitlines() 154 install_requires = readlines('requirements.txt')
151 tests_require = read('dev-requirements.txt').splitlines() 155 tests_require = readlines('dev-requirements.txt')
152 156
153 157
154 setup( 158 setup(
155 name="PieCrust", 159 name="PieCrust",
156 version=version, 160 version=version,
157 description="A powerful static website generator and lightweight CMS.", 161 description="A powerful static website generator and lightweight CMS.",
158 long_description=read('README.rst') + '\n\n' + read('CHANGELOG.rst'), 162 long_description=read('README.rst') + '\n\n' + read('CHANGELOG.rst'),
159 author="Ludovic Chabant", 163 author="Ludovic Chabant",
160 author_email="ludovic@chabant.com", 164 author_email="ludovic@chabant.com",
161 license="Apache License 2.0", 165 license="Apache License 2.0",
162 url="http://github.com/ludovicchabant/piecrust2", 166 url="http://bolt80.com/piecrust",
163 keywords=' '.join([ 167 keywords=' '.join([
164 'python', 168 'python',
165 'website', 169 'website',
166 'generator', 170 'generator',
167 'blog', 171 'blog',
168 'portfolio', 172 'portfolio',
169 'gallery', 173 'gallery',
170 'cms' 174 'cms'
171 ]), 175 ]),
172 packages=find_packages(), 176 packages=find_packages(exclude=['garcon', 'tests']),
173 include_package_data=True, 177 include_package_data=True,
174 zip_safe=False, 178 zip_safe=False,
175 install_requires=install_requires, 179 install_requires=install_requires,
176 tests_require=tests_require, 180 tests_require=tests_require,
177 cmdclass={ 181 cmdclass={
178 'test': PyTest, 182 'test': PyTest,
179 'version': GenerateVersionCommand 183 'version': GenerateVersionCommand
180 }, 184 },
181 classifiers=[ 185 classifiers=[
182 'Development Status :: 3 - Alpha', 186 'Development Status :: 4 - Beta',
183 'License :: OSI Approved :: Apache Software License', 187 'License :: OSI Approved :: Apache Software License',
184 'Environment :: Console', 188 'Environment :: Console',
185 'Intended Audience :: Developers', 189 'Intended Audience :: Developers',
186 'Intended Audience :: System Administrators', 190 'Intended Audience :: System Administrators',
187 'Natural Language :: English', 191 'Natural Language :: English',
188 'Operating System :: MacOS :: MacOS X', 192 'Operating System :: MacOS :: MacOS X',
189 'Operating System :: POSIX :: Linux', 193 'Operating System :: POSIX :: Linux',
190 'Operating System :: Microsoft :: Windows', 194 'Operating System :: Microsoft :: Windows',
191 'Programming Language :: Python', 195 'Programming Language :: Python',
192 'Programming Language :: Python :: 3' 196 'Programming Language :: Python :: 3',
197 'Topic :: Internet :: WWW/HTTP :: Site Management'
193 ], 198 ],
194 entry_points={'console_scripts': [ 199 entry_points={'console_scripts': [
195 'chef = piecrust.main:main' 200 'chef = piecrust.main:main'
196 ]} 201 ]}
197 ) 202 )