GitPython 3.1.54__py3-none-any.whl → 3.1.56__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.
git/__init__.py CHANGED
@@ -86,7 +86,7 @@ __all__ = [
86
86
  "to_hex_sha",
87
87
  ]
88
88
 
89
- __version__ = '3.1.54'
89
+ __version__ = '3.1.56'
90
90
 
91
91
  from typing import Any, List, Optional, Sequence, TYPE_CHECKING, Tuple, Union
92
92
 
git/objects/commit.py CHANGED
@@ -269,13 +269,21 @@ class Commit(base.Object, TraversableIterableObj, Diffable, Serializable):
269
269
  else:
270
270
  return self.message.split(b"\n", 1)[0]
271
271
 
272
- def count(self, paths: Union[PathLike, Sequence[PathLike]] = "", **kwargs: Any) -> int:
272
+ def count(
273
+ self,
274
+ paths: Union[PathLike, Sequence[PathLike]] = "",
275
+ allow_unsafe_options: bool = False,
276
+ **kwargs: Any,
277
+ ) -> int:
273
278
  """Count the number of commits reachable from this commit.
274
279
 
275
280
  :param paths:
276
281
  An optional path or a list of paths restricting the return value to commits
277
282
  actually containing the paths.
278
283
 
284
+ :param allow_unsafe_options:
285
+ Allow unsafe options, like ``--output``.
286
+
279
287
  :param kwargs:
280
288
  Additional options to be passed to :manpage:`git-rev-list(1)`. They must not
281
289
  alter the output style of the command, or parsing will yield incorrect
@@ -284,6 +292,11 @@ class Commit(base.Object, TraversableIterableObj, Diffable, Serializable):
284
292
  :return:
285
293
  An int defining the number of reachable commits
286
294
  """
295
+ if not allow_unsafe_options:
296
+ Git.check_unsafe_options(
297
+ options=Git._option_candidates([], kwargs), unsafe_options=self.unsafe_git_rev_options
298
+ )
299
+
287
300
  # Yes, it makes a difference whether empty paths are given or not in our case as
288
301
  # the empty paths version will ignore merge commits for some reason.
289
302
  if paths:
@@ -608,7 +608,7 @@ class Submodule(IndexObject, TraversableIterableObj):
608
608
  # END verify url
609
609
 
610
610
  ## See #525 for ensuring git URLs in config-files are valid under Windows.
611
- url = Git.polish_url(url)
611
+ url = Git.polish_url(url, expand_vars=False)
612
612
 
613
613
  # It's important to add the URL to the parent config, to let `git submodule` know.
614
614
  # Otherwise there is a '-' character in front of the submodule listing:
