Skip to content

Commit

Permalink
feat: adding build number env var for compatibility with drone and ot…
Browse files Browse the repository at this point in the history
…her CI systems

s more than one blank line not allowed 38:2

s trailing spaces not allowed

s trailing spaces not allowed
  • Loading branch information
jackspirou committed Feb 8, 2016
1 parent ec5d90d commit 44eacd1
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,13 @@ Options to send to Sauce Connect. Check [here](https://github.com/bermi/sauce-co
### build
Type: `String`
Default: *One of the following environment variables*:
`process.env.TRAVIS_BUILD_NUMBER`
`process.env.BUILD_NUMBER`
`process.env.BUILD_TAG`
`process.env.CI_BUILD_NUMBER`
`process.env.CI_BUILD_TAG`
`process.env.TRAVIS_BUILD_NUMBER`
`process.env.CIRCLE_BUILD_NUM`
`process.env.DRONE_BUILD_NUMBER`

ID of the build currently running. This should be set by your CI.

Expand Down
9 changes: 6 additions & 3 deletions lib/sauce_launcher.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,13 @@ function processConfig (helper, config, args) {
tunnelIdentifier: tunnelIdentifier
})

var build = process.env.TRAVIS_BUILD_NUMBER ||
process.env.BUILD_NUMBER ||
var build = process.env.BUILD_NUMBER ||
process.env.BUILD_TAG ||
process.env.CIRCLE_BUILD_NUM
process.env.CI_BUILD_NUMBER ||
process.env.CI_BUILD_TAG ||
process.env.TRAVIS_BUILD_NUMBER ||
process.env.CIRCLE_BUILD_NUM ||
process.env.DRONE_BUILD_NUMBER

var defaults = {
version: '',
Expand Down

0 comments on commit 44eacd1

Please sign in to comment.