Using Travis CI

Travis CI is a hosted service for continuous integration. It is very tightly coupled to GitHub (which is why you will need a Git repository on GitHub to actually use Travis CI). It is free to use for open source projects, which, together with its good GitHub integration, makes it the go-to choice for many popular projects. For building private GitHub projects, there is a paid usage model.

The configuration of your Travis build is done by a .travis.yml file that needs to be present at the root level of your repository. Basically, this file can look like this:

language: go 
go: 
  - 1.6 
  - 1.7 
  - 1.8   - 1.9
env: 
  - CGO_ENABLED=0 
 
install: true 
script: 
  - go build 

The language property describes which programming language your project ...

Get Cloud Native programming with Golang now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.