git/remote.py CHANGED
@@ -808,7 +808,7 @@ class Remote(LazyMixin, IterableObj):
808
808
  """
809
809
  scmd = "add"
810
810
  kwargs["insert_kwargs_after"] = scmd
811
- url = Git.polish_url(url)
811
+ url = Git.polish_url(url, expand_vars=False)
812
812
  if not allow_unsafe_protocols:
813
813
  Git.check_unsafe_protocols(url)
814
814
  repo.git.remote(scmd, "--", name, url, **kwargs)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: GitPython
3
- Version: 3.1.54
3
+ Version: 3.1.56
4
4
  Summary: GitPython is a Python library used to interact with Git repositories
5
5
  Home-page: https://github.com/gitpython-developers/GitPython
6
6
  Author: Sebastian Thiel, Michael Trier
@@ -22,6 +22,9 @@ Classifier: Programming Language :: Python :: 3.9
22
22
  Classifier: Programming Language :: Python :: 3.10
23
23
  Classifier: Programming Language :: Python :: 3.11
24
24
  Classifier: Programming Language :: Python :: 3.12
25
+ Classifier: Programming Language :: Python :: 3.13
26
+ Classifier: Programming Language :: Python :: 3.14
27
+ Classifier: Programming Language :: Python :: 3.15
25
28
  Requires-Python: >=3.7
26
29
  Description-Content-Type: text/markdown
27
30
  License-File: LICENSE
@@ -1,4 +1,4 @@
1
- git/__init__.py,sha256=ejaxDO65Qye0GVC6uARnfz8BBFjEe4atgLLXt__soo0,8899
1
+ git/__init__.py,sha256=rqhgyk2pLpsRiDm8ixgf4vM0CT2P0RNotTLMYiTWt14,8899
2
2
  git/cmd.py,sha256=SfzSWj4dxcXDHdpHQwIfyG3ISknzU8lnoYSi6fFBLbo,75648
3
3
  git/compat.py,sha256=y1E6y6O2q5r8clSlr8ZNmuIWG9nmHuehQEsVsmBffs8,4526
4
4
  git/config.py,sha256=aLDSuDiiB67W-OLktJpYVjSLwgIqWJtPYbRllNhQ7Gw,38406
@@ -6,7 +6,7 @@ git/db.py,sha256=vIW9uWSbqu99zbuU2ZDmOhVOv1UPTmxrnqiCtRHCfjE,2368
6
6
  git/diff.py,sha256=oMhc8IyMFfN24A7agcnarbFYjsz1vqskYzjh0s7MULw,28169
7
7
  git/exc.py,sha256=Gc7g1pHpn8OmTse30NHmJVsBJ2CYH8LxaR8y8UA3lIM,7119
8
8
  git/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
9
- git/remote.py,sha256=rCbrMMjILsX08TGYai8wdxzHCHc4ba6vPt6tP9efOog,46881
9
+ git/remote.py,sha256=d68K7XmkYXZUlIoLBDRpRom_df6mbkhWMrcPAP5s11c,46900
10
10
  git/types.py,sha256=d3oDduUGjfoqffcUL_GOD-3qroF8m3r9ai6Xi9_FraM,10279
11
11
  git/util.py,sha256=27MIkq6AhpjyAHF9r7UEA1pGYRAkxRMiZNo5IJGdJhU,44712
12
12
  git/index/__init__.py,sha256=i-Nqb8Lufp9aFbmxpQBORmmQnjEVVM1Pn58fsQkyGgQ,406
@@ -17,13 +17,13 @@ git/index/util.py,sha256=f0BfE2JPkdypsB2Q_HJ8KU7MC45RRHywL_GWwxa_5hw,3676
17
17
  git/objects/__init__.py,sha256=O6ZL_olX7e5-8iIbKviRPkVSJxN37WA-EC0q9d48U5Y,637
18
18
  git/objects/base.py,sha256=5-p9uSGWvPxX9hidvkGH9tQOJoH2eaRggUbMr9VJiL0,10285
19
19
  git/objects/blob.py,sha256=G9PZMNc5CFRQFNnlquBRAM5-jZg8581lRcxkvARobSk,1231
20
- git/objects/commit.py,sha256=5Pn-lDmFqzp2HxXGDv7Vr1pwwkC18IcZxmbRIkEaR7k,32816
20
+ git/objects/commit.py,sha256=aJYxpbkcmAskmnc6qv6Podswhshu1-GlY306UqNWzvs,33175
21
21
  git/objects/fun.py,sha256=B4jCqhAjm6Hl79GK58FPzW1H9K6Wc7Tx0rssyWmAcEE,8935
22
22
  git/objects/tag.py,sha256=jAGESnpmTEv-dLakPzheT5ILZFFArcItnXYqfxfDrgc,4441
23
23
  git/objects/tree.py,sha256=MmExcS59Iamb2cBqUvoHPdzgixabyvv5voHabossrl8,13898
24
24
  git/objects/util.py,sha256=Nlza4zLgdPmr_Yasyvvs6c1rKtW_wMxI6wDmQpQ3ufw,23846
25
25
  git/objects/submodule/__init__.py,sha256=6xySp767LVz3UylWgUalntS_nGXRuVzXxDuFAv_Wc2c,303
26
- git/objects/submodule/base.py,sha256=NR8eP-dEr-U_EG8LahRRgJ2n2z1wZXY9V0w57pBbiIo,66328
26
+ git/objects/submodule/base.py,sha256=1w39BpgNnpEmEacCLdCGLH-aeIaAMKU0oWUtgVcyVW0,66347
27
27
  git/objects/submodule/root.py,sha256=5eTtYNHasqdPq6q0oDCPr7IaO6uAHL3b4DxMoiO2LhE,20246
28
28
  git/objects/submodule/util.py,sha256=sQqAYaiSJdFkZa9NlAuK_wTsMNiS-kkQnQjvIoJtc_o,3509
29
29
  git/refs/__init__.py,sha256=DWlJNnsx-4jM_E-VycbP-FZUdn6iWhjnH_uZ_pZXBro,509
@@ -36,9 +36,9 @@ git/refs/tag.py,sha256=AKrFrMhkNzX8e9x5WmDRtHovbN9zYQghuKoneVW-TJg,5002
36
36
  git/repo/__init__.py,sha256=CILSVH36fX_WxVFSjD9o1WF5LgsNedPiJvSngKZqfVU,210
37
37
  git/repo/base.py,sha256=DZhyKpL1CkfPoXkFRgia6p9d2x7FNuogEhILlT68Xa4,64030
38
38
  git/repo/fun.py,sha256=PDFNkuTSGGoQc0EEEXjxHw2_KaKYvVjBZ9rrkwH5Q6Y,23462
39
- gitpython-3.1.54.dist-info/licenses/AUTHORS,sha256=Iucx_CH3w7_4084yjM6C5BvKfLA8cVfYHWW2pVmpxSk,2410
40
- gitpython-3.1.54.dist-info/licenses/LICENSE,sha256=hvyUwyGpr7wRUUcTURuv3tIl8lEA3MD3NQ6CvCMbi-s,1503
41
- gitpython-3.1.54.dist-info/METADATA,sha256=2517zCDhRiy0leLc0dujW64kmD-i2An5Za6jMdEqFhU,14187
42
- gitpython-3.1.54.dist-info/WHEEL,sha256=K260EYznzXsJYBQGqmI8VTxEdiZYNvDZwW9cBh9-_MA,91
43
- gitpython-3.1.54.dist-info/top_level.txt,sha256=0hzDuIp8obv624V3GmbqsagBWkk8ohtGU-Bc1PmTT0o,4
44
- gitpython-3.1.54.dist-info/RECORD,,
39
+ gitpython-3.1.56.dist-info/licenses/AUTHORS,sha256=Iucx_CH3w7_4084yjM6C5BvKfLA8cVfYHWW2pVmpxSk,2410
40
+ gitpython-3.1.56.dist-info/licenses/LICENSE,sha256=hvyUwyGpr7wRUUcTURuv3tIl8lEA3MD3NQ6CvCMbi-s,1503
41
+ gitpython-3.1.56.dist-info/METADATA,sha256=2GkcUbrC-AoVKsGEiIRrcIrMu4dgl-kg9iXzo3k4C-Q,14340
42
+ gitpython-3.1.56.dist-info/WHEEL,sha256=K260EYznzXsJYBQGqmI8VTxEdiZYNvDZwW9cBh9-_MA,91
43
+ gitpython-3.1.56.dist-info/top_level.txt,sha256=0hzDuIp8obv624V3GmbqsagBWkk8ohtGU-Bc1PmTT0o,4
44
+ gitpython-3.1.56.dist-info/RECORD,,