Skip to content

Commit

Permalink
Merge pull request #123 from monocongo/issue_119_src_dir_pypa_sample
Browse files Browse the repository at this point in the history
Now with src directory support, closer to sample PyPI sample project
  • Loading branch information
monocongo authored Jan 28, 2020
2 parents 2df0cdd + cb95eef commit f0917bc
Show file tree
Hide file tree
Showing 22 changed files with 54 additions and 11 deletions.
10 changes: 10 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
include pyproject.toml

# include the README
include *.md

# include the license file
include LICENSE.txt

# include all files under the src directory
graft src
2 changes: 0 additions & 2 deletions cvdata/__init__.py

This file was deleted.

5 changes: 5 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[build-system]
# These are the assumed default build requirements from pip:
# https://pip.pypa.io/en/stable/reference/pip/#pep-517-and-518-support
requires = ["setuptools>=40.8.0", "wheel"]
build-backend = "setuptools.build_meta"
13 changes: 13 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[metadata]
# This includes the license file(s) in the wheel.
# https://wheel.readthedocs.io/en/stable/user_guide.html#including-license-files-in-the-generated-wheel-file
license_files = LICENSE.txt

[bdist_wheel]
# This flag says to generate wheels that support both Python 2 and Python
# 3. If your code will not run unchanged on both Python 2 and 3, you will
# need to generate separate wheels for each Python version that you
# support. Removing this line (or setting universal to 0) will prevent
# bdist_wheel from trying to make a universal wheel. For more see:
# https://packaging.python.org/guides/distributing-packages-using-setuptools/#wheels
universal=1
13 changes: 7 additions & 6 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import os
import setuptools
from setuptools import setup, find_packages

parent_dir = os.path.dirname(os.path.realpath(__file__))

with open(f"{parent_dir}/README.md", "r") as readme_file:
long_description = readme_file.read()

setuptools.setup(
setup(
name="cvdata",
version="0.0.6",
author="James Adams",
Expand All @@ -15,17 +15,18 @@
long_description=long_description,
long_description_content_type="text/markdown",
url="https://github.com/monocongo/cvdata",
python_requires="==3.7.*",
packages=[
"cvdata",
],
python_requires=">=3.6,<3.8",
provides=[
"cvdata",
],
classifiers=[
"License :: OSI Approved :: MIT License",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Operating System :: OS Independent",
],
package_dir={'': 'src'},
packages=find_packages(where='src'),
install_requires=[
"boto3",
"contextlib2",
Expand Down
Empty file added src/cvdata/__init__.py
Empty file.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
22 changes: 19 additions & 3 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,8 +1,24 @@
[tox]
envlist = py37
envlist = py{36,37,},coverage

# Define the minimal tox version required to run; if the host
# tox is less than this the tool with create an environment and
# provision it with a tox that satisfies it under provision_tox_env.
# At least this version is needed for PEP 517/518 support.
minversion = 3.3.0

# Activate isolated build environment. tox will use a virtual environment
# to build a source distribution from the source tree. For build tools and
# arguments use the pyproject.toml file as specified in PEP-517 and PEP-518.
isolated_build = true

[testenv]
deps = opencv-python
deps =
coverage
opencv-python
pytest
scikit-image
commands = pytest
commands =
python setup.py check -m -s
py.test tests {posargs}

0 comments on commit f0917bc

Please sign in to comment.