Update git working directory and run commands
Project description
Run command when the upstream git branch was updated.
Example work file named git-monitor.yaml:
path: ~/work/company-website-devcommand: ansible-playbook playbook-develop-company.yml path: ~/work/company-website-prodremote: originbranch: productionforce: 1commands:- ansible-playbook playbook-deploy-company.yml
The first item ignores the default values, which are remote=origin, branch=main, force=0. If you didn’t set command, gitmon will only update the repository.
In the next example we have three additional fields:
path: ~/work/company-website-prodremote: originbranch: mainforce: 1repo_url: git@github.com:username/company-websitessh_keyfile: ~/.ssh/company-keyssh_keyfile_password: company-password
If the path is empty, we will try to create a new clone. And if the url scheme is not http, we will assume it was ssh, and if ssh_keyfile is set we will use that when cloning or updating the path.
Usage
Example:
python3 -m gitmon git-monitor.yaml
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
File details
Details for the file pygitmon-0.0.2.tar.gz
.
File metadata
- Download URL: pygitmon-0.0.2.tar.gz
- Upload date:
- Size: 41.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9785c47fc89de7ff23e2c379f224a23a0599408f960331bff1fd503286be42f7 |
|
MD5 | 853064d613e76fbb431f474718631964 |
|
BLAKE2b-256 | 290e03fe60d51e0f8a88ed25f13d1976fa1aa5495001f1651ef45765280cd5b7 |
File details
Details for the file pygitmon-0.0.2-py3-none-any.whl
.
File metadata
- Download URL: pygitmon-0.0.2-py3-none-any.whl
- Upload date:
- Size: 29.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 719a7556ef0fa62c40ff5872e465fffcb96d817189161ef4257b29b35255750d |
|
MD5 | 3c9d1ee611f0a9f9fe1595c316e99276 |
|
BLAKE2b-256 | 13043e47ad98227b146560f00174b5e47f31bf888e6dae97c22a4fc39bbd9c46 |