Skip to content

Commit f7a55f0

Browse files
committed
Updated setup.py to include long_description
pypi upload will fail if long description is missing. Also, the content_type should also be mentioned.
1 parent d4742d0 commit f7a55f0

File tree

1 file changed

+5
-2
lines changed
  • {{cookiecutter.project_shortname}}

1 file changed

+5
-2
lines changed

{{cookiecutter.project_shortname}}/setup.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
import json
2-
import os
32
from setuptools import setup
3+
from pathlib import Path
44

5-
5+
here = Path(__file__).parent
66
with open('package.json') as f:
77
package = json.load(f)
8+
long_description = (here / 'README.md').read_text()
89

910
package_name = package["name"].replace(" ", "_").replace("-", "_")
1011

@@ -16,6 +17,8 @@
1617
include_package_data=True,
1718
license=package['license'],
1819
description=package.get('description', package_name),
20+
long_description=long_description,
21+
long_description_content_type="text/markdown",
1922
install_requires=[],
2023
classifiers = [
2124
'Framework :: Dash',

0 commit comments

Comments
 (0)