mirror of
https://github.com/jsvine/pdfplumber.git
synced 2026-08-29 08:34:23 +08:00
Prevent pip from installing the project on Python versions 3.5 and lower
This commit is contained in:
@@ -1,17 +1,19 @@
|
|||||||
import sys, os
|
import os
|
||||||
|
|
||||||
from setuptools import setup, find_packages
|
from setuptools import setup, find_packages
|
||||||
import subprocess
|
|
||||||
|
|
||||||
NAME = "pdfplumber"
|
NAME = "pdfplumber"
|
||||||
HERE = os.path.abspath(os.path.dirname(__file__))
|
HERE = os.path.abspath(os.path.dirname(__file__))
|
||||||
|
|
||||||
version_ns = {}
|
version_ns = {}
|
||||||
|
|
||||||
|
|
||||||
def _open(subpath):
|
def _open(subpath):
|
||||||
path = os.path.join(HERE, subpath)
|
path = os.path.join(HERE, subpath)
|
||||||
return open(path, encoding="utf-8")
|
return open(path, encoding="utf-8")
|
||||||
|
|
||||||
with _open(NAME + '/_version.py') as f:
|
|
||||||
|
with _open(NAME + "/_version.py") as f:
|
||||||
exec(f.read(), {}, version_ns)
|
exec(f.read(), {}, version_ns)
|
||||||
|
|
||||||
with _open("requirements.txt") as f:
|
with _open("requirements.txt") as f:
|
||||||
@@ -29,15 +31,18 @@ setup(
|
|||||||
author="Jeremy Singer-Vine",
|
author="Jeremy Singer-Vine",
|
||||||
author_email="jsvine@gmail.com",
|
author_email="jsvine@gmail.com",
|
||||||
description="Plumb a PDF for detailed information about each char, rectangle, and line.",
|
description="Plumb a PDF for detailed information about each char, rectangle, and line.",
|
||||||
long_description = long_description,
|
long_description=long_description,
|
||||||
long_description_content_type = "text/markdown",
|
long_description_content_type="text/markdown",
|
||||||
version=version_ns['__version__'],
|
version=version_ns["__version__"],
|
||||||
packages=find_packages(exclude=["test",]),
|
packages=find_packages(
|
||||||
tests_require = base_reqs + dev_reqs,
|
exclude=[
|
||||||
install_requires = base_reqs,
|
"test",
|
||||||
entry_points={
|
]
|
||||||
"console_scripts": [ "pdfplumber = pdfplumber.cli:main" ]
|
),
|
||||||
},
|
tests_require=base_reqs + dev_reqs,
|
||||||
|
python_requires=">=3.6",
|
||||||
|
install_requires=base_reqs,
|
||||||
|
entry_points={"console_scripts": ["pdfplumber = pdfplumber.cli:main"]},
|
||||||
classifiers=[
|
classifiers=[
|
||||||
"Intended Audience :: Developers",
|
"Intended Audience :: Developers",
|
||||||
"License :: OSI Approved :: MIT License",
|
"License :: OSI Approved :: MIT License",
|
||||||
|
|||||||
Reference in New Issue
Block a user