dycw-pre-commit-hooks 0.13.7__py3-none-any.whl → 0.13.9__py3-none-any.whl
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.
Potentially problematic release.
This version of dycw-pre-commit-hooks might be problematic. Click here for more details.
- {dycw_pre_commit_hooks-0.13.7.dist-info → dycw_pre_commit_hooks-0.13.9.dist-info}/METADATA +4 -4
- {dycw_pre_commit_hooks-0.13.7.dist-info → dycw_pre_commit_hooks-0.13.9.dist-info}/RECORD +7 -7
- pre_commit_hooks/__init__.py +1 -1
- pre_commit_hooks/common.py +1 -1
- pre_commit_hooks/tag_commits/__init__.py +9 -2
- {dycw_pre_commit_hooks-0.13.7.dist-info → dycw_pre_commit_hooks-0.13.9.dist-info}/WHEEL +0 -0
- {dycw_pre_commit_hooks-0.13.7.dist-info → dycw_pre_commit_hooks-0.13.9.dist-info}/entry_points.txt +0 -0
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: dycw-pre-commit-hooks
|
|
3
|
-
Version: 0.13.
|
|
3
|
+
Version: 0.13.9
|
|
4
4
|
Author-email: Derek Wan <d.wan@icloud.com>
|
|
5
5
|
Requires-Python: >=3.12
|
|
6
|
-
Requires-Dist: click<8.
|
|
7
|
-
Requires-Dist: dycw-utilities<0.
|
|
6
|
+
Requires-Dist: click<8.4,>=8.3.0
|
|
7
|
+
Requires-Dist: dycw-utilities<0.169,>=0.168.8
|
|
8
8
|
Requires-Dist: gitpython<3.2,>=3.1.45
|
|
9
|
-
Requires-Dist: libcst<1.9,>=1.8.
|
|
9
|
+
Requires-Dist: libcst<1.9,>=1.8.5
|
|
10
10
|
Requires-Dist: loguru<0.8,>=0.7.3
|
|
11
11
|
Requires-Dist: more-itertools<10.9,>=10.8.0
|
|
12
12
|
Requires-Dist: orjson<3.12,>=3.11.3
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
pre_commit_hooks/__init__.py,sha256=
|
|
2
|
-
pre_commit_hooks/common.py,sha256=
|
|
1
|
+
pre_commit_hooks/__init__.py,sha256=7Ekge_xOwFqh5sKr0EdAIN7q3RO-uTyjxHz1A4PS0Qk,59
|
|
2
|
+
pre_commit_hooks/common.py,sha256=ZClypoURLwURWBORPrsEeYYDwWNbRCTVjUwZMIYHNZE,4502
|
|
3
3
|
pre_commit_hooks/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
4
4
|
pre_commit_hooks/check_submodules_updated/__init__.py,sha256=j-NrV-_l_47meqcMz-QxIUOyWloI3coQXXDKg1Jhwgs,900
|
|
5
5
|
pre_commit_hooks/check_submodules_updated/__main__.py,sha256=_-uQnuopAJQiHgoSLRMekYrVBbO9-rjP2s9cCC0u3jQ,161
|
|
@@ -15,9 +15,9 @@ pre_commit_hooks/replace_sequence_str/__init__.py,sha256=IUyhpYh89PF9fX65zYe5Pt3
|
|
|
15
15
|
pre_commit_hooks/replace_sequence_str/__main__.py,sha256=B1dxOxngV4vUVnDVrXSywiySOs1P_zF30_4ZMRsOSaY,157
|
|
16
16
|
pre_commit_hooks/run_bump_my_version/__init__.py,sha256=FhvLQEEoFm21_2c_12Loy_lc8gfNv2wtwAOrdtBEqrs,2028
|
|
17
17
|
pre_commit_hooks/run_bump_my_version/__main__.py,sha256=w2V3y61jrSau-zxjl8ciHtWPlJQwXbYxNJ2tGYVyI4s,156
|
|
18
|
-
pre_commit_hooks/tag_commits/__init__.py,sha256=
|
|
18
|
+
pre_commit_hooks/tag_commits/__init__.py,sha256=Ez1YahjRHTs_PNh82DRnGo3vebZ2BPrvUTNad6YEms4,3436
|
|
19
19
|
pre_commit_hooks/tag_commits/__main__.py,sha256=qefgYw7LWbvmzZS45-ym6olS4cHqw1Emw2wlqZBXN_o,148
|
|
20
|
-
dycw_pre_commit_hooks-0.13.
|
|
21
|
-
dycw_pre_commit_hooks-0.13.
|
|
22
|
-
dycw_pre_commit_hooks-0.13.
|
|
23
|
-
dycw_pre_commit_hooks-0.13.
|
|
20
|
+
dycw_pre_commit_hooks-0.13.9.dist-info/METADATA,sha256=uqgOWEOhCSt6gQbnOcgrt8WXQFBD1t-YZ98rfM368lk,1177
|
|
21
|
+
dycw_pre_commit_hooks-0.13.9.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
22
|
+
dycw_pre_commit_hooks-0.13.9.dist-info/entry_points.txt,sha256=mpEGGgi0HF_ukOSex2k3_DnActXAj3rMtHv5uwO2sMI,450
|
|
23
|
+
dycw_pre_commit_hooks-0.13.9.dist-info/RECORD,,
|
pre_commit_hooks/__init__.py
CHANGED
pre_commit_hooks/common.py
CHANGED
|
@@ -102,7 +102,7 @@ def throttled_run[**P](
|
|
|
102
102
|
) -> bool:
|
|
103
103
|
"""Throttled run."""
|
|
104
104
|
hash_ = md5_hash(get_repo_root())
|
|
105
|
-
path = xdg_cache_home().joinpath(name, hash_)
|
|
105
|
+
path = xdg_cache_home().joinpath("pre-commit-hooks", name, hash_)
|
|
106
106
|
if run_every is not None:
|
|
107
107
|
min_date_time = get_now_local() - run_every
|
|
108
108
|
try:
|
|
@@ -99,12 +99,19 @@ def _tag_commit(
|
|
|
99
99
|
except GetVersionError as error:
|
|
100
100
|
msg = f"Failed to tag {desc}; error getting veresion: {error.args[0]}"
|
|
101
101
|
raise TagCommitsError(msg) from None
|
|
102
|
+
str_ver = str(version)
|
|
102
103
|
try:
|
|
103
|
-
|
|
104
|
+
existing = repo.tags[str_ver]
|
|
105
|
+
except KeyError:
|
|
106
|
+
pass
|
|
107
|
+
else:
|
|
108
|
+
repo.delete_tag(existing)
|
|
109
|
+
try:
|
|
110
|
+
tag = repo.create_tag(str_ver, ref=sha)
|
|
104
111
|
except GitCommandError as error:
|
|
105
112
|
msg = f"Failed to tag {desc}; error creating tag: {error.stderr.strip()}"
|
|
106
113
|
raise TagCommitsError(msg) from None
|
|
107
|
-
logger.info(f"Tagging {desc} as {
|
|
114
|
+
logger.info(f"Tagging {desc} as {str_ver!r}...")
|
|
108
115
|
_ = repo.remotes.origin.push(f"refs/tags/{tag.name}")
|
|
109
116
|
return True
|
|
110
117
|
|
|
File without changes
|
{dycw_pre_commit_hooks-0.13.7.dist-info → dycw_pre_commit_hooks-0.13.9.dist-info}/entry_points.txt
RENAMED
|
File without changes
|