GitPython 3.1.42__tar.gz → 3.1.43__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.43/GitPython.egg-info}/PKG-INFO +36 -29
- GitPython-3.1.43/GitPython.egg-info/requires.txt +31 -0
- {GitPython-3.1.42/GitPython.egg-info → GitPython-3.1.43}/PKG-INFO +36 -29
- {GitPython-3.1.42 → GitPython-3.1.43}/README.md +25 -27
- GitPython-3.1.43/VERSION +1 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/doc/source/changes.rst +9 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/doc/source/conf.py +45 -46
- {GitPython-3.1.42 → GitPython-3.1.43}/doc/source/reference.rst +45 -18
- GitPython-3.1.43/git/__init__.py +300 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/git/cmd.py +541 -316
- {GitPython-3.1.42 → GitPython-3.1.43}/git/compat.py +65 -30
- {GitPython-3.1.42 → GitPython-3.1.43}/git/config.py +118 -77
- {GitPython-3.1.42 → GitPython-3.1.43}/git/db.py +16 -16
- {GitPython-3.1.42 → GitPython-3.1.43}/git/diff.py +176 -76
- {GitPython-3.1.42 → GitPython-3.1.43}/git/exc.py +14 -8
- GitPython-3.1.43/git/index/__init__.py +16 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/git/index/base.py +374 -308
- {GitPython-3.1.42 → GitPython-3.1.43}/git/index/fun.py +87 -67
- {GitPython-3.1.42 → GitPython-3.1.43}/git/index/typ.py +33 -25
- {GitPython-3.1.42 → GitPython-3.1.43}/git/index/util.py +7 -13
- GitPython-3.1.43/git/objects/__init__.py +25 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/git/objects/base.py +115 -48
- {GitPython-3.1.42 → GitPython-3.1.43}/git/objects/blob.py +17 -6
- {GitPython-3.1.42 → GitPython-3.1.43}/git/objects/commit.py +206 -136
- {GitPython-3.1.42 → GitPython-3.1.43}/git/objects/fun.py +56 -44
- GitPython-3.1.43/git/objects/submodule/__init__.py +7 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/git/objects/submodule/base.py +410 -225
- {GitPython-3.1.42 → GitPython-3.1.43}/git/objects/submodule/root.py +99 -74
- {GitPython-3.1.42 → GitPython-3.1.43}/git/objects/submodule/util.py +25 -24
- {GitPython-3.1.42 → GitPython-3.1.43}/git/objects/tag.py +47 -16
- {GitPython-3.1.42 → GitPython-3.1.43}/git/objects/tree.py +83 -62
- {GitPython-3.1.42 → GitPython-3.1.43}/git/objects/util.py +149 -110
- GitPython-3.1.43/git/refs/__init__.py +21 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/git/refs/head.py +61 -51
- {GitPython-3.1.42 → GitPython-3.1.43}/git/refs/log.py +83 -52
- {GitPython-3.1.42 → GitPython-3.1.43}/git/refs/reference.py +40 -30
- {GitPython-3.1.42 → GitPython-3.1.43}/git/refs/remote.py +15 -16
- {GitPython-3.1.42 → GitPython-3.1.43}/git/refs/symbolic.py +183 -126
- {GitPython-3.1.42 → GitPython-3.1.43}/git/refs/tag.py +34 -20
- {GitPython-3.1.42 → GitPython-3.1.43}/git/remote.py +235 -155
- {GitPython-3.1.42 → GitPython-3.1.43}/git/repo/__init__.py +4 -2
- {GitPython-3.1.42 → GitPython-3.1.43}/git/repo/base.py +370 -238
- {GitPython-3.1.42 → GitPython-3.1.43}/git/repo/fun.py +122 -96
- GitPython-3.1.43/git/types.py +284 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/git/util.py +250 -200
- {GitPython-3.1.42 → GitPython-3.1.43}/pyproject.toml +39 -7
- {GitPython-3.1.42 → GitPython-3.1.43}/setup.py +17 -13
- {GitPython-3.1.42 → GitPython-3.1.43}/test-requirements.txt +1 -1
- GitPython-3.1.42/GitPython.egg-info/requires.txt +0 -19
- GitPython-3.1.42/VERSION +0 -1
- 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 → GitPython-3.1.43}/AUTHORS +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/CHANGES +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/CONTRIBUTING.md +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/GitPython.egg-info/SOURCES.txt +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/GitPython.egg-info/dependency_links.txt +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/GitPython.egg-info/not-zip-safe +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/GitPython.egg-info/top_level.txt +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/LICENSE +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/MANIFEST.in +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/doc/.gitignore +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/doc/Makefile +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/doc/requirements.txt +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/doc/source/index.rst +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/doc/source/intro.rst +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/doc/source/quickstart.rst +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/doc/source/roadmap.rst +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/doc/source/tutorial.rst +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/git/py.typed +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/requirements.txt +0 -0
- {GitPython-3.1.42 → GitPython-3.1.43}/setup.cfg +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: GitPython
|
|
3
|
-
Version: 3.1.
|
|
3
|
+
Version: 3.1.43
|
|
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,16 @@ 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==4.3.2; extra == "doc"
|
|
46
|
+
Requires-Dist: sphinx_rtd_theme; extra == "doc"
|
|
47
|
+
Requires-Dist: sphinxcontrib-applehelp<=1.0.4,>=1.0.2; extra == "doc"
|
|
48
|
+
Requires-Dist: sphinxcontrib-devhelp==1.0.2; extra == "doc"
|
|
49
|
+
Requires-Dist: sphinxcontrib-htmlhelp<=2.0.1,>=2.0.0; extra == "doc"
|
|
50
|
+
Requires-Dist: sphinxcontrib-qthelp==1.0.3; extra == "doc"
|
|
51
|
+
Requires-Dist: sphinxcontrib-serializinghtml==1.1.5; extra == "doc"
|
|
52
|
+
Requires-Dist: sphinx-autodoc-typehints; extra == "doc"
|
|
44
53
|
|
|
45
54
|

