Publish private PRs.
Project description
publishprs: Publish private pull requests in a public repo
Install:
pip install publishprs
Connect to the LaminDB instance to be used for assets management:
lamin connect account/instance
Export API tokens for GitHub's API:
export GITHUB_SOURCE_TOKEN=... # token with access to source repo, to process assets, needs to be a classic token
export GITHUB_TARGET_TOKEN=... # token with access to target repo, to assign original user identity, should be fine-grained and issued by the original user account
Publish a PR:
from publishprs import Publisher
publisher = Publisher(
source_repo="https://github.com/laminlabs/laminhub",
target_repo="https://github.com/laminlabs/laminhub-public",
)
url = publisher.publish(pull_id=3820)
print(f"Published to: {url}")
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
publishprs-1.0.0.tar.gz
(12.2 kB
view details)
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 publishprs-1.0.0.tar.gz.
File metadata
- Download URL: publishprs-1.0.0.tar.gz
- Upload date:
- Size: 12.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: python-requests/2.32.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1391f6f2dbfa5920682053be040f2b765824fd828a6656b14249f733070f6c5b
|
|
| MD5 |
9f8bde630f2716238eb7a495f8d679a9
|
|
| BLAKE2b-256 |
a5fc4112da4143fb905940cf940d8e10d99a81ff53f487a8488c702e15dde3f5
|
File details
Details for the file publishprs-1.0.0-py3-none-any.whl.
File metadata
- Download URL: publishprs-1.0.0-py3-none-any.whl
- Upload date:
- Size: 9.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: python-requests/2.32.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
485020f8ffad837ba0d7cc5b793acfe988a7c37c1996b4b4b506dae490312f55
|
|
| MD5 |
5717552e266d4f988aab57a15a8bdbf5
|
|
| BLAKE2b-256 |
4919df60bc99ef55ade1a7a8063df408049afb97623e8482fa00b01a719ab085
|