Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jimmycuadra/lita-travis
A Lita handler for receiving notifications from Travis CI.
https://github.com/jimmycuadra/lita-travis
chatops lita lita-handler ruby travis-ci
Last synced: about 1 month ago
JSON representation
A Lita handler for receiving notifications from Travis CI.
- Host: GitHub
- URL: https://github.com/jimmycuadra/lita-travis
- Owner: jimmycuadra
- License: mit
- Created: 2013-08-26T07:18:20.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2018-01-10T20:56:28.000Z (about 7 years ago)
- Last Synced: 2024-11-27T21:07:00.291Z (about 1 month ago)
- Topics: chatops, lita, lita-handler, ruby, travis-ci
- Language: Ruby
- Size: 208 KB
- Stars: 6
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# lita-travis
[![Build Status](https://travis-ci.org/jimmycuadra/lita-travis.png?branch=master)](https://travis-ci.org/jimmycuadra/lita-travis)
[![Code Climate](https://codeclimate.com/github/jimmycuadra/lita-travis.png)](https://codeclimate.com/github/jimmycuadra/lita-travis)
[![Coverage Status](https://coveralls.io/repos/jimmycuadra/lita-travis/badge.png)](https://coveralls.io/r/jimmycuadra/lita-travis)**lita-travis** is a [Lita](https://github.com/jimmycuadra/lita) handler for receiving notifications from [Travis CI](https://travis-ci.org/). When Travis is configured to post notifications to your Lita instance, Lita will announce the results of project builds in chat rooms of your choice.
## Installation
Add lita-travis to your Lita instance's Gemfile:
``` ruby
gem "lita-travis"
```## Configuration
### Required attributes
* `token` (String) - Your Travis CI secret token, found on your profile page on the Travis website. Default: `nil`.
### Optional attributes
* `repos` (Hash) - A hash of repositories names and the chat rooms to post their notifications in. The keys should be strings in the format "github_username/repository_name" and the values should be either a string room name or an array of string room names. Default: `{}`.
* `default_rooms` (String, Array<String>) - A string room name or an array of string room names where notifications for repositories not explicitly specified in the `repos` hash should be sent. If `nil`, notifications for unknown repositories will be ignored. Default: `nil`.### Example
``` ruby
Lita.configure do |config|
config.handlers.travis.token = "abcdefg123"
config.handlers.travis.repos = {
"username/repo1" => "#repo1_team",
"username/repo2" => ["#repo2_team", "#other_team"]
}
config.handlers.travis.default_rooms = "#engineering"
end
```## Usage
Set the configuration attributes as described in the section above, and add the following to the `.travis.yml` file for each project you want to get build notifications for:
``` yml
notifications:
webhooks:
urls:
- http://example.com/travis
```Replace "example.com" with the hostname where your instance of Lita is running.
See Travis CI's [documentation on notifications](http://about.travis-ci.org/docs/user/notifications/) for additional options.
## License
[MIT](http://opensource.org/licenses/MIT)