Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Read README as utf-8 text and set the content_type to text/markdown #26

Merged
merged 2 commits into from Aug 24, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
14 changes: 8 additions & 6 deletions setup.py
@@ -1,13 +1,14 @@
import re
import io
import os
from setuptools import setup

description = 'Version-bump your software with a single command!'

long_description = re.sub(
"\`(.*)\<#.*\>\`\_",
r"\1",
str(open('README.md', 'rb').read()).replace(description, '')
)
# Import the README and use it as the long-description.
# This requires 'README.md' to be present in MANIFEST.in.
here = os.path.abspath(os.path.dirname(__file__))
with io.open(os.path.join(here, 'README.md'), encoding='utf-8') as f:
long_description = '\n' + f.read()

setup(
name='bump2version',
Expand All @@ -19,6 +20,7 @@
packages=['bumpversion'],
description=description,
long_description=long_description,
long_description_content_type='text/markdown',
entry_points={
'console_scripts': [
'bumpversion = bumpversion:main',
Expand Down