From e3106949a58390333db645fe5e1040bc3849c2f5 Mon Sep 17 00:00:00 2001 From: Jonathan Porta Date: Mon, 10 Nov 2014 16:41:01 -0800 Subject: Document possible command line params --- README.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/README.md b/README.md index 3223f42..7d62da3 100644 --- a/README.md +++ b/README.md @@ -109,6 +109,13 @@ Client-side JS code coverage using [PhantomJS](https://github.com/ariya/phantomj lab -r lcov | ./node_modules/.bin/coveralls ``` +### Command Line Parameters +Usage: coveralls.js [-v] filepath + +#### Optional arguments: + +-v, --verbose +filepath - optionally defines the base filepath of your source files. ## Running locally -- cgit v1.2.3 From 701abbcec5f43cd1387e3a9f9d041243f419f17c Mon Sep 17 00:00:00 2001 From: Jonathan Porta Date: Mon, 10 Nov 2014 16:41:42 -0800 Subject: Typo --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 7d62da3..a73e7bb 100644 --- a/README.md +++ b/README.md @@ -115,6 +115,7 @@ Usage: coveralls.js [-v] filepath #### Optional arguments: -v, --verbose + filepath - optionally defines the base filepath of your source files. ## Running locally -- cgit v1.2.3 From 6d2e7203351b34dd53eed0dee796d93e0e10d4e7 Mon Sep 17 00:00:00 2001 From: Jacob Meacham Date: Thu, 29 Jan 2015 00:06:09 -0800 Subject: allow users to pass options through. --- lib/getOptions.js | 11 +++++++++-- lib/handleInput.js | 7 ++++--- test/getOptions.js | 8 ++++++++ 3 files changed, 21 insertions(+), 5 deletions(-) diff --git a/lib/getOptions.js b/lib/getOptions.js index eab67f4..9713f03 100644 --- a/lib/getOptions.js +++ b/lib/getOptions.js @@ -108,11 +108,13 @@ var getBaseOptions = function(cb){ } }; -var getOptions = function(cb){ +var getOptions = function(cb, _userOptions){ if (!cb){ throw new Error('getOptions requires a callback'); } + var userOptions = _userOptions || {}; + getBaseOptions(function(err, options){ // try to get filepath from the command-line if (process.argv[2]) { @@ -124,7 +126,12 @@ var getOptions = function(cb){ options.filepath = process.argv[2]; } } - cb(err, options); + + // lodash or else would be better, but no need for the extra dependency + for (var option in userOptions) { + options[option] = userOptions[option]; + } + cb(err, options); }); }; diff --git a/lib/handleInput.js b/lib/handleInput.js index 5f88394..845bfad 100644 --- a/lib/handleInput.js +++ b/lib/handleInput.js @@ -1,9 +1,10 @@ var index = require('../index'); var logger = require('./logger')(); -function handleInput(input, cb) { +function handleInput(input, cb, userOptions) { logger.debug(input); - var options = index.getOptions(function(err, options){ + logger.debug('user options ' + userOptions); + index.getOptions(function(err, options){ if (err){ logger.error("error from getOptions"); @@ -33,7 +34,7 @@ function handleInput(input, cb) { cb(null); }); }); - }); + }, userOptions); } module.exports = handleInput; diff --git a/test/getOptions.js b/test/getOptions.js index 8a77708..6f9ddc5 100644 --- a/test/getOptions.js +++ b/test/getOptions.js @@ -135,6 +135,14 @@ describe("getOptions", function(){ it ("should set service_name and service_job_id if it's running on wercker", function(done){ testWercker(getOptions, done); }); + it ("should override set options with user options", function(done){ + var userOptions = {service_name: 'OVERRIDDEN_SERVICE_NAME'}; + process.env.COVERALLS_SERVICE_NAME = "SERVICE_NAME"; + getOptions(function(err, options){ + options.service_name.should.equal("OVERRIDDEN_SERVICE_NAME"); + done(); + }, userOptions); + }); }); var testServiceJobId = function(sut, done){ -- cgit v1.2.3 From 199d15ee8b7215e84cb1b133bd913ed718b84da2 Mon Sep 17 00:00:00 2001 From: "Merrifield, Jay" Date: Tue, 21 Apr 2015 13:53:13 -0400 Subject: Added support for service_pull_request in jenkins using the github pull request plugin's environment variables --- lib/convertLcovToCoveralls.js | 3 +++ lib/getOptions.js | 1 + 2 files changed, 4 insertions(+) diff --git a/lib/convertLcovToCoveralls.js b/lib/convertLcovToCoveralls.js index 3f604e1..37add87 100644 --- a/lib/convertLcovToCoveralls.js +++ b/lib/convertLcovToCoveralls.js @@ -48,6 +48,9 @@ var convertLcovToCoveralls = function(input, options, cb){ if (options.service_job_id){ postJson.service_job_id = options.service_job_id; } + if (options.service_pull_request){ + postJson.service_pull_request = options.service_pull_request; + } if (options.repo_token) { postJson.repo_token = options.repo_token; } diff --git a/lib/getOptions.js b/lib/getOptions.js index eab67f4..95a9577 100644 --- a/lib/getOptions.js +++ b/lib/getOptions.js @@ -28,6 +28,7 @@ var getBaseOptions = function(cb){ if (process.env.JENKINS_URL){ options.service_name = 'jenkins'; options.service_job_id = process.env.BUILD_ID; + options.service_pull_request = process.env.ghprbPullId; git_commit = process.env.GIT_COMMIT; git_branch = process.env.GIT_BRANCH; } -- cgit v1.2.3 From 375ad5ea62e7ee4a2eb376f27cfa080da7633784 Mon Sep 17 00:00:00 2001 From: Nick Merwin Date: Thu, 2 Jul 2015 10:21:37 -0700 Subject: updated travis badge --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index e80df74..48f9a5a 100644 --- a/README.md +++ b/README.md @@ -115,8 +115,8 @@ If you're running locally, you must have a `.coveralls.yml` file, as documented If you want to send commit data to coveralls, you can set the `COVERALLS_GIT_COMMIT` environment-variable to the commit hash you wish to reference. If you don't want to use a hash, you can set it to `HEAD` to supply coveralls with the latest commit data. This requires git to be installed and executable on the current PATH. -[travis-image]: https://travis-ci.org/cainus/node-coveralls.svg?branch=master -[travis-url]: https://travis-ci.org/cainus/node-coveralls +[travis-image]: https://travis-ci.org/nickmerwin/node-coveralls.svg?branch=master +[travis-url]: https://travis-ci.org/nickmerwin/node-coveralls [codeship-image]: https://www.codeship.io/projects/de6fb440-dea9-0130-e7d9-122ca7ee39d3/status [codeship-url]: https://www.codeship.io/projects/5622 -- cgit v1.2.3 From 249e4673a1f5b956428b0334ac3d19184409cc3b Mon Sep 17 00:00:00 2001 From: Joshua Ma Date: Mon, 13 Jul 2015 20:05:32 -0700 Subject: Fix parsing git message with REGEX_COMMIT_DETAILS Given the commit message ``` tree 2d257d54add0901a72fbe492538aec4a35b4f4a5 parent 21d9ce4eb278af46561e069d6410e72a88c38036 author Joshua Ma 1436838814 -0700 committer Joshua Ma 1436839048 -0700 main message secondary detail ``` REGEX_COMMIT_DETAILS previously incorrectly matched `secondary detail` as the message - it lets an optional newline match (A), followed by nongreedy `[\S\s]+`, until a double-newline (B) is found. The message used is what follows B. Since there's two double-newlines, before `main message` and `secondary detail`, the first double-newline is used towards (A) and the second set is the one that matches (B). So the message ends up being `secondary detail`. This change simplifies the regex to just a nongreedy `[\S\s]*` until the first double-newline, after which the message is expected. --- lib/fetchGitData.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/fetchGitData.js b/lib/fetchGitData.js index 67b6190..0c516d3 100644 --- a/lib/fetchGitData.js +++ b/lib/fetchGitData.js @@ -59,7 +59,7 @@ function fetchBranch(git, cb) { }); } -var REGEX_COMMIT_DETAILS = /\nauthor (.+?) <(.+?)>.+\ncommitter (.+?) <(.+?)>.+\n?[\S\s]+?\n\n(.*)/m; +var REGEX_COMMIT_DETAILS = /\nauthor (.+?) <(.+?)>.+\ncommitter (.+?) <(.+?)>.+[\S\s]*?\n\n(.*)/m; function fetchHeadDetails(git, cb) { exec('git cat-file -p ' + git.head.id, function(err, response) { -- cgit v1.2.3 From 64653c6df1d63065b0fb0b4984ac4c88f809b068 Mon Sep 17 00:00:00 2001 From: Nick Merwin Date: Mon, 13 Jul 2015 22:21:19 -0700 Subject: package updated version + maintainers README badges updates --- README.md | 21 +++++++++------------ package.json | 6 ++++-- 2 files changed, 13 insertions(+), 14 deletions(-) diff --git a/README.md b/README.md index 48f9a5a..870e11e 100644 --- a/README.md +++ b/README.md @@ -6,15 +6,15 @@ Supported CI services: [travis-ci](https://travis-ci.org/), [codeship](https://www.codeship.io/), [circle-ci](https://circleci.com/), [jenkins](http://jenkins-ci.org/) -##Installation: +##Installation: Add the latest version of `coveralls` to your package.json: -``` -npm install coveralls --save +``` +npm install coveralls --save ``` If you're using mocha, add `mocha-lcov-reporter` to your package.json: -``` -npm install mocha-lcov-reporter --save +``` +npm install mocha-lcov-reporter --save ``` ##Usage: @@ -29,7 +29,7 @@ This library currently supports [travis-ci](https://travis-ci.org/) with no extr There are optional environment variables for other build systems as well: * COVERALLS_SERVICE_JOB_ID (an id that uniquely identifies the build job) -* COVERALLS_RUN_AT (a date string for the time that the job ran. RFC 3339 dates work. This defaults to your +* COVERALLS_RUN_AT (a date string for the time that the job ran. RFC 3339 dates work. This defaults to your build system's date/time if you don't set it.) ### [Mocha](http://mochajs.org/) + [Blanket.js](https://github.com/alex-seville/blanket) @@ -44,7 +44,7 @@ NODE_ENV=test YOURPACKAGE_COVERAGE=1 ./node_modules/.bin/mocha \ ``` ### [Mocha](http://mochajs.org/) + [JSCoverage](https://github.com/fishbar/jscoverage) -Instrumenting your app for coverage is probably harder than it needs to be (read [here](http://www.seejohncode.com/2012/03/13/setting-up-mocha-jscoverage/)), but that's also a necessary step. +Instrumenting your app for coverage is probably harder than it needs to be (read [here](http://www.seejohncode.com/2012/03/13/setting-up-mocha-jscoverage/)), but that's also a necessary step. In mocha, if you've got your code instrumented for coverage, the command for a travis build would look something like this: ```sh @@ -121,14 +121,11 @@ If you want to send commit data to coveralls, you can set the `COVERALLS_GIT_COM [codeship-image]: https://www.codeship.io/projects/de6fb440-dea9-0130-e7d9-122ca7ee39d3/status [codeship-url]: https://www.codeship.io/projects/5622 -[coveralls-image]: https://img.shields.io/coveralls/cainus/node-coveralls/master.svg -[coveralls-url]: https://coveralls.io/r/cainus/node-coveralls?branch=master +[coveralls-image]: https://coveralls.io/repos/nickmerwin/node-coveralls/badge.svg?branch=master&service=github +[coveralls-url]: https://coveralls.io/github/nickmerwin/node-coveralls?branch=master ## Contributing I generally don't accept pull requests that are untested, or break the build, because I'd like to keep the quality high (this is a coverage tool afterall!). I also don't care for "soft-versioning" or "optimistic versioning" (dependencies that have ^, x, > in them, or anything other than numbers and dots). There have been too many problems with bad semantic versioning in dependencies, and I'd rather have a solid library than a bleeding edge one. - - - diff --git a/package.json b/package.json index ce0ea06..085962c 100644 --- a/package.json +++ b/package.json @@ -5,7 +5,7 @@ "coverage", "coveralls" ], - "version": "2.11.2", + "version": "2.11.3", "bugs": { "url": "https://github.com/cainus/node-coveralls/issues" }, @@ -16,9 +16,11 @@ "coveralls": "./bin/coveralls.js" }, "maintainers": [ - "Gregg Caines (http://caines.ca)" + "Nick Merwin (https://coveralls.io)" ], "contributors": [ + "Gregg Caines (http://caines.ca)", + "Joshua Ma (http://joshma.com)", "Alan Gutierrez (http://www.prettyrobots.com/)", "Kir Belevich (https://github.com/svg)", "elliotcable (http://elliottcable.name/)", -- cgit v1.2.3 From 4344c189726451016e86627a0c11620ce420cdaf Mon Sep 17 00:00:00 2001 From: Ethan Langevin Date: Tue, 14 Jul 2015 17:29:33 -0400 Subject: Pass CI_PULL_REQUEST through to coveralls if it is set --- lib/convertLcovToCoveralls.js | 3 +++ lib/getOptions.js | 6 ++++++ test/convertLcovToCoveralls.js | 2 ++ test/getOptions.js | 11 +++++++++++ 4 files changed, 22 insertions(+) diff --git a/lib/convertLcovToCoveralls.js b/lib/convertLcovToCoveralls.js index 3f604e1..8b89f26 100644 --- a/lib/convertLcovToCoveralls.js +++ b/lib/convertLcovToCoveralls.js @@ -51,6 +51,9 @@ var convertLcovToCoveralls = function(input, options, cb){ if (options.repo_token) { postJson.repo_token = options.repo_token; } + if (options.service_pull_request) { + postJson.service_pull_request = options.service_pull_request; + } parsed.forEach(function(file){ postJson.source_files.push(convertLcovFileObject(file, filepath)); }); diff --git a/lib/getOptions.js b/lib/getOptions.js index eab67f4..42a3de1 100644 --- a/lib/getOptions.js +++ b/lib/getOptions.js @@ -9,6 +9,12 @@ var getBaseOptions = function(cb){ var git_commit = process.env.COVERALLS_GIT_COMMIT; var git_branch = process.env.COVERALLS_GIT_BRANCH; + var match = (process.env.CI_PULL_REQUEST || "").match(/(\d+)$/); + + if (match) { + options.service_pull_request = match[1]; + } + if (process.env.TRAVIS){ options.service_name = 'travis-ci'; options.service_job_id = process.env.TRAVIS_JOB_ID; diff --git a/test/convertLcovToCoveralls.js b/test/convertLcovToCoveralls.js index 6a64eda..24fa6c8 100644 --- a/test/convertLcovToCoveralls.js +++ b/test/convertLcovToCoveralls.js @@ -29,6 +29,7 @@ describe("convertLcovToCoveralls", function(){ process.env.COVERALLS_SERVICE_NAME = "SERVICE_NAME"; process.env.COVERALLS_SERVICE_JOB_ID = "SERVICE_JOB_ID"; process.env.COVERALLS_REPO_TOKEN = "REPO_TOKEN"; + process.env.CI_PULL_REQUEST = "https://github.com/fake/fake/pulls/123"; getOptions(function(err, options){ var lcovpath = __dirname + "/../fixtures/onefile.lcov"; @@ -37,6 +38,7 @@ describe("convertLcovToCoveralls", function(){ options.filepath = libpath; convertLcovToCoveralls(input, options, function(err, output){ should.not.exist(err); + output.service_pull_request.should.equal("123"); //output.git.should.equal("GIT_HASH"); done(); }); diff --git a/test/getOptions.js b/test/getOptions.js index 8a77708..356fb96 100644 --- a/test/getOptions.js +++ b/test/getOptions.js @@ -115,6 +115,9 @@ describe("getOptions", function(){ it ("should set service_name if it exists", function(done){ testServiceName(getOptions, done); }); + it("should set service_pull_request if it exists", function(done){ + testServicePullRequest(getOptions, done); + }); it ("should set service_name and service_job_id if it's running on travis-ci", function(done){ testTravisCi(getOptions, done); }); @@ -246,6 +249,14 @@ var testServiceName = function(sut, done){ }); }; +var testServicePullRequest = function(sut, done){ + process.env.CI_PULL_REQUEST = "https://github.com/fake/fake/pulls/123"; + sut(function(err, options){ + options.service_pull_request.should.equal("123"); + done(); + }); +}; + var testTravisCi = function(sut, done){ process.env.TRAVIS = "TRUE"; process.env.TRAVIS_JOB_ID = "1234"; -- cgit v1.2.3 From ec169bbaaca2e387b55d2b9f245732fabeb541be Mon Sep 17 00:00:00 2001 From: Nick Merwin Date: Sat, 18 Jul 2015 10:19:36 -0700 Subject: updated package.json repo --- package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 085962c..defb89b 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,7 @@ ], "version": "2.11.3", "bugs": { - "url": "https://github.com/cainus/node-coveralls/issues" + "url": "https://github.com/nickmerwin/node-coveralls/issues" }, "scripts": { "test": "make test" @@ -51,7 +51,7 @@ }, "repository": { "type": "git", - "url": "git://github.com/cainus/node-coveralls.git" + "url": "git://github.com/nickmerwin/node-coveralls.git" }, "author": "Gregg Caines", "license": "BSD" -- cgit v1.2.3 From acb47bd706d0d503330876210b5a802ffacee231 Mon Sep 17 00:00:00 2001 From: Andrii Shumada Date: Thu, 6 Aug 2015 01:40:36 +0300 Subject: put test deps in dev-dependencies --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 0ba9343..2640ab6 100644 --- a/README.md +++ b/README.md @@ -9,12 +9,12 @@ Supported CI services: [travis-ci](https://travis-ci.org/), [codeship](https:// ##Installation: Add the latest version of `coveralls` to your package.json: ``` -npm install coveralls --save +npm install coveralls --save-dev ``` If you're using mocha, add `mocha-lcov-reporter` to your package.json: ``` -npm install mocha-lcov-reporter --save +npm install mocha-lcov-reporter --save-dev ``` ##Usage: -- cgit v1.2.3 From ef96cf7b8147318dc164181adc2a7a626c0a14f4 Mon Sep 17 00:00:00 2001 From: Nick Merwin Date: Fri, 7 Aug 2015 11:21:40 -0700 Subject: removed dash from "circleci" in readme * closes #104 --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 2640ab6..ab20cc3 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,7 @@ [Coveralls.io](https://coveralls.io/) support for node.js. Get the great coverage reporting of coveralls.io and add a cool coverage button ( like the one above ) to your README. -Supported CI services: [travis-ci](https://travis-ci.org/), [codeship](https://www.codeship.io/), [circle-ci](https://circleci.com/), [jenkins](http://jenkins-ci.org/) +Supported CI services: [travis-ci](https://travis-ci.org/), [codeship](https://www.codeship.io/), [circleci](https://circleci.com/), [jenkins](http://jenkins-ci.org/) ##Installation: Add the latest version of `coveralls` to your package.json: -- cgit v1.2.3 From c66864d65f355e3d4b3f4e69e9fd63998f501331 Mon Sep 17 00:00:00 2001 From: Adam Meadows Date: Wed, 12 Aug 2015 14:58:19 -0700 Subject: Added support for process.env.COVERALLS_ENDPOINT To allow using this tool with Coveralls Enterprise, I've added support in `sendToCoveralls` to read the host from a `COVERALLS_ENDPOINT` environment variable (if it exists), else default to coveralls.io (as before). --- lib/sendToCoveralls.js | 7 ++++++- test/sendToCoveralls.js | 31 +++++++++++++++++++++++++++++-- 2 files changed, 35 insertions(+), 3 deletions(-) diff --git a/lib/sendToCoveralls.js b/lib/sendToCoveralls.js index 10e614d..38b37f7 100644 --- a/lib/sendToCoveralls.js +++ b/lib/sendToCoveralls.js @@ -1,8 +1,13 @@ var request = require('request'); var sendToCoveralls = function(obj, cb){ + var urlBase = 'https://coveralls.io'; + if (process.env.COVERALLS_ENDPOINT) { + urlBase = process.env.COVERALLS_ENDPOINT; + } + var str = JSON.stringify(obj); - var url = 'https://coveralls.io/api/v1/jobs'; + var url = urlBase + '/api/v1/jobs'; request.post({url : url, form : { json : str}}, function(err, response, body){ cb(err, response, body); }); diff --git a/test/sendToCoveralls.js b/test/sendToCoveralls.js index 937df95..f809319 100644 --- a/test/sendToCoveralls.js +++ b/test/sendToCoveralls.js @@ -5,9 +5,20 @@ var index = require('../index'); logger = require('log-driver')({level : false}); describe("sendToCoveralls", function(){ + var realCoverallsHost; + beforeEach(function() { + realCoverallsHost = process.env.COVERALLS_ENDPOINT; + }); + afterEach(function() { sinon.restoreAll(); + if (realCoverallsHost !== undefined) { + process.env.COVERALLS_ENDPOINT = realCoverallsHost; + } else { + delete process.env.COVERALLS_ENDPOINT; + } }); + it ("passes on the correct params to request.post", function(done){ sinon.stub(request, 'post', function(obj, cb){ obj.url.should.equal('https://coveralls.io/api/v1/jobs'); @@ -16,12 +27,28 @@ describe("sendToCoveralls", function(){ }); var obj = {"some":"obj"}; - index.sendToCoveralls(obj, function(err, response, body){ + index.sendToCoveralls(obj, function(err, response, body){ + err.should.equal('err'); + response.should.equal('response'); + body.should.equal('body'); + done(); + }); + }); + + it ("allows sending to enterprise url", function(done){ + process.env.COVERALLS_ENDPOINT = 'https://coveralls-ubuntu.domain.com'; + sinon.stub(request, 'post', function(obj, cb){ + obj.url.should.equal('https://coveralls-ubuntu.domain.com/api/v1/jobs'); + obj.form.should.eql({json : '{"some":"obj"}'}); + cb('err', 'response', 'body'); + }); + + var obj = {"some":"obj"}; + index.sendToCoveralls(obj, function(err, response, body){ err.should.equal('err'); response.should.equal('response'); body.should.equal('body'); done(); - }); }); }); -- cgit v1.2.3 From ee82dd92ac9b65f069d5ed722c0e241ddc30dcee Mon Sep 17 00:00:00 2001 From: Nick Merwin Date: Wed, 12 Aug 2015 20:41:05 -0700 Subject: version bump --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index defb89b..b70c6de 100644 --- a/package.json +++ b/package.json @@ -5,7 +5,7 @@ "coverage", "coveralls" ], - "version": "2.11.3", + "version": "2.11.4", "bugs": { "url": "https://github.com/nickmerwin/node-coveralls/issues" }, -- cgit v1.2.3 From b4d5479e72c0605c7ee252caa154d227e39adec5 Mon Sep 17 00:00:00 2001 From: Dale Harvey Date: Fri, 16 Oct 2015 13:45:12 +0200 Subject: Use HEAD to pick up git info --- lib/getOptions.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/getOptions.js b/lib/getOptions.js index 42a3de1..84a52a5 100644 --- a/lib/getOptions.js +++ b/lib/getOptions.js @@ -18,7 +18,7 @@ var getBaseOptions = function(cb){ if (process.env.TRAVIS){ options.service_name = 'travis-ci'; options.service_job_id = process.env.TRAVIS_JOB_ID; - git_commit = process.env.TRAVIS_COMMIT; + git_commit = 'HEAD'; git_branch = process.env.TRAVIS_BRANCH; } -- cgit v1.2.3 From 624352aae91033a17ca7c83e3595ec970bcef1c5 Mon Sep 17 00:00:00 2001 From: Andrii Shumada Date: Fri, 6 Nov 2015 14:56:03 +0200 Subject: rm unneeded options, bump node in travis --- .travis.yml | 6 ++++-- lib/detectLocalGit.js | 2 +- lib/getOptions.js | 2 +- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.travis.yml b/.travis.yml index b6f134c..284a527 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,6 +1,8 @@ language: node_js node_js: - - '0.10' - - '0.11' + - stable + - 4.2 + - 0.10 + - 0.11 script: make test-coveralls diff --git a/lib/detectLocalGit.js b/lib/detectLocalGit.js index 302cd44..773eb70 100644 --- a/lib/detectLocalGit.js +++ b/lib/detectLocalGit.js @@ -3,7 +3,7 @@ var path = require('path'); var REGEX_BRANCH = /^ref: refs\/heads\/(\w+)$/; -module.exports = function detectLocalGit(knownCommit, knownBranch) { +module.exports = function detectLocalGit() { var dir = process.cwd(), gitDir; while (path.resolve('/') !== dir) { gitDir = path.join(dir, '.git'); diff --git a/lib/getOptions.js b/lib/getOptions.js index 42a3de1..3241abd 100644 --- a/lib/getOptions.js +++ b/lib/getOptions.js @@ -68,7 +68,7 @@ var getBaseOptions = function(cb){ } if (!git_commit || !git_branch) { - var data = require('./detectLocalGit')(git_commit, git_branch); + var data = require('./detectLocalGit')(); if (data) { git_commit = git_commit || data.git_commit; git_branch = git_branch || data.git_branch; -- cgit v1.2.3 From 3eb69a89ad1ebb8634070a1fdebd0439a93d5b34 Mon Sep 17 00:00:00 2001 From: Russell Dempsey Date: Fri, 4 Dec 2015 01:02:52 -0800 Subject: Resolve Lodash deprecation warning coveralls@^2.6.1 resolves to coveralls@2.11.4, depends on request@2.40.0 - https://github.com/nickmerwin/node-coveralls/blob/master/package.json#L35 request@2.40.0 depends on form-data@~0.1.0 - https://github.com/request/request/blob/v2.40.0/package.json#L33 (so does 3.0, watch out) form-data@~0.1.0 resolves to @0.1.4, depends on async0.9.2 - https://github.com/form-data/form-data/blob/0.1.4/package.json#L20 async0.9.2 depends on deprecated lodash@2.4.1 - https://github.com/caolan/async/blob/0.9.2/package.json#L28 coveralls@master also depends on request@2.40.0 and should be updated to - https://github.com/request/request/blob/v2.67.0/package.json#L29 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index b70c6de..b06a3f7 100644 --- a/package.json +++ b/package.json @@ -32,7 +32,7 @@ "js-yaml": "3.0.1", "lcov-parse": "0.0.6", "log-driver": "1.2.4", - "request": "2.40.0" + "request": "2.67.0" }, "devDependencies": { "sinon-restore": "1.0.0", -- cgit v1.2.3