From 147b9147826fe4752fe8b1edfd91d6f43e952eaa Mon Sep 17 00:00:00 2001 From: Pradyun Gedam Date: Thu, 1 Apr 2021 23:25:09 +0100 Subject: [PATCH] Get rid of the tools/automation folder It was an unnecessary level added to the folder hierarchy. --- .gitattributes | 2 +- noxfile.py | 2 +- pyproject.toml | 4 ++-- tools/{automation => }/news/template.rst | 0 tools/{automation => }/release/__init__.py | 2 +- tools/{automation => }/release/check_version.py | 0 tools/{automation => }/vendoring/patches/appdirs.patch | 0 tools/{automation => }/vendoring/patches/certifi.patch | 0 tools/{automation => }/vendoring/patches/requests.patch | 0 9 files changed, 5 insertions(+), 5 deletions(-) rename tools/{automation => }/news/template.rst (100%) rename tools/{automation => }/release/__init__.py (99%) rename tools/{automation => }/release/check_version.py (100%) rename tools/{automation => }/vendoring/patches/appdirs.patch (100%) rename tools/{automation => }/vendoring/patches/certifi.patch (100%) rename tools/{automation => }/vendoring/patches/requests.patch (100%) diff --git a/.gitattributes b/.gitattributes index 7b547a58c..6a0fc6943 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,4 +1,4 @@ # Patches must have Unix-style line endings, even on Windows -tools/automation/vendoring/patches/* eol=lf +tools/vendoring/patches/* eol=lf # The CA Bundle should always use Unix-style line endings, even on Windows src/pip/_vendor/certifi/*.pem eol=lf diff --git a/noxfile.py b/noxfile.py index eab265034..d9e344543 100644 --- a/noxfile.py +++ b/noxfile.py @@ -12,7 +12,7 @@ import nox # fmt: off sys.path.append(".") -from tools.automation import release # isort:skip # noqa +from tools import release # isort:skip # noqa sys.path.pop() # fmt: on diff --git a/pyproject.toml b/pyproject.toml index 281594b21..b7e20bbe2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -9,7 +9,7 @@ filename = "NEWS.rst" directory = "news/" title_format = "{version} ({project_date})" issue_format = "`#{issue} `_" -template = "tools/automation/news/template.rst" +template = "tools/news/template.rst" type = [ { name = "Process", directory = "process", showcontent = true }, { name = "Deprecations and Removals", directory = "removal", showcontent = true }, @@ -26,7 +26,7 @@ requirements = "src/pip/_vendor/vendor.txt" namespace = "pip._vendor" protected-files = ["__init__.py", "README.rst", "vendor.txt"] -patches-dir = "tools/automation/vendoring/patches" +patches-dir = "tools/vendoring/patches" [tool.vendoring.transformations] substitute = [ diff --git a/tools/automation/news/template.rst b/tools/news/template.rst similarity index 100% rename from tools/automation/news/template.rst rename to tools/news/template.rst diff --git a/tools/automation/release/__init__.py b/tools/release/__init__.py similarity index 99% rename from tools/automation/release/__init__.py rename to tools/release/__init__.py index a10ccd1f5..ec3a0eeb7 100644 --- a/tools/automation/release/__init__.py +++ b/tools/release/__init__.py @@ -28,7 +28,7 @@ def get_version_from_arguments(session: Session) -> Optional[str]: cmd = [ # https://github.com/theacodes/nox/pull/378 os.path.join(session.bin, "python"), # type: ignore - "tools/automation/release/check_version.py", + "tools/release/check_version.py", version ] not_ok = subprocess.run(cmd).returncode diff --git a/tools/automation/release/check_version.py b/tools/release/check_version.py similarity index 100% rename from tools/automation/release/check_version.py rename to tools/release/check_version.py diff --git a/tools/automation/vendoring/patches/appdirs.patch b/tools/vendoring/patches/appdirs.patch similarity index 100% rename from tools/automation/vendoring/patches/appdirs.patch rename to tools/vendoring/patches/appdirs.patch diff --git a/tools/automation/vendoring/patches/certifi.patch b/tools/vendoring/patches/certifi.patch similarity index 100% rename from tools/automation/vendoring/patches/certifi.patch rename to tools/vendoring/patches/certifi.patch diff --git a/tools/automation/vendoring/patches/requests.patch b/tools/vendoring/patches/requests.patch similarity index 100% rename from tools/automation/vendoring/patches/requests.patch rename to tools/vendoring/patches/requests.patch