This release is a pre-release and may not be stable for production use.
sshgit
Git remote operations (clone, fetch, pull, push) over SSH. Built on dulwich and paramiko.
Installation
pip install sshgit
Usage
sshgit clone <remote-path> [dest]
Clone a remote repository over SSH.
sshgit clone /home/me/project.git --host devbox --username me
sshgit clone /srv/repos/app.git --host 10.0.1.5 --port 2222 --ed25519-key ~/.ssh/id_ed25519
sshgit clone /home/me/repo.git ./local-repo --host myserver --username deploy --password
sshgit clone /opt/repos/lib.git --host bastion --rsa-key ~/.ssh/id_rsa --branch main
| Flag | Description |
|---|---|
--host HOST |
Remote hostname or IP (required) |
--username USER |
SSH username (required) |
--port PORT |
SSH port (default: 22) |
--password PASS |
SSH password |
--ed25519-key PATH |
Path to Ed25519 private key |
--rsa-key PATH |
Path to RSA private key |
--branch NAME |
Branch to check out (default: remote HEAD) |
sshgit fetch [refspec]
Fetch objects and refs from the remote. Reads connection details from .git/config.
sshgit fetch
sshgit fetch main
sshgit fetch --prune
| Flag | Description |
|---|---|
--prune |
Remove stale remote-tracking refs |
sshgit pull [branch]
Fetch and fast-forward the current branch. Refuses if the branch has diverged.
sshgit pull
sshgit pull main
sshgit push [refspec]
Push local commits to the remote.
sshgit push
sshgit push main
sshgit push --force
sshgit push --tags
| Flag | Description |
|---|---|
--force |
Allow non-fast-forward updates |
--tags |
Push all tags |
Authentication
One of --ed25519-key, --rsa-key, or --password is required on every invocation. No implicit agent or config file lookup.
| Flag | Description |
|---|---|
--ed25519-key PATH |
Path to Ed25519 private key |
--rsa-key PATH |
Path to RSA private key |
--password PASS |
SSH password |
Jump Host (Proxy)
All commands accept these optional flags for connecting through a bastion host:
| Flag | Description |
|---|---|
--proxy-host HOST |
Jump host hostname or IP |
--proxy-port PORT |
Jump host SSH port (default: 22) |
--proxy-username USER |
Jump host username (defaults to target username) |
--proxy-ed25519-key PATH |
Ed25519 key for jump host |
--proxy-rsa-key PATH |
RSA key for jump host |
--proxy-password PASS |
Jump host password |
Contributing
Contributions are welcome! Please submit pull requests or open issues on the GitHub repository.
License
This project is licensed under the MIT License.
Metadata
Release files for sshgit 0.1.0a1
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 | Actions |
|---|---|---|---|---|
| sshgit-0.1.0a1.tar.gz | 9.5 kB | Without provenance | Details for sshgit-0.1.0a1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| sshgit-0.1.0a1-py2.py3-none-any.whl | Python 3, Python 2 | none | any | Details for sshgit-0.1.0a1-py2.py3-none-any.whl |
Total release size: 19.4 kB
Release files / sshgit-0.1.0a1.tar.gz
| Download URL | sshgit-0.1.0a1.tar.gz |
|---|---|
| Size | 9.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4a4246659264130a345014d134df12eefe7586026368a9d4b80a7efd7c1ed1ac
|
|
BLAKE2b-256 checksum How to use checksums |
554d76fa4dd4067db0d96d0df952fc90bfd734cb2253d02ad3c568191a4ac10a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.13
|
Release files / sshgit-0.1.0a1-py2.py3-none-any.whl
| Download URL | sshgit-0.1.0a1-py2.py3-none-any.whl |
|---|---|
| Size | 9.9 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
a1e68293e7a0f697a895ae787679380ce54aec86d89d078d2b1116a452b69383
|
|
BLAKE2b-256 checksum How to use checksums |
76595579a7d022247a69ecf4ef92ce8063120adae7bce59a7bf3e24a6f66ad01
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.13
|
Security for sshgit 0.1.0a1
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.