Skip to content

Commit f90227d

Browse files
author
FND
committed
fixed packaging
guarding against generated DESC file missing from the distribution Having a README different from long_description is proving to be a bit of a pain...
1 parent e06bdec commit f90227d

File tree

2 files changed

+10
-3
lines changed

2 files changed

+10
-3
lines changed

setup.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,18 +11,25 @@
1111
from spackager import __version__
1212

1313

14+
try:
15+
long_desc = open(os.path.join(os.path.dirname(__file__), 'DESC')).read()
16+
except IOError: # XXX: hacky way to avoid including DESC in distribution
17+
long_desc = None
18+
19+
1420
setup(
1521
name = NAME,
1622
version = __version__,
1723
description = DESCRIPTION,
18-
long_description = open(os.path.join(os.path.dirname(__file__), 'DESC')).read(),
24+
long_description = long_desc,
1925
author = AUTHOR,
2026
author_email = AUTHOR_EMAIL,
2127
url = 'http://pypi.python.org/pypi/%s' % NAME,
2228
platforms = 'Posix; MacOS X; Windows',
2329
packages = find_packages(exclude=['test']),
2430
scripts = ['spac'],
25-
install_requires = ['pyquery']
31+
#package_data = { '': ['DESC'] },
32+
install_requires = ['pyquery'],
2633
#include_package_data = True,
2734
#zip_safe = False
2835
)

spackager/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,4 @@
1919
the doctyle declaration.
2020
"""
2121

22-
__version__ = '0.5.1'
22+
__version__ = '0.5.2'

0 commit comments

Comments
 (0)