Skip to content

Commit b73ee6a

Browse files
andylou2tfx-copybara
authored andcommitted
Add a project long description to setup.py.
PiperOrigin-RevId: 304429437
1 parent 6bbac76 commit b73ee6a

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

build_pip_package.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ function main() {
4343
cp ${BUILD_WORKSPACE_DIRECTORY}/setup.py "${TMPDIR}"
4444
cp ${BUILD_WORKSPACE_DIRECTORY}/MANIFEST.in "${TMPDIR}"
4545
cp ${BUILD_WORKSPACE_DIRECTORY}/LICENSE "${TMPDIR}"
46+
cp ${BUILD_WORKSPACE_DIRECTORY}/README.md "${TMPDIR}"
4647

4748
rsync -avm -L --exclude='*_test.py' ${BUILD_WORKSPACE_DIRECTORY}/struct2tensor "${TMPDIR}"
4849

setup.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,9 @@ def is_pure(self):
4242
def has_ext_modules(self):
4343
return True
4444

45+
# Get the long description from the README file.
46+
with open('README.md') as fp:
47+
_LONG_DESCRIPTION = fp.read()
4548

4649
with open('struct2tensor/version.py') as fp:
4750
globals_dict = {}
@@ -89,4 +92,6 @@ def has_ext_modules(self):
8992
],
9093
license='Apache 2.0',
9194
keywords='tensorflow protobuf machine learning',
95+
long_description=_LONG_DESCRIPTION,
96+
long_description_content_type='text/markdown',
9297
cmdclass={'install': _InstallPlatlib})

0 commit comments

Comments
 (0)