An incomplete Python 3 wrapper for the GitHub API
Project description
commitment
An incomplete Python 3 wrapper for the GitHub API.
Note this project does not aim to provide a complete abstraction over the GitHub API - just a few high-level convenience methods for pushing data to a GitHub repo.
Installation
pip install commitment
Usage
Generate a GitHub API key: https://github.com/settings/tokens
from commitment import GitHubCredentials, GitHubClient
credentials = GitHubCredentials(
repo="myuser/somerepo",
name="myuser",
email="someone@example.com",
api_key="f00b42",
)
client = GitHubClient(credentials)
client.create_branch('my_new_branch', base_branch='master')
client.push_file('Hello World!', 'directory/filename.txt', 'my commit message', branch='my_new_branch')
client.open_pull_request('my_new_branch', 'title', 'body', base_branch='master')
Versioning
commitment follows semantic versioning.
From version 4 onwards, commitment will drop compatibility with unsupported python versions without incrementing the major version. This is in line with common practice in the python community.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file commitment-4.1.1.tar.gz.
File metadata
- Download URL: commitment-4.1.1.tar.gz
- Upload date:
- Size: 3.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
56b49bd473576caf44b936113ad19441c315d67bde9fd85197dd42c475ddaab4
|
|
| MD5 |
e2d5621d95c8250af0c7c848b6fee791
|
|
| BLAKE2b-256 |
4001206cd6d206ef8e41dbcfe3cf82798ad312b1b1312256219396ba40682b64
|
Provenance
The following attestation bundles were made for commitment-4.1.1.tar.gz:
Publisher:
publish.yml on chris48s/commitment
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
commitment-4.1.1.tar.gz -
Subject digest:
56b49bd473576caf44b936113ad19441c315d67bde9fd85197dd42c475ddaab4 - Sigstore transparency entry: 630384790
- Sigstore integration time:
-
Permalink:
chris48s/commitment@ce77264216c5ff98f56d3521d193b6b13bb85369 -
Branch / Tag:
refs/tags/4.1.1 - Owner: https://github.com/chris48s
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@ce77264216c5ff98f56d3521d193b6b13bb85369 -
Trigger Event:
create
-
Statement type:
File details
Details for the file commitment-4.1.1-py3-none-any.whl.
File metadata
- Download URL: commitment-4.1.1-py3-none-any.whl
- Upload date:
- Size: 4.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
12b24e14f7f6948e2c5b2d32e2ca8c7ccd6f00dcff417470de2574743778ebad
|
|
| MD5 |
cd928b970703b44a90b8b3dc39228992
|
|
| BLAKE2b-256 |
fbe259652974f907147c2b8eca9244819bf2c5e843d9cc400dc0f6fb0caccce6
|
Provenance
The following attestation bundles were made for commitment-4.1.1-py3-none-any.whl:
Publisher:
publish.yml on chris48s/commitment
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
commitment-4.1.1-py3-none-any.whl -
Subject digest:
12b24e14f7f6948e2c5b2d32e2ca8c7ccd6f00dcff417470de2574743778ebad - Sigstore transparency entry: 630384792
- Sigstore integration time:
-
Permalink:
chris48s/commitment@ce77264216c5ff98f56d3521d193b6b13bb85369 -
Branch / Tag:
refs/tags/4.1.1 - Owner: https://github.com/chris48s
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@ce77264216c5ff98f56d3521d193b6b13bb85369 -
Trigger Event:
create
-
Statement type: