From f47ffe20b6462fafd478e726ee41b65936434b65 Mon Sep 17 00:00:00 2001 From: Michael Droettboom Date: Tue, 30 May 2023 12:07:48 -0400 Subject: [PATCH] Only run dependabot the "main" requirements.txt You can't exclude directories for dependabot, only exclude them, so by moving the main requirements.txt to a directory that doesn't include all of the benchmarks' requirements.txt beneath it, we can limit dependabot to just that one file. --- .github/dependabot.yml | 4 ++++ MANIFEST.in | 2 +- doc/changelog.rst | 3 +++ pyperformance/{data-files => requirements}/requirements.txt | 2 +- pyperformance/venv.py | 4 +++- requirements.txt | 2 +- 6 files changed, 13 insertions(+), 4 deletions(-) create mode 100644 .github/dependabot.yml rename pyperformance/{data-files => requirements}/requirements.txt (73%) diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 00000000..13c177fa --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,4 @@ +version: 2 +updates: + - package-ecosystem: "pip" + directory: "/pyperformance/requirements" diff --git a/MANIFEST.in b/MANIFEST.in index 31a4281d..f41e2b99 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -10,7 +10,7 @@ include doc/*.rst doc/images/*.png doc/images/*.jpg include doc/conf.py doc/Makefile doc/make.bat include pyperformance/*.py -include pyperformance/data-files/requirements.txt +include pyperformance/requirements/requirements.txt include pyperformance/data-files/benchmarks/MANIFEST include pyperformance/data-files/benchmarks/bm_*/*.toml include pyperformance/data-files/benchmarks/bm_*/*.py diff --git a/doc/changelog.rst b/doc/changelog.rst index bcabdb9c..ab9225f2 100644 --- a/doc/changelog.rst +++ b/doc/changelog.rst @@ -1,6 +1,9 @@ Changelog ========= +* Move the main requirements.txt file to pyperformance/requirements + so that dependabot can only run on that one file. + Version 1.0.7 (2023-04-22) ------------- diff --git a/pyperformance/data-files/requirements.txt b/pyperformance/requirements/requirements.txt similarity index 73% rename from pyperformance/data-files/requirements.txt rename to pyperformance/requirements/requirements.txt index 4da6b34e..988c67b1 100644 --- a/pyperformance/data-files/requirements.txt +++ b/pyperformance/requirements/requirements.txt @@ -2,7 +2,7 @@ # This file is autogenerated by pip-compile with Python 3.11 # by the following command: # -# pip-compile --output-file=pyperformance/data-files/requirements.txt requirements.in +# pip-compile --output-file=pyperformance/requirements/requirements.txt requirements.in # packaging==23.1 # via -r requirements.in diff --git a/pyperformance/venv.py b/pyperformance/venv.py index e148c2d2..17bd1bee 100644 --- a/pyperformance/venv.py +++ b/pyperformance/venv.py @@ -6,7 +6,9 @@ from . import _utils, _pip, _venv -REQUIREMENTS_FILE = os.path.join(pyperformance.DATA_DIR, 'requirements.txt') +REQUIREMENTS_FILE = os.path.join( + os.path.dirname(__file__), 'requirements', 'requirements.txt' +) PYPERF_OPTIONAL = ['psutil'] diff --git a/requirements.txt b/requirements.txt index 4ce56a00..b340e549 120000 --- a/requirements.txt +++ b/requirements.txt @@ -1 +1 @@ -pyperformance/data-files/requirements.txt \ No newline at end of file +pyperformance/requirements/requirements.txt \ No newline at end of file