From 13fa0847ab676ee2975403cefdb25f2d5395f4ad Mon Sep 17 00:00:00 2001 From: Dmitry Shachnev Date: Sun, 9 Sep 2012 17:24:22 +0400 Subject: setup.py: Add `long_description` attribute to `data` so that there's no text breakage on PyPI page --- setup.py | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'setup.py') diff --git a/setup.py b/setup.py index 3491300..e6fbdd7 100755 --- a/setup.py +++ b/setup.py @@ -165,6 +165,27 @@ class md_build(build): sub_commands = build.sub_commands + [('build_docs', has_docs)] +long_description = \ +'''This is a Python implementation of John Gruber's Markdown_. +It is almost completely compliant with the reference implementation, +though there are a few known issues. See Features_ for information +on what exactly is supported and what is not. Additional features are +supported by the `Available Extensions`_. + +.. _Python-Markdown: http://packages.python.org/Markdown/ +.. _Markdown: http://daringfireball.net/projects/markdown/ +.. _Features: http://packages.python.org/Markdown/index.html#Features +.. _`Available Extensions`: http://packages.python.org/Markdown/extensions/index.html + +Support +======= + +You may ask for help and discuss various other issues on the +`mailing list`_ and report bugs on the `bug tracker`_. + +.. _`mailing list`: http://lists.sourceforge.net/lists/listinfo/python-markdown-discuss +.. _`bug tracker`: http://github.com/waylan/Python-Markdown/issues +''' data = dict( name = 'Markdown', @@ -172,6 +193,7 @@ data = dict( url = 'http://packages.python.org/Markdown/', download_url = 'http://pypi.python.org/packages/source/M/Markdown/Markdown-%s.tar.gz' % version, description = 'Python implementation of Markdown.', + long_description = long_description, author = 'Manfred Stienstra, Yuri takhteyev and Waylan limberg', author_email = 'markdown [at] freewisdom.org', maintainer = 'Waylan Limberg', -- cgit v1.2.3 From a3656333ea3f7b391b1b61c13e3566b4e0d81053 Mon Sep 17 00:00:00 2001 From: Dmitry Shachnev Date: Sun, 9 Sep 2012 18:26:44 +0400 Subject: Remove unneeded link --- setup.py | 1 - 1 file changed, 1 deletion(-) (limited to 'setup.py') diff --git a/setup.py b/setup.py index e6fbdd7..6551c5f 100755 --- a/setup.py +++ b/setup.py @@ -172,7 +172,6 @@ though there are a few known issues. See Features_ for information on what exactly is supported and what is not. Additional features are supported by the `Available Extensions`_. -.. _Python-Markdown: http://packages.python.org/Markdown/ .. _Markdown: http://daringfireball.net/projects/markdown/ .. _Features: http://packages.python.org/Markdown/index.html#Features .. _`Available Extensions`: http://packages.python.org/Markdown/extensions/index.html -- cgit v1.2.3 From 6aa18462014e9c6327b84bf39108dd5f56db37e5 Mon Sep 17 00:00:00 2001 From: Waylan Limberg Date: Sun, 4 Nov 2012 17:49:37 -0500 Subject: Upped version to 2.2.1. --- setup.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'setup.py') diff --git a/setup.py b/setup.py index 6551c5f..c501e0a 100755 --- a/setup.py +++ b/setup.py @@ -17,7 +17,7 @@ except ImportError: raise ImportError("build_py_2to3 is required to build in Python 3.x.") from distutils.command.build_py import build_py -version = '2.2.0' +version = '2.2.1' # The command line script name. Currently set to "markdown_py" so as not to # conflict with the perl implimentation (which uses "markdown"). We can't use @@ -209,7 +209,6 @@ data = dict( 'Operating System :: OS Independent', 'Programming Language :: Python', 'Programming Language :: Python :: 2', - 'Programming Language :: Python :: 2.4', 'Programming Language :: Python :: 2.5', 'Programming Language :: Python :: 2.6', 'Programming Language :: Python :: 2.7', -- cgit v1.2.3 From e57b954a1f964ec0635d189c16d130c4e6ba5479 Mon Sep 17 00:00:00 2001 From: Waylan Limberg Date: Wed, 5 Dec 2012 11:30:06 -0500 Subject: Upped version to 2.3.dev. Also refactored the version info to force PEP 386 compliance and to avoid the need to change the version in both the source and setup.py --- setup.py | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) (limited to 'setup.py') diff --git a/setup.py b/setup.py index c501e0a..d8221be 100755 --- a/setup.py +++ b/setup.py @@ -17,7 +17,21 @@ except ImportError: raise ImportError("build_py_2to3 is required to build in Python 3.x.") from distutils.command.build_py import build_py -version = '2.2.1' +# Get version & version_info without importing markdown +execfile(os.path.join(os.path.dirname(os.path.abspath(__file__)), + 'markdown/__version__.py')) + +# Get development Status for classifiers +dev_status_map = { + 'alpha': '3 - Alpha', + 'beta' : '4 - Beta', + 'rc' : '4 - Beta', + 'final': '5 - Production/Stable' +} +if version_info[3] == 'alpha' and version_info[4] == 0: + DEVSTATUS = '2 - Pre-Alpha' +else: + DEVSTATUS = dev_status_map[version_info[3]] # The command line script name. Currently set to "markdown_py" so as not to # conflict with the perl implimentation (which uses "markdown"). We can't use @@ -204,7 +218,7 @@ data = dict( 'build_py': build_py, 'build_docs': build_docs, 'build': md_build}, - classifiers = ['Development Status :: 5 - Production/Stable', + classifiers = ['Development Status :: %s' % DEVSTATUS, 'License :: OSI Approved :: BSD License', 'Operating System :: OS Independent', 'Programming Language :: Python', -- cgit v1.2.3 From d6a747570a053f15dc4951689b7820248f2cc25f Mon Sep 17 00:00:00 2001 From: Waylan Limberg Date: Tue, 18 Dec 2012 14:57:07 -0500 Subject: Fixed #169. The new version stuff now works in python 2 & 3. --- setup.py | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) (limited to 'setup.py') diff --git a/setup.py b/setup.py index d8221be..855a08d 100755 --- a/setup.py +++ b/setup.py @@ -8,6 +8,7 @@ from distutils.command.build import build from distutils.core import Command from distutils.util import change_root, newer import codecs +import imp # Try to run 2to3 automaticaly when building in Python 3.x try: @@ -17,9 +18,17 @@ except ImportError: raise ImportError("build_py_2to3 is required to build in Python 3.x.") from distutils.command.build_py import build_py -# Get version & version_info without importing markdown -execfile(os.path.join(os.path.dirname(os.path.abspath(__file__)), - 'markdown/__version__.py')) +def get_version(): + " Get version & version_info without importing markdown.__init__ " + path = os.path.join(os.path.dirname(__file__), 'markdown') + fp, pathname, desc = imp.find_module('__version__', [path]) + try: + v = imp.load_module('__version__', fp, pathname, desc) + return v.version, v.version_info + finally: + fp.close() + +version, version_info = get_version() # Get development Status for classifiers dev_status_map = { -- cgit v1.2.3 From 4e65bb6b49f85a311aac0b6225b7520388486ff5 Mon Sep 17 00:00:00 2001 From: Waylan Limberg Date: Thu, 10 Jan 2013 20:23:16 -0500 Subject: No longer support python 2.5 --- setup.py | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'setup.py') diff --git a/setup.py b/setup.py index 855a08d..37410a4 100755 --- a/setup.py +++ b/setup.py @@ -209,7 +209,7 @@ You may ask for help and discuss various other issues on the .. _`bug tracker`: http://github.com/waylan/Python-Markdown/issues ''' -data = dict( +setup( name = 'Markdown', version = version, url = 'http://packages.python.org/Markdown/', @@ -247,9 +247,3 @@ data = dict( 'Topic :: Text Processing :: Markup :: HTML', ], ) - -if sys.version[:3] < '2.5': - data['install_requires'] = ['elementtree'] - -setup(**data) - -- cgit v1.2.3 From ff80e467ea875e4677fcc20c189ef730ef240a07 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= Date: Sun, 13 Jan 2013 10:13:21 +0100 Subject: Support disabling documentation build via --no-build-docs. --- setup.py | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'setup.py') diff --git a/setup.py b/setup.py index 37410a4..3e6beb7 100755 --- a/setup.py +++ b/setup.py @@ -183,8 +183,19 @@ class build_docs(Command): class md_build(build): """ Run "build_docs" command from "build" command. """ + + user_options = build.user_options + [ + ('no-build-docs', None, 'do not build documentation'), + ] + + boolean_options = build.boolean_options + ['build-docs'] + + def initialize_options(self): + build.initialize_options(self) + self.no_build_docs = False + def has_docs(self): - return True + return not self.no_build_docs sub_commands = build.sub_commands + [('build_docs', has_docs)] -- cgit v1.2.3