|
|
46
55
|
[](https://readthedocs.org/projects/gitpython/?badge=stable)
|
|
@@ -61,7 +70,7 @@ probably the skills to scratch that itch of mine: implement `git` in a way that
|
|
|
61
70
|
If you like the idea and want to learn more, please head over to [gitoxide](https://github.com/Byron/gitoxide), an
|
|
62
71
|
implementation of 'git' in [Rust](https://www.rust-lang.org).
|
|
63
72
|
|
|
64
|
-
*(Please note that `gitoxide` is not currently available for use in Python, and that Rust is required)*
|
|
73
|
+
*(Please note that `gitoxide` is not currently available for use in Python, and that Rust is required.)*
|
|
65
74
|
|
|
66
75
|
## GitPython
|
|
67
76
|
|
|
@@ -83,9 +92,9 @@ The project is open to contributions of all kinds, as well as new maintainers.
|
|
|
83
92
|
|
|
84
93
|
### REQUIREMENTS
|
|
85
94
|
|
|
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.
|
|
95
|
+
GitPython needs the `git` executable to be installed on the system and available in your
|
|
96
|
+
`PATH` for most operations. If it is not in your `PATH`, you can help GitPython find it
|
|
97
|
+
by setting the `GIT_PYTHON_GIT_EXECUTABLE=<path/to/git>` environment variable.
|
|
89
98
|
|
|
90
99
|
- Git (1.7.x or newer)
|
|
91
100
|
- Python >= 3.7
|
|
@@ -101,7 +110,7 @@ GitPython and its required package dependencies can be installed in any of the f
|
|
|
101
110
|
|
|
102
111
|
To obtain and install a copy [from PyPI](https://pypi.org/project/GitPython/), run:
|
|
103
112
|
|
|
104
|
-
```
|
|
113
|
+
```sh
|
|
105
114
|
pip install GitPython
|
|
106
115
|
```
|
|
107
116
|
|
|
@@ -111,7 +120,7 @@ pip install GitPython
|
|
|
111
120
|
|
|
112
121
|
If you have downloaded the source code, run this from inside the unpacked `GitPython` directory:
|
|
113
122
|
|
|
114
|
-
```
|
|
123
|
+
```sh
|
|
115
124
|
pip install .
|
|
116
125
|
```
|
|
117
126
|
|
|
@@ -119,7 +128,7 @@ pip install .
|
|
|
119
128
|
|
|
120
129
|
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
130
|
|
|
122
|
-
```
|
|
131
|
+
```sh
|
|
123
132
|
git clone https://github.com/gitpython-developers/GitPython
|
|
124
133
|
cd GitPython
|
|
125
134
|
./init-tests-after-clone.sh
|
|
@@ -129,7 +138,7 @@ On Windows, `./init-tests-after-clone.sh` can be run in a Git Bash shell.
|
|
|
129
138
|
|
|
130
139
|
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
140
|
|
|
132
|
-
```
|
|
141
|
+
```sh
|
|
133
142
|
gh repo clone GitPython
|
|
134
143
|
```
|
|
135
144
|
|
|
@@ -137,7 +146,7 @@ Having cloned the repo, create and activate your [virtual environment](https://d
|
|
|
137
146
|
|
|
138
147
|
Then make an [editable install](https://pip.pypa.io/en/stable/topics/local-project-installs/#editable-installs):
|
|
139
148
|
|
|
140
|
-
```
|
|
149
|
+
```sh
|
|
141
150
|
pip install -e ".[test]"
|
|
142
151
|
```
|
|
143
152
|
|
|
@@ -149,7 +158,7 @@ In rare cases, you may want to work on GitPython and one or both of its [gitdb](
|
|
|
149
158
|
|
|
150
159
|
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
160
|
|
|
152
|
-
```
|
|
161
|
+
```sh
|
|
153
162
|
pip install -e ".[test]" -e git/ext/gitdb -e git/ext/gitdb/gitdb/ext/smmap
|
|
154
163
|
```
|
|
155
164
|
|
|
@@ -185,42 +194,38 @@ you will encounter test failures.
|
|
|
185
194
|
|
|
186
195
|
Ensure testing libraries are installed. This is taken care of already if you installed with:
|
|
187
196
|
|
|
188
|
-
```
|
|
197
|
+
```sh
|
|
189
198
|
pip install -e ".[test]"
|
|
190
199
|
```
|
|
191
200
|
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
```bash
|
|
195
|
-
pip install -r test-requirements.txt
|
|
196
|
-
```
|
|
201
|
+
If you had installed with a command like `pip install -e .` instead, you can still run
|
|
202
|
+
the above command to add the testing dependencies.
|
|
197
203
|
|
|
198
204
|
#### Test commands
|
|
199
205
|
|
|
200
206
|
To test, run:
|
|
201
207
|
|
|
202
|
-
```
|
|
208
|
+
```sh
|
|
203
209
|
pytest
|
|
204
210
|
```
|
|
205
211
|
|
|
206
|
-
To lint, and apply automatic code formatting, run:
|
|
212
|
+
To lint, and apply some linting fixes as well as automatic code formatting, run:
|
|
207
213
|
|
|
208
|
-
```
|
|
214
|
+
```sh
|
|
209
215
|
pre-commit run --all-files
|
|
210
216
|
```
|
|
211
217
|
|
|
212
|
-
|
|
213
|
-
- Auto-formatting without other lint checks can be done with: `black .`
|
|
218
|
+
This includes the linting and autoformatting done by Ruff, as well as some other checks.
|
|
214
219
|
|
|
215
220
|
To typecheck, run:
|
|
216
221
|
|
|
217
|
-
```
|
|
218
|
-
mypy
|
|
222
|
+
```sh
|
|
223
|
+
mypy
|
|
219
224
|
```
|
|
220
225
|
|
|
221
226
|
#### CI (and tox)
|
|
222
227
|
|
|
223
|
-
|
|
228
|
+
Style and formatting checks, and running tests on all the different supported Python versions, will be performed:
|
|
224
229
|
|
|
225
230
|
- Upon submitting a pull request.
|
|
226
231
|
- On each push, *if* you have a fork with GitHub Actions enabled.
|
|
@@ -228,10 +233,12 @@ The same linting, and running tests on all the different supported Python versio
|
|
|
228
233
|
|
|
229
234
|
#### Configuration files
|
|
230
235
|
|
|
231
|
-
Specific tools:
|
|
236
|
+
Specific tools are all configured in the `./pyproject.toml` file:
|
|
232
237
|
|
|
233
|
-
-
|
|
234
|
-
-
|
|
238
|
+
- `pytest` (test runner)
|
|
239
|
+
- `coverage.py` (code coverage)
|
|
240
|
+
- `ruff` (linter and formatter)
|
|
241
|
+
- `mypy` (type checker)
|
|
235
242
|
|
|
236
243
|
Orchestration tools:
|
|
237
244
|
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
gitdb<5,>=4.0.1
|
|
2
|
+
|
|
3
|
+
[:python_version < "3.8"]
|
|
4
|
+
typing-extensions>=3.7.4.3
|
|
5
|
+
|
|
6
|
+
[doc]
|
|
7
|
+
sphinx==4.3.2
|
|
8
|
+
sphinx_rtd_theme
|
|
9
|
+
sphinxcontrib-applehelp<=1.0.4,>=1.0.2
|
|
10
|
+
sphinxcontrib-devhelp==1.0.2
|
|
11
|
+
sphinxcontrib-htmlhelp<=2.0.1,>=2.0.0
|
|
12
|
+
sphinxcontrib-qthelp==1.0.3
|
|
13
|
+
sphinxcontrib-serializinghtml==1.1.5
|
|
14
|
+
sphinx-autodoc-typehints
|
|
15
|
+
|
|
16
|
+
[test]
|
|
17
|
+
coverage[toml]
|
|
18
|
+
ddt!=1.4.3,>=1.1.1
|
|
19
|
+
mypy
|
|
20
|
+
pre-commit
|
|
21
|
+
pytest>=7.3.1
|
|
22
|
+
pytest-cov
|
|
23
|
+
pytest-instafail
|
|
24
|
+
pytest-mock
|
|
25
|
+
pytest-sugar
|
|
26
|
+
|
|
27
|
+
[test:python_version < "3.11"]
|
|
28
|
+
typing-extensions
|
|
29
|
+
|
|
30
|
+
[test:python_version < "3.8"]
|
|
31
|
+
mock
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: GitPython
|
|
3
|
-
Version: 3.1.
|
|
3
|
+
Version: 3.1.43
|
|
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,16 @@ 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==4.3.2; extra == "doc"
|
|
46
|
+
Requires-Dist: sphinx_rtd_theme; extra == "doc"
|
|
47
|
+
Requires-Dist: sphinxcontrib-applehelp<=1.0.4,>=1.0.2; extra == "doc"
|
|
48
|
+
Requires-Dist: sphinxcontrib-devhelp==1.0.2; extra == "doc"
|
|
49
|
+
Requires-Dist: sphinxcontrib-htmlhelp<=2.0.1,>=2.0.0; extra == "doc"
|
|
50
|
+
Requires-Dist: sphinxcontrib-qthelp==1.0.3; extra == "doc"
|
|
51
|
+
Requires-Dist: sphinxcontrib-serializinghtml==1.1.5; extra == "doc"
|
|
52
|
+
Requires-Dist: sphinx-autodoc-typehints; extra == "doc"
|
|
44
53
|
|
|
45
54
|

|
|
46
55
|
[](https://readthedocs.org/projects/gitpython/?badge=stable)
|
|
@@ -61,7 +70,7 @@ probably the skills to scratch that itch of mine: implement `git` in a way that
|
|
|
61
70
|
If you like the idea and want to learn more, please head over to [gitoxide](https://github.com/Byron/gitoxide), an
|
|
62
71
|
implementation of 'git' in [Rust](https://www.rust-lang.org).
|
|
63
72
|
|
|
64
|
-
*(Please note that `gitoxide` is not currently available for use in Python, and that Rust is required)*
|
|
73
|
+
*(Please note that `gitoxide` is not currently available for use in Python, and that Rust is required.)*
|
|
65
74
|
|
|
66
75
|
## GitPython
|
|
67
76
|
|
|
@@ -83,9 +92,9 @@ The project is open to contributions of all kinds, as well as new maintainers.
|
|
|
83
92
|
|
|
84
93
|
### REQUIREMENTS
|
|
85
94
|
|
|
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.
|
|
95
|
+
GitPython needs the `git` executable to be installed on the system and available in your
|
|
96
|
+
`PATH` for most operations. If it is not in your `PATH`, you can help GitPython find it
|
|
97
|
+
by setting the `GIT_PYTHON_GIT_EXECUTABLE=<path/to/git>` environment variable.
|
|
89
98
|
|
|
90
99
|
- Git (1.7.x or newer)
|
|
91
100
|
- Python >= 3.7
|
|
@@ -101,7 +110,7 @@ GitPython and its required package dependencies can be installed in any of the f
|
|
|
101
110
|
|
|
102
111
|
To obtain and install a copy [from PyPI](https://pypi.org/project/GitPython/), run:
|
|
103
112
|
|
|
104
|
-
```
|
|
113
|
+
```sh
|
|
105
114
|
pip install GitPython
|
|
106
115
|
```
|
|
107
116
|
|
|
@@ -111,7 +120,7 @@ pip install GitPython
|
|
|
111
120
|
|
|
112
121
|
If you have downloaded the source code, run this from inside the unpacked `GitPython` directory:
|
|
113
122
|
|
|
114
|
-
```
|
|
123
|
+
```sh
|
|
115
124
|
pip install .
|
|
116
125
|
```
|
|
117
126
|
|
|
@@ -119,7 +128,7 @@ pip install .
|
|
|
119
128
|
|
|
120
129
|
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
130
|
|
|
122
|
-
```
|
|
131
|
+
```sh
|
|
123
132
|
git clone https://github.com/gitpython-developers/GitPython
|
|
124
133
|
cd GitPython
|
|
125
134
|
./init-tests-after-clone.sh
|
|
@@ -129,7 +138,7 @@ On Windows, `./init-tests-after-clone.sh` can be run in a Git Bash shell.
|
|
|
129
138
|
|
|
130
139
|
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
140
|
|
|
132
|
-
```
|
|
141
|
+
```sh
|
|
133
142
|
gh repo clone GitPython
|
|
134
143
|
```
|
|
135
144
|
|
|
@@ -137,7 +146,7 @@ Having cloned the repo, create and activate your [virtual environment](https://d
|
|
|
137
146
|
|
|
138
147
|
Then make an [editable install](https://pip.pypa.io/en/stable/topics/local-project-installs/#editable-installs):
|
|
139
148
|
|
|
140
|
-
```
|
|
149
|
+
```sh
|
|
141
150
|
pip install -e ".[test]"
|
|
142
151
|
```
|
|
143
152
|
|
|
@@ -149,7 +158,7 @@ In rare cases, you may want to work on GitPython and one or both of its [gitdb](
|
|
|
149
158
|
|
|
150
159
|
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
160
|
|
|
152
|
-
```
|
|
161
|
+
```sh
|
|
153
162
|
pip install -e ".[test]" -e git/ext/gitdb -e git/ext/gitdb/gitdb/ext/smmap
|
|
154
163
|
```
|
|
155
164
|
|
|
@@ -185,42 +194,38 @@ you will encounter test failures.
|
|
|
185
194
|
|
|
186
195
|
Ensure testing libraries are installed. This is taken care of already if you installed with:
|
|
187
196
|
|
|
188
|
-
```
|
|
197
|
+
```sh
|
|
189
198
|
pip install -e ".[test]"
|
|
190
199
|
```
|
|
191
200
|
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
```bash
|
|
195
|
-
pip install -r test-requirements.txt
|
|
196
|
-
```
|
|
201
|
+
If you had installed with a command like `pip install -e .` instead, you can still run
|
|
202
|
+
the above command to add the testing dependencies.
|
|
197
203
|
|
|
198
204
|
#### Test commands
|
|
199
205
|
|
|
200
206
|
To test, run:
|
|
201
207
|
|
|
202
|
-
```
|
|
208
|
+
```sh
|
|
203
209
|
pytest
|
|
204
210
|
```
|
|
205
211
|
|
|
206
|
-
To lint, and apply automatic code formatting, run:
|
|
212
|
+
To lint, and apply some linting fixes as well as automatic code formatting, run:
|
|
207
213
|
|
|
208
|
-
```
|
|
214
|
+
```sh
|
|
209
215
|
pre-commit run --all-files
|
|
210
216
|
```
|
|
211
217
|
|
|
212
|
-
|
|
213
|
-
- Auto-formatting without other lint checks can be done with: `black .`
|
|
218
|
+
This includes the linting and autoformatting done by Ruff, as well as some other checks.
|
|
214
219
|
|
|
215
220
|
To typecheck, run:
|
|
216
221
|
|
|
217
|
-
```
|
|
218
|
-
mypy
|
|
222
|
+
```sh
|
|
223
|
+
mypy
|
|
219
224
|
```
|
|
220
225
|
|
|
221
226
|
#### CI (and tox)
|
|
222
227
|
|
|
223
|
-
|
|
228
|
+
Style and formatting checks, and running tests on all the different supported Python versions, will be performed:
|
|
224
229
|
|
|
225
230
|
- Upon submitting a pull request.
|
|
226
231
|
- On each push, *if* you have a fork with GitHub Actions enabled.
|
|
@@ -228,10 +233,12 @@ The same linting, and running tests on all the different supported Python versio
|
|
|
228
233
|
|
|
229
234
|
#### Configuration files
|
|
230
235
|
|
|
231
|
-
Specific tools:
|
|
236
|
+
Specific tools are all configured in the `./pyproject.toml` file:
|
|
232
237
|
|
|
233
|
-
-
|
|
234
|
-
-
|
|
238
|
+
- `pytest` (test runner)
|
|
239
|
+
- `coverage.py` (code coverage)
|
|
240
|
+
- `ruff` (linter and formatter)
|
|
241
|
+
- `mypy` (type checker)
|
|
235
242
|
|
|
236
243
|
Orchestration tools:
|
|
237
244
|
|
|
@@ -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
|
|
|
@@ -105,7 +105,7 @@ In rare cases, you may want to work on GitPython and one or both of its [gitdb](
|
|
|
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
|
|
GitPython-3.1.43/VERSION
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
3.1.43
|
|
@@ -2,6 +2,15 @@
|
|
|
2
2
|
Changelog
|
|
3
3
|
=========
|
|
4
4
|
|
|
5
|
+
3.1.43
|
|
6
|
+
======
|
|
7
|
+
|
|
8
|
+
A major visible change will be the added deprecation- or user-warnings,
|
|
9
|
+
and greatly improved typing.
|
|
10
|
+
|
|
11
|
+
See the following for all changes.
|
|
12
|
+
https://github.com/gitpython-developers/GitPython/releases/tag/3.1.43
|
|
13
|
+
|
|
5
14
|
3.1.42
|
|
6
15
|
======
|
|
7
16
|
|