Read version.txt (#1631)

* read version from version.txt

* reordered lines
This commit is contained in:
Abubakar Abid 2022-06-24 21:24:57 -07:00 committed by GitHub
parent 1e6ceb9543
commit 0f44cf8012
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -6,15 +6,18 @@ from pathlib import Path
import re
this_directory = Path(__file__).parent
long_description = (this_directory / "README.md").read_text(encoding='utf8')
long_description = (this_directory / "README.md").read_text(encoding='utf8')
# Replace relative paths to images with absolute paths
long_description = re.sub("website/homepage/", "https://raw.githubusercontent.com/gradio-app/gradio/main/website/homepage/", long_description)
long_description = re.sub(r"demo/([\S]*.gif)", r"https://raw.githubusercontent.com/gradio-app/gradio/main/demo/\g<1>", long_description)
version = (this_directory / "gradio" / "version.txt").read_text(
encoding='utf8').strip()
setup(
name="gradio",
version="3.0.13",
version=version,
include_package_data=True,
description="Python library for easily interacting with trained machine learning models",
long_description=long_description,