GitPython 3.1.42__tar.gz → 3.1.44__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.
- {GitPython-3.1.42 → gitpython-3.1.44}/AUTHORS +1 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/CONTRIBUTING.md +5 -0
- {GitPython-3.1.42 → gitpython-3.1.44/GitPython.egg-info}/PKG-INFO +35 -30
- {GitPython-3.1.42 → gitpython-3.1.44}/GitPython.egg-info/requires.txt +8 -1
- {GitPython-3.1.42/GitPython.egg-info → gitpython-3.1.44}/PKG-INFO +35 -30
- {GitPython-3.1.42 → gitpython-3.1.44}/README.md +29 -28
- gitpython-3.1.44/VERSION +1 -0
- gitpython-3.1.44/doc/requirements.txt +3 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/doc/source/changes.rst +16 -1
- {GitPython-3.1.42 → gitpython-3.1.44}/doc/source/conf.py +45 -46
- {GitPython-3.1.42 → gitpython-3.1.44}/doc/source/index.rst +0 -1
- {GitPython-3.1.42 → gitpython-3.1.44}/doc/source/intro.rst +0 -1
- {GitPython-3.1.42 → gitpython-3.1.44}/doc/source/reference.rst +45 -18
- {GitPython-3.1.42 → gitpython-3.1.44}/doc/source/roadmap.rst +0 -1
- gitpython-3.1.44/git/__init__.py +300 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/git/cmd.py +542 -316
- {GitPython-3.1.42 → gitpython-3.1.44}/git/compat.py +65 -30
- {GitPython-3.1.42 → gitpython-3.1.44}/git/config.py +119 -78
- {GitPython-3.1.42 → gitpython-3.1.44}/git/db.py +16 -16
- {GitPython-3.1.42 → gitpython-3.1.44}/git/diff.py +182 -82
- {GitPython-3.1.42 → gitpython-3.1.44}/git/exc.py +14 -8
- gitpython-3.1.44/git/index/__init__.py +16 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/git/index/base.py +384 -318
- {GitPython-3.1.42 → gitpython-3.1.44}/git/index/fun.py +87 -67
- {GitPython-3.1.42 → gitpython-3.1.44}/git/index/typ.py +33 -25
- {GitPython-3.1.42 → gitpython-3.1.44}/git/index/util.py +7 -13
- gitpython-3.1.44/git/objects/__init__.py +25 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/git/objects/base.py +115 -48
- {GitPython-3.1.42 → gitpython-3.1.44}/git/objects/blob.py +17 -6
- {GitPython-3.1.42 → gitpython-3.1.44}/git/objects/commit.py +223 -143
- {GitPython-3.1.42 → gitpython-3.1.44}/git/objects/fun.py +56 -44
- gitpython-3.1.44/git/objects/submodule/__init__.py +7 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/git/objects/submodule/base.py +410 -225
- {GitPython-3.1.42 → gitpython-3.1.44}/git/objects/submodule/root.py +99 -74
- {GitPython-3.1.42 → gitpython-3.1.44}/git/objects/submodule/util.py +25 -24
- {GitPython-3.1.42 → gitpython-3.1.44}/git/objects/tag.py +48 -18
- {GitPython-3.1.42 → gitpython-3.1.44}/git/objects/tree.py +83 -62
- {GitPython-3.1.42 → gitpython-3.1.44}/git/objects/util.py +152 -113
- gitpython-3.1.44/git/refs/__init__.py +21 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/git/refs/head.py +62 -52
- {GitPython-3.1.42 → gitpython-3.1.44}/git/refs/log.py +83 -52
- {GitPython-3.1.42 → gitpython-3.1.44}/git/refs/reference.py +40 -30
- {GitPython-3.1.42 → gitpython-3.1.44}/git/refs/remote.py +15 -16
- {GitPython-3.1.42 → gitpython-3.1.44}/git/refs/symbolic.py +183 -126
- {GitPython-3.1.42 → gitpython-3.1.44}/git/refs/tag.py +34 -20
- {GitPython-3.1.42 → gitpython-3.1.44}/git/remote.py +242 -155
- {GitPython-3.1.42 → gitpython-3.1.44}/git/repo/__init__.py +4 -2
- {GitPython-3.1.42 → gitpython-3.1.44}/git/repo/base.py +391 -243
- {GitPython-3.1.42 → gitpython-3.1.44}/git/repo/fun.py +122 -96
- gitpython-3.1.44/git/types.py +285 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/git/util.py +254 -202
- gitpython-3.1.44/pyproject.toml +89 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/setup.py +17 -13
- {GitPython-3.1.42 → gitpython-3.1.44}/test-requirements.txt +1 -1
- GitPython-3.1.42/VERSION +0 -1
- GitPython-3.1.42/doc/requirements.txt +0 -8
- GitPython-3.1.42/git/__init__.py +0 -143
- GitPython-3.1.42/git/index/__init__.py +0 -7
- GitPython-3.1.42/git/objects/__init__.py +0 -24
- GitPython-3.1.42/git/objects/submodule/__init__.py +0 -5
- GitPython-3.1.42/git/refs/__init__.py +0 -12
- GitPython-3.1.42/git/types.py +0 -117
- GitPython-3.1.42/pyproject.toml +0 -49
- {GitPython-3.1.42 → gitpython-3.1.44}/CHANGES +0 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/GitPython.egg-info/SOURCES.txt +0 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/GitPython.egg-info/dependency_links.txt +0 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/GitPython.egg-info/not-zip-safe +0 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/GitPython.egg-info/top_level.txt +0 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/LICENSE +0 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/MANIFEST.in +0 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/doc/.gitignore +0 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/doc/Makefile +0 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/doc/source/quickstart.rst +0 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/doc/source/tutorial.rst +0 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/git/py.typed +0 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/requirements.txt +0 -0
- {GitPython-3.1.42 → gitpython-3.1.44}/setup.cfg +0 -0
|
@@ -54,5 +54,6 @@ Contributors are:
|
|
|
54
54
|
-Wenhan Zhu <wzhu.cosmos _at_ gmail.com>
|
|
55
55
|
-Eliah Kagan <eliah.kagan _at_ gmail.com>
|
|
56
56
|
-Ethan Lin <et.repositories _at_ gmail.com>
|
|
57
|
+
-Jonas Scharpf <jonas.scharpf _at_ checkmk.com>
|
|
57
58
|
|
|
58
59
|
Portions derived from other open source works and are clearly marked.
|
|
@@ -8,3 +8,8 @@ The following is a short step-by-step rundown of what one typically would do to
|
|
|
8
8
|
- Try to avoid massive commits and prefer to take small steps, with one commit for each.
|
|
9
9
|
- Feel free to add yourself to AUTHORS file.
|
|
10
10
|
- Create a pull request.
|
|
11
|
+
|
|
12
|
+
## Fuzzing Test Specific Documentation
|
|
13
|
+
|
|
14
|
+
For details related to contributing to the fuzzing test suite and OSS-Fuzz integration, please
|
|
15
|
+
refer to the dedicated [fuzzing README](./fuzzing/README.md).
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: GitPython
|
|
3
|
-
Version: 3.1.
|
|
3
|
+
Version: 3.1.44
|
|
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
|
|
@@ -30,7 +30,6 @@ License-File: AUTHORS
|
|
|
30
30
|
Requires-Dist: gitdb<5,>=4.0.1
|
|
31
31
|
Requires-Dist: typing-extensions>=3.7.4.3; python_version < "3.8"
|
|
32
32
|
Provides-Extra: test
|
|
33
|
-
Requires-Dist: black; extra == "test"
|
|
34
33
|
Requires-Dist: coverage[toml]; extra == "test"
|
|
35
34
|
Requires-Dist: ddt!=1.4.3,>=1.1.1; extra == "test"
|
|
36
35
|
Requires-Dist: mock; python_version < "3.8" and extra == "test"
|
|
@@ -41,6 +40,11 @@ Requires-Dist: pytest-cov; extra == "test"
|
|
|
41
40
|
Requires-Dist: pytest-instafail; extra == "test"
|
|
42
41
|
Requires-Dist: pytest-mock; extra == "test"
|
|
43
42
|
Requires-Dist: pytest-sugar; extra == "test"
|
|
43
|
+
Requires-Dist: typing-extensions; python_version < "3.11" and extra == "test"
|
|
44
|
+
Provides-Extra: doc
|
|
45
|
+
Requires-Dist: sphinx<7.2,>=7.1.2; extra == "doc"
|
|
46
|
+
Requires-Dist: sphinx_rtd_theme; extra == "doc"
|
|
47
|
+
Requires-Dist: sphinx-autodoc-typehints; extra == "doc"
|
|
44
48
|
|
|
45
49
|

