simple-git-versioning 0.3.7__tar.gz → 0.3.14__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.
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/.gitlab-ci.yml +1 -1
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/PKG-INFO +2 -2
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/pyproject.toml +4 -4
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/tests/unit/__init__.py +2 -4
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/tests/unit/test_project.py +24 -0
- simple_git_versioning-0.3.14/uv.lock +1664 -0
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/versioning/__init__.py +0 -1
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/versioning/hatchling.py +12 -4
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/versioning/pep440.py +10 -4
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/versioning/project.py +11 -0
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/versioning/semver2.py +21 -4
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/versioning/setuptools.py +9 -1
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/versioning/version.py +2 -4
- simple_git_versioning-0.3.7/uv.lock +0 -2048
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/.gitignore +0 -0
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/.pre-commit-config.yaml +0 -0
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/LICENSE +0 -0
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/README.md +0 -0
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/tests/__init__.py +0 -0
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/tests/unit/test_cli.py +0 -0
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/tests/unit/test_pep440.py +0 -0
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/tests/unit/test_semver2.py +0 -0
- {simple_git_versioning-0.3.7 → simple_git_versioning-0.3.14}/tests/unit/test_version.py +0 -0
|
@@ -96,7 +96,7 @@ tag:
|
|
|
96
96
|
- git config user.email "$GITLAB_USER_EMAIL"
|
|
97
97
|
- git config user.name "$GITLAB_USER_NAME"
|
|
98
98
|
- git tag -a "$version" -m "version $version"
|
|
99
|
-
- git push --tag
|
|
99
|
+
- git push --tag
|
|
100
100
|
|
|
101
101
|
publish:
|
|
102
102
|
stage: release
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: simple-git-versioning
|
|
3
|
-
Version: 0.3.
|
|
3
|
+
Version: 0.3.14
|
|
4
4
|
Summary: Thinly scoped and opinionated tool that computes a version number from git tags and trailers
|
|
5
5
|
Project-URL: homepage, https://gitlab.com/ypsah/simple-git-versioning
|
|
6
6
|
Project-URL: repository, https://gitlab.com/ypsah/simple-git-versioning
|
|
@@ -22,7 +22,7 @@ Classifier: Programming Language :: Python :: 3.10
|
|
|
22
22
|
Classifier: Programming Language :: Python :: 3.11
|
|
23
23
|
Classifier: Programming Language :: Python :: 3.12
|
|
24
24
|
Classifier: Programming Language :: Python :: 3.13
|
|
25
|
-
Requires-Python:
|
|
25
|
+
Requires-Python: >=3.10
|
|
26
26
|
Requires-Dist: icontract
|
|
27
27
|
Requires-Dist: sh<3,>=2
|
|
28
28
|
Requires-Dist: toml; python_version < '3.11'
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
name = "simple-git-versioning"
|
|
3
3
|
description = "Thinly scoped and opinionated tool that computes a version number from git tags and trailers"
|
|
4
4
|
license = { text = "MIT" }
|
|
5
|
-
requires-python = ">=3.
|
|
5
|
+
requires-python = ">=3.10"
|
|
6
6
|
authors = [
|
|
7
7
|
{ name = "Quentin Bouget", email = "ypsah@devyard.org" },
|
|
8
8
|
]
|
|
@@ -43,13 +43,13 @@ poetry = ["cleo", "poetry"]
|
|
|
43
43
|
|
|
44
44
|
[dependency-groups]
|
|
45
45
|
dev = [
|
|
46
|
-
"black",
|
|
46
|
+
"black==26.1.0",
|
|
47
47
|
"hypothesis",
|
|
48
|
-
"isort",
|
|
48
|
+
"isort==7.0.0",
|
|
49
49
|
"pre-commit",
|
|
50
50
|
"pytest",
|
|
51
51
|
"pytest-cov",
|
|
52
|
-
"ruff",
|
|
52
|
+
"ruff==0.15.0",
|
|
53
53
|
]
|
|
54
54
|
|
|
55
55
|
[project.urls]
|
|
@@ -31,8 +31,7 @@ def _format_commit_message(message: str) -> str:
|
|
|
31
31
|
|
|
32
32
|
|
|
33
33
|
_DEFAULT_COMMIT_TITLE = "lorem ipsum dolor sit amet"
|
|
34
|
-
_DEFAULT_COMMIT_MESSAGE = _format_commit_message(
|
|
35
|
-
"""
|
|
34
|
+
_DEFAULT_COMMIT_MESSAGE = _format_commit_message("""
|
|
36
35
|
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod
|
|
37
36
|
tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim
|
|
38
37
|
veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea
|
|
@@ -40,8 +39,7 @@ _DEFAULT_COMMIT_MESSAGE = _format_commit_message(
|
|
|
40
39
|
velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint
|
|
41
40
|
occaecat cupidatat non proident, sunt in culpa qui officia deserunt
|
|
42
41
|
mollit anim id est laborum.
|
|
43
|
-
"""
|
|
44
|
-
)
|
|
42
|
+
""")
|
|
45
43
|
|
|
46
44
|
|
|
47
45
|
@dataclass(frozen=True, kw_only=True)
|
|
@@ -20,6 +20,7 @@ from versioning.project import (
|
|
|
20
20
|
InvalidVersionBumpTrailer,
|
|
21
21
|
NotAGitWorkTree,
|
|
22
22
|
NoVersion,
|
|
23
|
+
NoVersionInShallowRepository,
|
|
23
24
|
Project,
|
|
24
25
|
)
|
|
25
26
|
from versioning.semver2 import Project as SemVer2Project
|
|
@@ -124,6 +125,20 @@ def test_project_contextmanager(implementation: type[Project]):
|
|
|
124
125
|
assert os.getcwd() == tmpdir
|
|
125
126
|
|
|
126
127
|
|
|
128
|
+
@across_implementations()
|
|
129
|
+
def test_project_is_not_shallow(implementation: type[Project]):
|
|
130
|
+
with project(implementation, INIT) as proj:
|
|
131
|
+
assert not proj.is_shallow()
|
|
132
|
+
|
|
133
|
+
|
|
134
|
+
@across_implementations()
|
|
135
|
+
def test_project_is_shallow(implementation: type[Project]):
|
|
136
|
+
with project(implementation, INIT, PATCH) as _proj, TemporaryDirectory() as tmpdir:
|
|
137
|
+
git("clone", "--depth", "1", f"file://{_proj.path}", tmpdir)
|
|
138
|
+
with implementation(path=Path(tmpdir)) as proj:
|
|
139
|
+
assert proj.is_shallow()
|
|
140
|
+
|
|
141
|
+
|
|
127
142
|
@across_implementations()
|
|
128
143
|
def test_project_canonical(implementation: type[Project]):
|
|
129
144
|
with project(implementation, INIT) as proj:
|
|
@@ -431,3 +446,12 @@ def test_project_release_invalid_bump(implementation: type[Project]):
|
|
|
431
446
|
with pytest.raises(InvalidVersionBumpTrailer) as excinfo:
|
|
432
447
|
proj.release("HEAD")
|
|
433
448
|
assert excinfo.value.bump == "invalid"
|
|
449
|
+
|
|
450
|
+
|
|
451
|
+
@across_implementations()
|
|
452
|
+
def test_project_release_no_version_shallow(implementation: type[Project]):
|
|
453
|
+
with project(implementation, INIT, Release(), PATCH) as _proj, TemporaryDirectory() as tmpdir:
|
|
454
|
+
git("clone", "--depth", "1", f"file://{_proj.path}", tmpdir)
|
|
455
|
+
with implementation(path=Path(tmpdir)) as proj:
|
|
456
|
+
with pytest.raises(NoVersionInShallowRepository):
|
|
457
|
+
proj.release("HEAD")
|