Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/danielwhatmuff/trigger-travis
Python CLI to kick off travis jobs on a particular branch and optionally inject environment variables
https://github.com/danielwhatmuff/trigger-travis
ci cli continuous-deployment continuous-integration continuous-testing devops python travis travis-ci
Last synced: about 1 month ago
JSON representation
Python CLI to kick off travis jobs on a particular branch and optionally inject environment variables
- Host: GitHub
- URL: https://github.com/danielwhatmuff/trigger-travis
- Owner: danielwhatmuff
- Created: 2017-07-05T22:39:11.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-10-23T00:25:56.000Z (about 5 years ago)
- Last Synced: 2024-12-06T21:31:21.124Z (about 1 month ago)
- Topics: ci, cli, continuous-deployment, continuous-integration, continuous-testing, devops, python, travis, travis-ci
- Language: Python
- Size: 11.7 KB
- Stars: 2
- Watchers: 1
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: HISTORY.rst
Awesome Lists containing this project
README
# trigger-travis
![](https://cdn.travis-ci.com/images/logos/TravisCI-Full-Color-45e242791b7752b745a7ae53f265acd4.png)## Overview
* Install and execute this CLI to trigger Travis CI builds on a particular branch, optionally overriding env vars or the script section
* For more information, see https://docs.travis-ci.com/user/triggering-builds/### Get a token from Travis-ci.org
```yaml
travis login --org
travis token --org
```### Get a token from Travis-ci.com
```yaml
travis login --org --pro
travis token --org --pro
```### Install the CLI and view the available options
```yaml
$ pip install trigger-travis
$ trigger-travis --help
```### Example of running a build and passing environment variables
```yaml
$ trigger-travis -t yourtoken -r yourorg/yourrepo --branch develop --env SOMEENV=value,ANOTHERENV=anothervalue --mergemode deep_merge --pro
```### Example of running a build and overriding the commit message
```yaml
$ trigger-travis -t yourtoken -c 'This build was triggered by the API' --branch master
```### Example of running a build and overriding the script
```yaml
$ trigger-travis -t yourtoken -s 'exit 0' -m replace --branch master
```## Related docs
* [Travis Build Docs](https://docs.travis-ci.com/user/customizing-the-build)
* [Triggering Builds APIv3](https://docs.travis-ci.com/user/triggering-builds/)## Known issues
* Encrypted environment variables defined within your travis.yml don't work with the deep_merge option - you must define them in the repo settings using the Travis UI, this is a limitation with Travis...