package-dev-tools 0.8.6__tar.gz → 0.8.8__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/PKG-INFO +4 -4
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/pyproject.toml +4 -4
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/actions/template_sync/merge.py +1 -1
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/utils/git.py +14 -25
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools.egg-info/PKG-INFO +4 -4
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools.egg-info/requires.txt +3 -3
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/LICENSE +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/README.md +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/bin/pre-commit/bump-version +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/bin/pre-commit/check-version +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/setup.cfg +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/__init__.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/actions/__init__.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/actions/instantiate_new_project/__init__.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/actions/instantiate_new_project/cleanup_readme.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/actions/instantiate_new_project/cleanup_workflows.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/actions/instantiate_new_project/instantiate_new_project.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/actions/instantiate_new_project/substitute_template_name/__init__.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/actions/instantiate_new_project/substitute_template_name/project.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/actions/instantiate_new_project/substitute_template_name/substitute_template_name.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/actions/template_sync/__init__.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/actions/template_sync/git.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/actions/template_sync/sync.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/actions/template_sync/trigger.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/__init__.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/check_coverage.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/check_shields.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/cleanup_readme.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/export_pre_commit_config.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/extract_info.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/instantiate_new_project.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/substitute_template_name.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/sync_template.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/trigger_template_sync.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/models/__init__.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/models/path.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/pre_commit/__init__.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/pre_commit/check_coverage.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/pre_commit/check_import.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/pre_commit/check_shields.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/pre_commit/expand_docstrings.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/pre_commit/export_config.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/py.typed +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/utils/__init__.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/utils/badge.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/utils/package.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/utils/python_versions.py +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools.egg-info/SOURCES.txt +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools.egg-info/dependency_links.txt +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools.egg-info/entry_points.txt +0 -0
- {package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools.egg-info/top_level.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: package-dev-tools
|
|
3
|
-
Version: 0.8.
|
|
3
|
+
Version: 0.8.8
|
|
4
4
|
Summary: CI/CD tools for Python packages
|
|
5
5
|
Author-email: Quinten Roets <qdr2104@columbia.edu>
|
|
6
6
|
License-Expression: MIT
|
|
@@ -8,7 +8,7 @@ Project-URL: Source Code, https://github.com/quintenroets/package-dev-tools
|
|
|
8
8
|
Requires-Python: >=3.11
|
|
9
9
|
Description-Content-Type: text/markdown
|
|
10
10
|
License-File: LICENSE
|
|
11
|
-
Requires-Dist: package-utils<1,>=0.
|
|
11
|
+
Requires-Dist: package-utils<1,>=0.9.0
|
|
12
12
|
Requires-Dist: packaging<27,>=23.2
|
|
13
13
|
Requires-Dist: powercli<1,>=0.4.0
|
|
14
14
|
Requires-Dist: pygithub<3,>=2.1.1
|
|
@@ -16,7 +16,7 @@ Requires-Dist: python-slugify<9,>=8.0.1
|
|
|
16
16
|
Requires-Dist: PyYaml<7,>=6.0.1
|
|
17
17
|
Requires-Dist: requests<3,>=2.31.0
|
|
18
18
|
Requires-Dist: simple-classproperty<5,>=4.0.2
|
|
19
|
-
Requires-Dist: superpathlib<3,>=2.0
|
|
19
|
+
Requires-Dist: superpathlib<3,>=2.1.0
|
|
20
20
|
Requires-Dist: autotyping<25,>=23.3.0
|
|
21
21
|
Requires-Dist: bump2version<2,>=1.0.1
|
|
22
22
|
Requires-Dist: coverage<8,>=7.4.0
|
|
@@ -28,7 +28,7 @@ Requires-Dist: ruff<0.17,>=0.16.3
|
|
|
28
28
|
Provides-Extra: dev
|
|
29
29
|
Requires-Dist: hypothesis<7,>=6.91.0; extra == "dev"
|
|
30
30
|
Requires-Dist: package-dev-utils<1,>=0.1.6; extra == "dev"
|
|
31
|
-
Requires-Dist: package-utils[context]<1,>=0.
|
|
31
|
+
Requires-Dist: package-utils[context]<1,>=0.9.0; extra == "dev"
|
|
32
32
|
Requires-Dist: types-requests<3,>=2.31.0.10; extra == "dev"
|
|
33
33
|
Dynamic: license-file
|
|
34
34
|
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "package-dev-tools"
|
|
3
|
-
version = "0.8.
|
|
3
|
+
version = "0.8.8"
|
|
4
4
|
description = "CI/CD tools for Python packages"
|
|
5
5
|
authors = [{name = "Quinten Roets", email = "qdr2104@columbia.edu"}]
|
|
6
6
|
license = "MIT"
|
|
7
7
|
readme = "README.md"
|
|
8
8
|
requires-python = ">=3.11"
|
|
9
9
|
dependencies = [
|
|
10
|
-
"package-utils >=0.
|
|
10
|
+
"package-utils >=0.9.0, <1",
|
|
11
11
|
"packaging >=23.2, <27",
|
|
12
12
|
"powercli >=0.4.0, <1",
|
|
13
13
|
"pygithub >=2.1.1, <3",
|
|
@@ -15,7 +15,7 @@ dependencies = [
|
|
|
15
15
|
"PyYaml >=6.0.1, <7",
|
|
16
16
|
"requests >=2.31.0, <3",
|
|
17
17
|
"simple-classproperty >=4.0.2, <5",
|
|
18
|
-
"superpathlib >=2.0
|
|
18
|
+
"superpathlib >=2.1.0, <3",
|
|
19
19
|
|
|
20
20
|
# pre-commit binaries
|
|
21
21
|
"autotyping >=23.3.0, <25",
|
|
@@ -34,7 +34,7 @@ dependencies = [
|
|
|
34
34
|
dev = [
|
|
35
35
|
"hypothesis >=6.91.0, <7",
|
|
36
36
|
"package-dev-utils >=0.1.6, <1",
|
|
37
|
-
"package-utils[context] >=0.
|
|
37
|
+
"package-utils[context] >=0.9.0, <1",
|
|
38
38
|
|
|
39
39
|
# mypy
|
|
40
40
|
"types-requests >=2.31.0.10, <3",
|
|
@@ -59,7 +59,7 @@ class Merger: # pragma: nocover
|
|
|
59
59
|
for relative_file in self.generate_project_files():
|
|
60
60
|
file = source / relative_file
|
|
61
61
|
destination_file = destination / relative_file
|
|
62
|
-
file.
|
|
62
|
+
destination_file.byte_content = file.byte_content if file.exists() else b""
|
|
63
63
|
|
|
64
64
|
def generate_project_files(self) -> Iterator[Path]:
|
|
65
65
|
path = models.Path(self.repository_directory)
|
|
@@ -1,29 +1,17 @@
|
|
|
1
1
|
import os
|
|
2
2
|
import shlex
|
|
3
3
|
import shutil
|
|
4
|
-
import subprocess
|
|
5
4
|
from collections.abc import Iterator
|
|
6
5
|
from dataclasses import dataclass, field
|
|
7
6
|
from functools import cache
|
|
8
7
|
from typing import Any
|
|
9
8
|
|
|
10
|
-
|
|
11
|
-
from cli.commands.
|
|
9
|
+
import cli
|
|
10
|
+
from cli.commands.commands import CommandItem
|
|
12
11
|
|
|
13
12
|
from package_dev_tools.models import Path
|
|
14
13
|
|
|
15
14
|
|
|
16
|
-
@cache
|
|
17
|
-
def resolve_git_binary() -> str:
|
|
18
|
-
paths = (
|
|
19
|
-
path
|
|
20
|
-
for p in os.get_exec_path()
|
|
21
|
-
if (path := shutil.which("git", path=str(p)))
|
|
22
|
-
and not path.startswith(str(Path.home()))
|
|
23
|
-
)
|
|
24
|
-
return shlex.quote(next(paths, shutil.which("git") or "git"))
|
|
25
|
-
|
|
26
|
-
|
|
27
15
|
@dataclass
|
|
28
16
|
class GitInterface:
|
|
29
17
|
path: Path = field(default_factory=Path.cwd)
|
|
@@ -48,20 +36,21 @@ class GitInterface:
|
|
|
48
36
|
return (Path(relative_path) for relative_path in output.splitlines())
|
|
49
37
|
|
|
50
38
|
def capture_output(self, *args: CommandItem, **kwargs: Any) -> str:
|
|
51
|
-
return self.create_runner(*args, **kwargs).capture_output()
|
|
52
|
-
|
|
53
|
-
def run(
|
|
54
|
-
self,
|
|
55
|
-
*args: CommandItem,
|
|
56
|
-
check: bool = True,
|
|
57
|
-
) -> subprocess.CompletedProcess[str]: # pragma: nocover
|
|
58
|
-
return self.create_runner(*args, check=check).run()
|
|
59
|
-
|
|
60
|
-
def create_runner(self, *args: CommandItem, **kwargs: Any) -> Runner[str]:
|
|
61
39
|
git_args = f"{resolve_git_binary()} {args[0]}", *args[1:]
|
|
62
|
-
return
|
|
40
|
+
return cli.capture_output(*git_args, cwd=self.path, **kwargs)
|
|
63
41
|
|
|
64
42
|
def configure(self) -> None:
|
|
65
43
|
git_configuration = {"name": self.git_name, "email": self.git_email}
|
|
66
44
|
for attribute, value in git_configuration.items():
|
|
67
45
|
self.capture_output(f"config user.{attribute} {value}")
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
@cache
|
|
49
|
+
def resolve_git_binary() -> str:
|
|
50
|
+
paths = (
|
|
51
|
+
path
|
|
52
|
+
for p in os.get_exec_path()
|
|
53
|
+
if (path := shutil.which("git", path=str(p)))
|
|
54
|
+
and not path.startswith(str(Path.home()))
|
|
55
|
+
)
|
|
56
|
+
return shlex.quote(next(paths, shutil.which("git") or "git"))
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: package-dev-tools
|
|
3
|
-
Version: 0.8.
|
|
3
|
+
Version: 0.8.8
|
|
4
4
|
Summary: CI/CD tools for Python packages
|
|
5
5
|
Author-email: Quinten Roets <qdr2104@columbia.edu>
|
|
6
6
|
License-Expression: MIT
|
|
@@ -8,7 +8,7 @@ Project-URL: Source Code, https://github.com/quintenroets/package-dev-tools
|
|
|
8
8
|
Requires-Python: >=3.11
|
|
9
9
|
Description-Content-Type: text/markdown
|
|
10
10
|
License-File: LICENSE
|
|
11
|
-
Requires-Dist: package-utils<1,>=0.
|
|
11
|
+
Requires-Dist: package-utils<1,>=0.9.0
|
|
12
12
|
Requires-Dist: packaging<27,>=23.2
|
|
13
13
|
Requires-Dist: powercli<1,>=0.4.0
|
|
14
14
|
Requires-Dist: pygithub<3,>=2.1.1
|
|
@@ -16,7 +16,7 @@ Requires-Dist: python-slugify<9,>=8.0.1
|
|
|
16
16
|
Requires-Dist: PyYaml<7,>=6.0.1
|
|
17
17
|
Requires-Dist: requests<3,>=2.31.0
|
|
18
18
|
Requires-Dist: simple-classproperty<5,>=4.0.2
|
|
19
|
-
Requires-Dist: superpathlib<3,>=2.0
|
|
19
|
+
Requires-Dist: superpathlib<3,>=2.1.0
|
|
20
20
|
Requires-Dist: autotyping<25,>=23.3.0
|
|
21
21
|
Requires-Dist: bump2version<2,>=1.0.1
|
|
22
22
|
Requires-Dist: coverage<8,>=7.4.0
|
|
@@ -28,7 +28,7 @@ Requires-Dist: ruff<0.17,>=0.16.3
|
|
|
28
28
|
Provides-Extra: dev
|
|
29
29
|
Requires-Dist: hypothesis<7,>=6.91.0; extra == "dev"
|
|
30
30
|
Requires-Dist: package-dev-utils<1,>=0.1.6; extra == "dev"
|
|
31
|
-
Requires-Dist: package-utils[context]<1,>=0.
|
|
31
|
+
Requires-Dist: package-utils[context]<1,>=0.9.0; extra == "dev"
|
|
32
32
|
Requires-Dist: types-requests<3,>=2.31.0.10; extra == "dev"
|
|
33
33
|
Dynamic: license-file
|
|
34
34
|
|
{package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools.egg-info/requires.txt
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
package-utils<1,>=0.
|
|
1
|
+
package-utils<1,>=0.9.0
|
|
2
2
|
packaging<27,>=23.2
|
|
3
3
|
powercli<1,>=0.4.0
|
|
4
4
|
pygithub<3,>=2.1.1
|
|
@@ -6,7 +6,7 @@ python-slugify<9,>=8.0.1
|
|
|
6
6
|
PyYaml<7,>=6.0.1
|
|
7
7
|
requests<3,>=2.31.0
|
|
8
8
|
simple-classproperty<5,>=4.0.2
|
|
9
|
-
superpathlib<3,>=2.0
|
|
9
|
+
superpathlib<3,>=2.1.0
|
|
10
10
|
autotyping<25,>=23.3.0
|
|
11
11
|
bump2version<2,>=1.0.1
|
|
12
12
|
coverage<8,>=7.4.0
|
|
@@ -19,5 +19,5 @@ ruff<0.17,>=0.16.3
|
|
|
19
19
|
[dev]
|
|
20
20
|
hypothesis<7,>=6.91.0
|
|
21
21
|
package-dev-utils<1,>=0.1.6
|
|
22
|
-
package-utils[context]<1,>=0.
|
|
22
|
+
package-utils[context]<1,>=0.9.0
|
|
23
23
|
types-requests<3,>=2.31.0.10
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/actions/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/check_coverage.py
RENAMED
|
File without changes
|
{package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/check_shields.py
RENAMED
|
File without changes
|
{package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/cleanup_readme.py
RENAMED
|
File without changes
|
|
File without changes
|
{package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/extract_info.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/cli/sync_template.py
RENAMED
|
File without changes
|
|
File without changes
|
{package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/models/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/pre_commit/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/pre_commit/check_import.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools/utils/python_versions.py
RENAMED
|
File without changes
|
{package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools.egg-info/SOURCES.txt
RENAMED
|
File without changes
|
|
File without changes
|
{package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools.egg-info/entry_points.txt
RENAMED
|
File without changes
|
{package_dev_tools-0.8.6 → package_dev_tools-0.8.8}/src/package_dev_tools.egg-info/top_level.txt
RENAMED
|
File without changes
|