aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--pyproject.toml3
-rw-r--r--requirements.txt3
-rw-r--r--setup.cfg40
-rw-r--r--setup.py16
-rw-r--r--test-requirements.txt5
-rw-r--r--tox.ini4
6 files changed, 25 insertions, 46 deletions
diff --git a/pyproject.toml b/pyproject.toml
new file mode 100644
index 0000000..fed528d
--- /dev/null
+++ b/pyproject.toml
@@ -0,0 +1,3 @@
+[build-system]
+requires = ["setuptools"]
+build-backend = "setuptools.build_meta"
diff --git a/requirements.txt b/requirements.txt
deleted file mode 100644
index 94f02aa..0000000
--- a/requirements.txt
+++ /dev/null
@@ -1,3 +0,0 @@
-pip >= 10.0.1
-pygit2 >= 0.24.0
-flask
diff --git a/setup.cfg b/setup.cfg
index 4204b45..86d82ce 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -1,6 +1,8 @@
[metadata]
name = git-deps
-summary = automatically detect dependencies between git commits
+description = automatically detect dependencies between git commits
+long_description = file: README.md
+long_description_content_type = text/markdown
author = Adam Spiers
author_email = git@adamspiers.org
license = GPL-2+
@@ -19,7 +21,22 @@ classifier =
Topic :: Software Development :: Version Control
Topic :: Utilities
-[entry_points]
+[options]
+packages =
+ git_deps
+install_requires =
+ pygit2 >= 0.24.0
+ flask
+ sphinx
+ pyscaffold
+
+[options.extras_require]
+testing =
+ pytest-cov
+ pytest
+ flake8
+
+[options.entry_points]
console_scripts =
git-deps = git_deps.cli:run
gitfile-handler = git_deps.handler:run
@@ -30,24 +47,9 @@ scripts =
data_files =
share/git_deps = share/gitfile-handler.desktop
-[options]
-packages =
- git_deps
-
-[options.entry_points]
-console_scripts =
- git-deps = git_deps.cli:run
-
-[test]
-# py.test options when running `python setup.py test`
-addopts = tests
-
-[pytest]
-# Options for py.test:
-# Specify command line options as you would do when invoking py.test directly.
-# e.g. --cov-report html (or xml) for html/xml output or --junitxml junit.xml
-# in order to write a coverage file that can be read by Jenkins.
+[tool:pytest]
addopts =
+ tests
--cov git_deps --cov-report term-missing
--verbose
diff --git a/setup.py b/setup.py
index b1ec38f..1b86b71 100644
--- a/setup.py
+++ b/setup.py
@@ -11,19 +11,5 @@
import sys
from setuptools import setup
-
-def setup_package():
- needs_sphinx = {'build_sphinx', 'upload_docs'}.intersection(sys.argv)
- sphinx = ['sphinx'] if needs_sphinx else []
- setup(
- setup_requires=[
- 'pyscaffold',
- ] + sphinx,
- long_description='README.md',
- long_description_content_type="text/markdown",
- use_pyscaffold=True
- )
-
-
if __name__ == "__main__":
- setup_package()
+ setup()
diff --git a/test-requirements.txt b/test-requirements.txt
deleted file mode 100644
index 468f195..0000000
--- a/test-requirements.txt
+++ /dev/null
@@ -1,5 +0,0 @@
-# Add requirements only needed for your unittests and during development here.
-# They will be installed automatically when running `python setup.py test`.
-# ATTENTION: Don't remove pytest-cov and pytest as they are needed.
-pytest-cov
-pytest
diff --git a/tox.ini b/tox.ini
index 89f5094..1785f0f 100644
--- a/tox.ini
+++ b/tox.ini
@@ -11,14 +11,10 @@ usedevelop = True
changedir = tests
commands =
py.test {posargs}
-deps =
- pytest
- -r{toxinidir}/requirements.txt
[testenv:flake8]
skip_install = True
changedir = {toxinidir}
-deps = flake8
commands = flake8 setup.py git_deps tests
# Options for pytest