|
|
46
50
|
[](https://readthedocs.org/projects/gitpython/?badge=stable)
|
|
@@ -61,7 +65,7 @@ probably the skills to scratch that itch of mine: implement `git` in a way that
|
|
|
61
65
|
If you like the idea and want to learn more, please head over to [gitoxide](https://github.com/Byron/gitoxide), an
|
|
62
66
|
implementation of 'git' in [Rust](https://www.rust-lang.org).
|
|
63
67
|
|
|
64
|
-
*(Please note that `gitoxide` is not currently available for use in Python, and that Rust is required)*
|
|
68
|
+
*(Please note that `gitoxide` is not currently available for use in Python, and that Rust is required.)*
|
|
65
69
|
|
|
66
70
|
## GitPython
|
|
67
71
|
|
|
@@ -83,9 +87,9 @@ The project is open to contributions of all kinds, as well as new maintainers.
|
|
|
83
87
|
|
|
84
88
|
### REQUIREMENTS
|
|
85
89
|
|
|
86
|
-
GitPython needs the `git` executable to be installed on the system and available in your
|
|
87
|
-
If it is not in your `PATH`, you can help GitPython find it
|
|
88
|
-
the `GIT_PYTHON_GIT_EXECUTABLE=<path/to/git>` environment variable.
|
|
90
|
+
GitPython needs the `git` executable to be installed on the system and available in your
|
|
91
|
+
`PATH` for most operations. If it is not in your `PATH`, you can help GitPython find it
|
|
92
|
+
by setting the `GIT_PYTHON_GIT_EXECUTABLE=<path/to/git>` environment variable.
|
|
89
93
|
|
|
90
94
|
- Git (1.7.x or newer)
|
|
91
95
|
- Python >= 3.7
|
|
@@ -101,7 +105,7 @@ GitPython and its required package dependencies can be installed in any of the f
|
|
|
101
105
|
|
|
102
106
|
To obtain and install a copy [from PyPI](https://pypi.org/project/GitPython/), run:
|
|
103
107
|
|
|
104
|
-
```
|
|
108
|
+
```sh
|
|
105
109
|
pip install GitPython
|
|
106
110
|
```
|
|
107
111
|
|
|
@@ -111,7 +115,7 @@ pip install GitPython
|
|
|
111
115
|
|
|
112
116
|
If you have downloaded the source code, run this from inside the unpacked `GitPython` directory:
|
|
113
117
|
|
|
114
|
-
```
|
|
118
|
+
```sh
|
|
115
119
|
pip install .
|
|
116
120
|
```
|
|
117
121
|
|
|
@@ -119,7 +123,7 @@ pip install .
|
|
|
119
123
|
|
|
120
124
|
To clone the [the GitHub repository](https://github.com/gitpython-developers/GitPython) from source to work on the code, you can do it like so:
|
|
121
125
|
|
|
122
|
-
```
|
|
126
|
+
```sh
|
|
123
127
|
git clone https://github.com/gitpython-developers/GitPython
|
|
124
128
|
cd GitPython
|
|
125
129
|
./init-tests-after-clone.sh
|
|
@@ -129,7 +133,7 @@ On Windows, `./init-tests-after-clone.sh` can be run in a Git Bash shell.
|
|
|
129
133
|
|
|
130
134
|
If you are cloning [your own fork](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/about-forks), then replace the above `git clone` command with one that gives the URL of your fork. Or use this [`gh`](https://cli.github.com/) command (assuming you have `gh` and your fork is called `GitPython`):
|
|
131
135
|
|
|
132
|
-
```
|
|
136
|
+
```sh
|
|
133
137
|
gh repo clone GitPython
|
|
134
138
|
```
|
|
135
139
|
|
|
@@ -137,7 +141,7 @@ Having cloned the repo, create and activate your [virtual environment](https://d
|
|
|
137
141
|
|
|
138
142
|
Then make an [editable install](https://pip.pypa.io/en/stable/topics/local-project-installs/#editable-installs):
|
|
139
143
|
|
|
140
|
-
```
|
|
144
|
+
```sh
|
|
141
145
|
pip install -e ".[test]"
|
|
142
146
|
```
|
|
143
147
|
|
|
@@ -145,11 +149,11 @@ In the less common case that you do not want to install test dependencies, `pip
|
|
|
145
149
|
|
|
146
150
|
#### With editable *dependencies* (not preferred, and rarely needed)
|
|
147
151
|
|
|
148
|
-
In rare cases, you may want to work on GitPython and one or both of its [gitdb](https://github.com/gitpython-developers/gitdb) and [smmap](https://github.com/gitpython-developers/smmap) dependencies at the same time, with changes in your local working copy of gitdb or smmap
|
|
152
|
+
In rare cases, you may want to work on GitPython and one or both of its [gitdb](https://github.com/gitpython-developers/gitdb) and [smmap](https://github.com/gitpython-developers/smmap) dependencies at the same time, with changes in your local working copy of gitdb or smmap immediately reflected in the behavior of your local working copy of GitPython. This can be done by making editable installations of those dependencies in the same virtual environment where you install GitPython.
|
|
149
153
|
|
|
150
154
|
If you want to do that *and* you want the versions in GitPython's git submodules to be used, then pass `-e git/ext/gitdb` and/or `-e git/ext/gitdb/gitdb/ext/smmap` to `pip install`. This can be done in any order, and in separate `pip install` commands or the same one, so long as `-e` appears before *each* path. For example, you can install GitPython, gitdb, and smmap editably in the currently active virtual environment this way:
|
|
151
155
|
|
|
152
|
-
```
|
|
156
|
+
```sh
|
|
153
157
|
pip install -e ".[test]" -e git/ext/gitdb -e git/ext/gitdb/gitdb/ext/smmap
|
|
154
158
|
```
|
|
155
159
|
|
|
@@ -185,42 +189,38 @@ you will encounter test failures.
|
|
|
185
189
|
|
|
186
190
|
Ensure testing libraries are installed. This is taken care of already if you installed with:
|
|
187
191
|
|
|
188
|
-
```
|
|
192
|
+
```sh
|
|
189
193
|
pip install -e ".[test]"
|
|
190
194
|
```
|
|
191
195
|
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
```bash
|
|
195
|
-
pip install -r test-requirements.txt
|
|
196
|
-
```
|
|
196
|
+
If you had installed with a command like `pip install -e .` instead, you can still run
|
|
197
|
+
the above command to add the testing dependencies.
|
|
197
198
|
|
|
198
199
|
#### Test commands
|
|
199
200
|
|
|
200
201
|
To test, run:
|
|
201
202
|
|
|
202
|
-
```
|
|
203
|
+
```sh
|
|
203
204
|
pytest
|
|
204
205
|
```
|
|
205
206
|
|
|
206
|
-
To lint, and apply automatic code formatting, run:
|
|
207
|
+
To lint, and apply some linting fixes as well as automatic code formatting, run:
|
|
207
208
|
|
|
208
|
-
```
|
|
209
|
+
```sh
|
|
209
210
|
pre-commit run --all-files
|
|
210
211
|
```
|
|
211
212
|
|
|
212
|
-
|
|
213
|
-
- Auto-formatting without other lint checks can be done with: `black .`
|
|
213
|
+
This includes the linting and autoformatting done by Ruff, as well as some other checks.
|
|
214
214
|
|
|
215
215
|
To typecheck, run:
|
|
216
216
|
|
|
217
|
-
```
|
|
218
|
-
mypy
|
|
217
|
+
```sh
|
|
218
|
+
mypy
|
|
219
219
|
```
|
|
220
220
|
|
|
221
221
|
#### CI (and tox)
|
|
222
222
|
|
|
223
|
-
|
|
223
|
+
Style and formatting checks, and running tests on all the different supported Python versions, will be performed:
|
|
224
224
|
|
|
225
225
|
- Upon submitting a pull request.
|
|
226
226
|
- On each push, *if* you have a fork with GitHub Actions enabled.
|
|
@@ -228,10 +228,12 @@ The same linting, and running tests on all the different supported Python versio
|
|
|
228
228
|
|
|
229
229
|
#### Configuration files
|
|
230
230
|
|
|
231
|
-
Specific tools:
|
|
231
|
+
Specific tools are all configured in the `./pyproject.toml` file:
|
|
232
232
|
|
|
233
|
-
-
|
|
234
|
-
-
|
|
233
|
+
- `pytest` (test runner)
|
|
234
|
+
- `coverage.py` (code coverage)
|
|
235
|
+
- `ruff` (linter and formatter)
|
|
236
|
+
- `mypy` (type checker)
|
|
235
237
|
|
|
236
238
|
Orchestration tools:
|
|
237
239
|
|
|
@@ -286,5 +288,8 @@ Please have a look at the [contributions file][contributing].
|
|
|
286
288
|
|
|
287
289
|
[3-Clause BSD License](https://opensource.org/license/bsd-3-clause/), also known as the New BSD License. See the [LICENSE file][license].
|
|
288
290
|
|
|
291
|
+
One file exclusively used for fuzz testing is subject to [a separate license, detailed here](./fuzzing/README.md#license).
|
|
292
|
+
This file is not included in the wheel or sdist packages published by the maintainers of GitPython.
|
|
293
|
+
|
|
289
294
|
[contributing]: https://github.com/gitpython-developers/GitPython/blob/main/CONTRIBUTING.md
|
|
290
295
|
[license]: https://github.com/gitpython-developers/GitPython/blob/main/LICENSE
|
|
@@ -3,8 +3,12 @@ gitdb<5,>=4.0.1
|
|
|
3
3
|
[:python_version < "3.8"]
|
|
4
4
|
typing-extensions>=3.7.4.3
|
|
5
5
|
|
|
6
|
+
[doc]
|
|
7
|
+
sphinx<7.2,>=7.1.2
|
|
8
|
+
sphinx_rtd_theme
|
|
9
|
+
sphinx-autodoc-typehints
|
|
10
|
+
|
|
6
11
|
[test]
|
|
7
|
-
black
|
|
8
12
|
coverage[toml]
|
|
9
13
|
ddt!=1.4.3,>=1.1.1
|
|
10
14
|
mypy
|
|
@@ -15,5 +19,8 @@ pytest-instafail
|
|
|
15
19
|
pytest-mock
|
|
16
20
|
pytest-sugar
|
|
17
21
|
|
|
22
|
+
[test:python_version < "3.11"]
|
|
23
|
+
typing-extensions
|
|
24
|
+
|
|
18
25
|
[test:python_version < "3.8"]
|
|
19
26
|
mock
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: GitPython
|
|
3
|
-
Version: 3.1.
|
|
3
|
+
Version: 3.1.44
|
|
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
|
|
@@ -30,7 +30,6 @@ License-File: AUTHORS
|
|
|
30
30
|
Requires-Dist: gitdb<5,>=4.0.1
|
|
31
31
|
Requires-Dist: typing-extensions>=3.7.4.3; python_version < "3.8"
|
|
32
32
|
Provides-Extra: test
|
|
33
|
-
Requires-Dist: black; extra == "test"
|
|
34
33
|
Requires-Dist: coverage[toml]; extra == "test"
|
|
35
34
|
Requires-Dist: ddt!=1.4.3,>=1.1.1; extra == "test"
|
|
36
35
|
Requires-Dist: mock; python_version < "3.8" and extra == "test"
|
|
@@ -41,6 +40,11 @@ Requires-Dist: pytest-cov; extra == "test"
|
|
|
41
40
|
Requires-Dist: pytest-instafail; extra == "test"
|
|
42
41
|
Requires-Dist: pytest-mock; extra == "test"
|
|
43
42
|
Requires-Dist: pytest-sugar; extra == "test"
|
|
43
|
+
Requires-Dist: typing-extensions; python_version < "3.11" and extra == "test"
|
|
44
|
+
Provides-Extra: doc
|
|
45
|
+
Requires-Dist: sphinx<7.2,>=7.1.2; extra == "doc"
|
|
46
|
+
Requires-Dist: sphinx_rtd_theme; extra == "doc"
|
|
47
|
+
Requires-Dist: sphinx-autodoc-typehints; extra == "doc"
|
|
44
48
|
|
|
45
49
|

|
|
46
50
|
[](https://readthedocs.org/projects/gitpython/?badge=stable)
|
|
@@ -61,7 +65,7 @@ probably the skills to scratch that itch of mine: implement `git` in a way that
|
|
|
61
65
|
If you like the idea and want to learn more, please head over to [gitoxide](https://github.com/Byron/gitoxide), an
|
|
62
66
|
implementation of 'git' in [Rust](https://www.rust-lang.org).
|
|
63
67
|
|
|
64
|
-
*(Please note that `gitoxide` is not currently available for use in Python, and that Rust is required)*
|
|
68
|
+
*(Please note that `gitoxide` is not currently available for use in Python, and that Rust is required.)*
|
|
65
69
|
|
|
66
70
|
## GitPython
|
|
67
71
|
|
|
@@ -83,9 +87,9 @@ The project is open to contributions of all kinds, as well as new maintainers.
|
|
|
83
87
|
|
|
84
88
|
### REQUIREMENTS
|
|
85
89
|
|
|
86
|
-
GitPython needs the `git` executable to be installed on the system and available in your
|
|
87
|
-
If it is not in your `PATH`, you can help GitPython find it
|
|
88
|
-
the `GIT_PYTHON_GIT_EXECUTABLE=<path/to/git>` environment variable.
|
|
90
|
+
GitPython needs the `git` executable to be installed on the system and available in your
|
|
91
|
+
`PATH` for most operations. If it is not in your `PATH`, you can help GitPython find it
|
|
92
|
+
by setting the `GIT_PYTHON_GIT_EXECUTABLE=<path/to/git>` environment variable.
|
|
89
93
|
|
|
90
94
|
- Git (1.7.x or newer)
|
|
91
95
|
- Python >= 3.7
|
|
@@ -101,7 +105,7 @@ GitPython and its required package dependencies can be installed in any of the f
|
|
|
101
105
|
|
|
102
106
|
To obtain and install a copy [from PyPI](https://pypi.org/project/GitPython/), run:
|
|
103
107
|
|
|
104
|
-
```
|
|
108
|
+
```sh
|
|
105
109
|
pip install GitPython
|
|
106
110
|
```
|
|
107
111
|
|
|
@@ -111,7 +115,7 @@ pip install GitPython
|
|
|
111
115
|
|
|
112
116
|
If you have downloaded the source code, run this from inside the unpacked `GitPython` directory:
|
|
113
117
|
|
|
114
|
-
```
|
|
118
|
+
```sh
|
|
115
119
|
pip install .
|
|
116
120
|
```
|
|
117
121
|
|
|
@@ -119,7 +123,7 @@ pip install .
|
|
|
119
123
|
|
|
120
124
|
To clone the [the GitHub repository](https://github.com/gitpython-developers/GitPython) from source to work on the code, you can do it like so:
|
|
121
125
|
|
|
122
|
-
```
|
|
126
|
+
```sh
|
|
123
127
|
git clone https://github.com/gitpython-developers/GitPython
|
|
124
128
|
cd GitPython
|
|
125
129
|
./init-tests-after-clone.sh
|
|
@@ -129,7 +133,7 @@ On Windows, `./init-tests-after-clone.sh` can be run in a Git Bash shell.
|
|
|
129
133
|
|
|
130
134
|
If you are cloning [your own fork](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/about-forks), then replace the above `git clone` command with one that gives the URL of your fork. Or use this [`gh`](https://cli.github.com/) command (assuming you have `gh` and your fork is called `GitPython`):
|
|
131
135
|
|
|
132
|
-
```
|
|
136
|
+
```sh
|
|
133
137
|
gh repo clone GitPython
|
|
134
138
|
```
|
|
135
139
|
|
|
@@ -137,7 +141,7 @@ Having cloned the repo, create and activate your [virtual environment](https://d
|
|
|
137
141
|
|
|
138
142
|
Then make an [editable install](https://pip.pypa.io/en/stable/topics/local-project-installs/#editable-installs):
|
|
139
143
|
|
|
140
|
-
```
|
|
144
|
+
```sh
|
|
141
145
|
pip install -e ".[test]"
|
|
142
146
|
```
|
|
143
147
|
|
|
@@ -145,11 +149,11 @@ In the less common case that you do not want to install test dependencies, `pip
|
|
|
145
149
|
|
|
146
150
|
#### With editable *dependencies* (not preferred, and rarely needed)
|
|
147
151
|
|
|
148
|
-
In rare cases, you may want to work on GitPython and one or both of its [gitdb](https://github.com/gitpython-developers/gitdb) and [smmap](https://github.com/gitpython-developers/smmap) dependencies at the same time, with changes in your local working copy of gitdb or smmap
|
|
152
|
+
In rare cases, you may want to work on GitPython and one or both of its [gitdb](https://github.com/gitpython-developers/gitdb) and [smmap](https://github.com/gitpython-developers/smmap) dependencies at the same time, with changes in your local working copy of gitdb or smmap immediately reflected in the behavior of your local working copy of GitPython. This can be done by making editable installations of those dependencies in the same virtual environment where you install GitPython.
|
|
149
153
|
|
|
150
154
|
If you want to do that *and* you want the versions in GitPython's git submodules to be used, then pass `-e git/ext/gitdb` and/or `-e git/ext/gitdb/gitdb/ext/smmap` to `pip install`. This can be done in any order, and in separate `pip install` commands or the same one, so long as `-e` appears before *each* path. For example, you can install GitPython, gitdb, and smmap editably in the currently active virtual environment this way:
|
|
151
155
|
|
|
152
|
-
```
|
|
156
|
+
```sh
|
|
153
157
|
pip install -e ".[test]" -e git/ext/gitdb -e git/ext/gitdb/gitdb/ext/smmap
|
|
154
158
|
```
|
|
155
159
|
|
|
@@ -185,42 +189,38 @@ you will encounter test failures.
|
|
|
185
189
|
|
|
186
190
|
Ensure testing libraries are installed. This is taken care of already if you installed with:
|
|
187
191
|
|
|
188
|
-
```
|
|
192
|
+
```sh
|
|
189
193
|
pip install -e ".[test]"
|
|
190
194
|
```
|
|
191
195
|
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
```bash
|
|
195
|
-
pip install -r test-requirements.txt
|
|
196
|
-
```
|
|
196
|
+
If you had installed with a command like `pip install -e .` instead, you can still run
|
|
197
|
+
the above command to add the testing dependencies.
|
|
197
198
|
|
|
198
199
|
#### Test commands
|
|
199
200
|
|
|
200
201
|
To test, run:
|
|
201
202
|
|
|
202
|
-
```
|
|
203
|
+
```sh
|
|
203
204
|
pytest
|
|
204
205
|
```
|
|
205
206
|
|
|
206
|
-
To lint, and apply automatic code formatting, run:
|
|
207
|
+
To lint, and apply some linting fixes as well as automatic code formatting, run:
|
|
207
208
|
|
|
208
|
-
```
|
|
209
|
+
```sh
|
|
209
210
|
pre-commit run --all-files
|
|
210
211
|
```
|
|
211
212
|
|
|
212
|
-
|
|
213
|
-
- Auto-formatting without other lint checks can be done with: `black .`
|
|
213
|
+
This includes the linting and autoformatting done by Ruff, as well as some other checks.
|
|
214
214
|
|
|
215
215
|
To typecheck, run:
|
|
216
216
|
|
|
217
|
-
```
|
|
218
|
-
mypy
|
|
217
|
+
```sh
|
|
218
|
+
mypy
|
|
219
219
|
```
|
|
220
220
|
|
|
221
221
|
#### CI (and tox)
|
|
222
222
|
|
|
223
|
-
|
|
223
|
+
Style and formatting checks, and running tests on all the different supported Python versions, will be performed:
|
|
224
224
|
|
|
225
225
|
- Upon submitting a pull request.
|
|
226
226
|
- On each push, *if* you have a fork with GitHub Actions enabled.
|
|
@@ -228,10 +228,12 @@ The same linting, and running tests on all the different supported Python versio
|
|
|
228
228
|
|
|
229
229
|
#### Configuration files
|
|
230
230
|
|
|
231
|
-
Specific tools:
|
|
231
|
+
Specific tools are all configured in the `./pyproject.toml` file:
|
|
232
232
|
|
|
233
|
-
-
|
|
234
|
-
-
|
|
233
|
+
- `pytest` (test runner)
|
|
234
|
+
- `coverage.py` (code coverage)
|
|
235
|
+
- `ruff` (linter and formatter)
|
|
236
|
+
- `mypy` (type checker)
|
|
235
237
|
|
|
236
238
|
Orchestration tools:
|
|
237
239
|
|
|
@@ -286,5 +288,8 @@ Please have a look at the [contributions file][contributing].
|
|
|
286
288
|
|
|
287
289
|
[3-Clause BSD License](https://opensource.org/license/bsd-3-clause/), also known as the New BSD License. See the [LICENSE file][license].
|
|
288
290
|
|
|
291
|
+
One file exclusively used for fuzz testing is subject to [a separate license, detailed here](./fuzzing/README.md#license).
|
|
292
|
+
This file is not included in the wheel or sdist packages published by the maintainers of GitPython.
|
|
293
|
+
|
|
289
294
|
[contributing]: https://github.com/gitpython-developers/GitPython/blob/main/CONTRIBUTING.md
|
|
290
295
|
[license]: https://github.com/gitpython-developers/GitPython/blob/main/LICENSE
|
|
@@ -17,7 +17,7 @@ probably the skills to scratch that itch of mine: implement `git` in a way that
|
|
|
17
17
|
If you like the idea and want to learn more, please head over to [gitoxide](https://github.com/Byron/gitoxide), an
|
|
18
18
|
implementation of 'git' in [Rust](https://www.rust-lang.org).
|
|
19
19
|
|
|
20
|
-
*(Please note that `gitoxide` is not currently available for use in Python, and that Rust is required)*
|
|
20
|
+
*(Please note that `gitoxide` is not currently available for use in Python, and that Rust is required.)*
|
|
21
21
|
|
|
22
22
|
## GitPython
|
|
23
23
|
|
|
@@ -39,9 +39,9 @@ The project is open to contributions of all kinds, as well as new maintainers.
|
|
|
39
39
|
|
|
40
40
|
### REQUIREMENTS
|
|
41
41
|
|
|
42
|
-
GitPython needs the `git` executable to be installed on the system and available in your
|
|
43
|
-
If it is not in your `PATH`, you can help GitPython find it
|
|
44
|
-
the `GIT_PYTHON_GIT_EXECUTABLE=<path/to/git>` environment variable.
|
|
42
|
+
GitPython needs the `git` executable to be installed on the system and available in your
|
|
43
|
+
`PATH` for most operations. If it is not in your `PATH`, you can help GitPython find it
|
|
44
|
+
by setting the `GIT_PYTHON_GIT_EXECUTABLE=<path/to/git>` environment variable.
|
|
45
45
|
|
|
46
46
|
- Git (1.7.x or newer)
|
|
47
47
|
- Python >= 3.7
|
|
@@ -57,7 +57,7 @@ GitPython and its required package dependencies can be installed in any of the f
|
|
|
57
57
|
|
|
58
58
|
To obtain and install a copy [from PyPI](https://pypi.org/project/GitPython/), run:
|
|
59
59
|
|
|
60
|
-
```
|
|
60
|
+
```sh
|
|
61
61
|
pip install GitPython
|
|
62
62
|
```
|
|
63
63
|
|
|
@@ -67,7 +67,7 @@ pip install GitPython
|
|
|
67
67
|
|
|
68
68
|
If you have downloaded the source code, run this from inside the unpacked `GitPython` directory:
|
|
69
69
|
|
|
70
|
-
```
|
|
70
|
+
```sh
|
|
71
71
|
pip install .
|
|
72
72
|
```
|
|
73
73
|
|
|
@@ -75,7 +75,7 @@ pip install .
|
|
|
75
75
|
|
|
76
76
|
To clone the [the GitHub repository](https://github.com/gitpython-developers/GitPython) from source to work on the code, you can do it like so:
|
|
77
77
|
|
|
78
|
-
```
|
|
78
|
+
```sh
|
|
79
79
|
git clone https://github.com/gitpython-developers/GitPython
|
|
80
80
|
cd GitPython
|
|
81
81
|
./init-tests-after-clone.sh
|
|
@@ -85,7 +85,7 @@ On Windows, `./init-tests-after-clone.sh` can be run in a Git Bash shell.
|
|
|
85
85
|
|
|
86
86
|
If you are cloning [your own fork](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/about-forks), then replace the above `git clone` command with one that gives the URL of your fork. Or use this [`gh`](https://cli.github.com/) command (assuming you have `gh` and your fork is called `GitPython`):
|
|
87
87
|
|
|
88
|
-
```
|
|
88
|
+
```sh
|
|
89
89
|
gh repo clone GitPython
|
|
90
90
|
```
|
|
91
91
|
|
|
@@ -93,7 +93,7 @@ Having cloned the repo, create and activate your [virtual environment](https://d
|
|
|
93
93
|
|
|
94
94
|
Then make an [editable install](https://pip.pypa.io/en/stable/topics/local-project-installs/#editable-installs):
|
|
95
95
|
|
|
96
|
-
```
|
|
96
|
+
```sh
|
|
97
97
|
pip install -e ".[test]"
|
|
98
98
|
```
|
|
99
99
|
|
|
@@ -101,11 +101,11 @@ In the less common case that you do not want to install test dependencies, `pip
|
|
|
101
101
|
|
|
102
102
|
#### With editable *dependencies* (not preferred, and rarely needed)
|
|
103
103
|
|
|
104
|
-
In rare cases, you may want to work on GitPython and one or both of its [gitdb](https://github.com/gitpython-developers/gitdb) and [smmap](https://github.com/gitpython-developers/smmap) dependencies at the same time, with changes in your local working copy of gitdb or smmap
|
|
104
|
+
In rare cases, you may want to work on GitPython and one or both of its [gitdb](https://github.com/gitpython-developers/gitdb) and [smmap](https://github.com/gitpython-developers/smmap) dependencies at the same time, with changes in your local working copy of gitdb or smmap immediately reflected in the behavior of your local working copy of GitPython. This can be done by making editable installations of those dependencies in the same virtual environment where you install GitPython.
|
|
105
105
|
|
|
106
106
|
If you want to do that *and* you want the versions in GitPython's git submodules to be used, then pass `-e git/ext/gitdb` and/or `-e git/ext/gitdb/gitdb/ext/smmap` to `pip install`. This can be done in any order, and in separate `pip install` commands or the same one, so long as `-e` appears before *each* path. For example, you can install GitPython, gitdb, and smmap editably in the currently active virtual environment this way:
|
|
107
107
|
|
|
108
|
-
```
|
|
108
|
+
```sh
|
|
109
109
|
pip install -e ".[test]" -e git/ext/gitdb -e git/ext/gitdb/gitdb/ext/smmap
|
|
110
110
|
```
|
|
111
111
|
|
|
@@ -141,42 +141,38 @@ you will encounter test failures.
|
|
|
141
141
|
|
|
142
142
|
Ensure testing libraries are installed. This is taken care of already if you installed with:
|
|
143
143
|
|
|
144
|
-
```
|
|
144
|
+
```sh
|
|
145
145
|
pip install -e ".[test]"
|
|
146
146
|
```
|
|
147
147
|
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
```bash
|
|
151
|
-
pip install -r test-requirements.txt
|
|
152
|
-
```
|
|
148
|
+
If you had installed with a command like `pip install -e .` instead, you can still run
|
|
149
|
+
the above command to add the testing dependencies.
|
|
153
150
|
|
|
154
151
|
#### Test commands
|
|
155
152
|
|
|
156
153
|
To test, run:
|
|
157
154
|
|
|
158
|
-
```
|
|
155
|
+
```sh
|
|
159
156
|
pytest
|
|
160
157
|
```
|
|
161
158
|
|
|
162
|
-
To lint, and apply automatic code formatting, run:
|
|
159
|
+
To lint, and apply some linting fixes as well as automatic code formatting, run:
|
|
163
160
|
|
|
164
|
-
```
|
|
161
|
+
```sh
|
|
165
162
|
pre-commit run --all-files
|
|
166
163
|
```
|
|
167
164
|
|
|
168
|
-
|
|
169
|
-
- Auto-formatting without other lint checks can be done with: `black .`
|
|
165
|
+
This includes the linting and autoformatting done by Ruff, as well as some other checks.
|
|
170
166
|
|
|
171
167
|
To typecheck, run:
|
|
172
168
|
|
|
173
|
-
```
|
|
174
|
-
mypy
|
|
169
|
+
```sh
|
|
170
|
+
mypy
|
|
175
171
|
```
|
|
176
172
|
|
|
177
173
|
#### CI (and tox)
|
|
178
174
|
|
|
179
|
-
|
|
175
|
+
Style and formatting checks, and running tests on all the different supported Python versions, will be performed:
|
|
180
176
|
|
|
181
177
|
- Upon submitting a pull request.
|
|
182
178
|
- On each push, *if* you have a fork with GitHub Actions enabled.
|
|
@@ -184,10 +180,12 @@ The same linting, and running tests on all the different supported Python versio
|
|
|
184
180
|
|
|
185
181
|
#### Configuration files
|
|
186
182
|
|
|
187
|
-
Specific tools:
|
|
183
|
+
Specific tools are all configured in the `./pyproject.toml` file:
|
|
188
184
|
|
|
189
|
-
-
|
|
190
|
-
-
|
|
185
|
+
- `pytest` (test runner)
|
|
186
|
+
- `coverage.py` (code coverage)
|
|
187
|
+
- `ruff` (linter and formatter)
|
|
188
|
+
- `mypy` (type checker)
|
|
191
189
|
|
|
192
190
|
Orchestration tools:
|
|
193
191
|
|
|
@@ -242,5 +240,8 @@ Please have a look at the [contributions file][contributing].
|
|
|
242
240
|
|
|
243
241
|
[3-Clause BSD License](https://opensource.org/license/bsd-3-clause/), also known as the New BSD License. See the [LICENSE file][license].
|
|
244
242
|
|
|
243
|
+
One file exclusively used for fuzz testing is subject to [a separate license, detailed here](./fuzzing/README.md#license).
|
|
244
|
+
This file is not included in the wheel or sdist packages published by the maintainers of GitPython.
|
|
245
|
+
|
|
245
246
|
[contributing]: https://github.com/gitpython-developers/GitPython/blob/main/CONTRIBUTING.md
|
|
246
247
|
[license]: https://github.com/gitpython-developers/GitPython/blob/main/LICENSE
|
gitpython-3.1.44/VERSION
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
3.1.44
|
|
@@ -2,6 +2,21 @@
|
|
|
2
2
|
Changelog
|
|
3
3
|
=========
|
|
4
4
|
|
|
5
|
+
3.1.44
|
|
6
|
+
======
|
|
7
|
+
|
|
8
|
+
See the following for all changes.
|
|
9
|
+
https://github.com/gitpython-developers/GitPython/releases/tag/3.1.44
|
|
10
|
+
|
|
11
|
+
3.1.43
|
|
12
|
+
======
|
|
13
|
+
|
|
14
|
+
A major visible change will be the added deprecation- or user-warnings,
|
|
15
|
+
and greatly improved typing.
|
|
16
|
+
|
|
17
|
+
See the following for all changes.
|
|
18
|
+
https://github.com/gitpython-developers/GitPython/releases/tag/3.1.43
|
|
19
|
+
|
|
5
20
|
3.1.42
|
|
6
21
|
======
|
|
7
22
|
|
|
@@ -11,7 +26,7 @@ https://github.com/gitpython-developers/GitPython/releases/tag/3.1.42
|
|
|
11
26
|
3.1.41
|
|
12
27
|
======
|
|
13
28
|
|
|
14
|
-
This release is relevant for security as it fixes a possible
|
|
29
|
+
This release is relevant for security as it fixes a possible arbitrary
|
|
15
30
|
code execution on Windows.
|
|
16
31
|
|
|
17
32
|
See this PR for details: https://github.com/gitpython-developers/GitPython/pull/1792
|