Simple Python wrapper for Git
Provides access to Commit objects and easy branch listing.
- License: 3-Clause BSD
- Python: Python 3.6+
Table of Contents
Installation
Install using pip:
python3 -m pip install atudomain-git --user
Alternatively, you can just append downloaded repository path to PYTHONPATH.
Quickstart
Import Git class:
from atudomain.git import Git
Create Git object:
git = Git('/home/user/example-repo')
Getting branches
Get list of remote origin branches:
branches = git.get_branches(include='^remotes/origin')
Get list of local branches:
branches = git.get_branches(exclude='^remotes/')
Getting Commits
Get list of Commits for the current branch:
commits = git.get_commits()
Get list with last Commit for the current branch:
commits = git.get_commits('HEAD^..HEAD')
Getting Commit details
Get committer date from Commit:
committer_date = commits[0].committer_date
Get commit id from Commit:
commit_id = commits[0].commit_id
Check if Commit is a merge:
is_merge = commits[0].is_merge
API Documentation
Metadata
Release files for atudomain-git 4.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| atudomain-git-4.0.0.tar.gz | 11.7 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| atudomain_git-4.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 22.7 kB
Release files / atudomain-git-4.0.0.tar.gz
| Download URL | atudomain-git-4.0.0.tar.gz |
|---|---|
| Size | 11.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
291f643d69862980088742cb23a8bc4289b555e24462034fce5fe9075839a09d
|
|
BLAKE2b-256 checksum How to use checksums |
eb26c464b3946f982834bf3973c6f53e6359640534d8146f88aa09d38930d181
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.6.13
|
Release files / atudomain_git-4.0.0-py3-none-any.whl
| Download URL | atudomain_git-4.0.0-py3-none-any.whl |
|---|---|
| Size | 11.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b4bf090a0ff28d7df0ef4af7e42d6a0d27862be82141ab0dd44bc543a29ad78e
|
|
BLAKE2b-256 checksum How to use checksums |
9822ec910db9899a39d87d2030bf916658787dd45303234a41f685bf376f6b51
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.6.13
|
Security for atudomain-git 4.0.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.