diff options
| author | Nick Merwin <[email protected]> | 2019-11-20 17:05:48 -0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2019-11-20 17:05:48 -0800 |
| commit | 336123fe05e7f80d79fc8522b4ff21a60fffe77c (patch) | |
| tree | 97e5b9343471fc73ddf4ffb20cd71ca58367d6c6 /bin | |
| parent | eba01a29c69f28ffd7f50556492a43b5ba2486d7 (diff) | |
| download | node-coveralls-336123fe05e7f80d79fc8522b4ff21a60fffe77c.tar.xz node-coveralls-336123fe05e7f80d79fc8522b4ff21a60fffe77c.zip | |
ES6
* remove unused variables
* move `require`s at the top
* check for prototype built-ins
* run in strict mode
* always check for error values in tests
* make style consistent
* mark Node.js 6 as the minimum supported version in package.json
* Use the arrow return syntax
* logger.js: use `Boolean` to make the intention clearer.
* Use the rest params instead of arguments.
* test/getOptions.js: beautify git data.
* Update logger.js
Remove `hasDebugEnvVariable` function; it's just a `process.env` check
* Create .jshintrc
Diffstat (limited to 'bin')
| -rwxr-xr-x | bin/coveralls.js | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/bin/coveralls.js b/bin/coveralls.js index 324ec6d..7d92ad2 100755 --- a/bin/coveralls.js +++ b/bin/coveralls.js @@ -1,22 +1,22 @@ #!/usr/bin/env node -var handleInput = require('../lib/handleInput'); -var logger = require('../lib/logger'); +'use strict'; + +const { handleInput } = require('..'); process.stdin.resume(); process.stdin.setEncoding('utf8'); -var input = ''; +let input = ''; -process.stdin.on('data', function(chunk) { - input += chunk; +process.stdin.on('data', chunk => { + input += chunk; }); -process.stdin.on('end', function() { - handleInput(input, function(err) { - if (err) { - throw err; - } - }); +process.stdin.on('end', () => { + handleInput(input, err => { + if (err) { + throw err; + } + }); }); - |
