Issues (11)

tasks/bin.js (2 issues)

1
var hasbin = require('hasbin');
2
var fs = require('fs');
3
var path = require('path');
4
5
module.exports = {
6
    path: function() {
7
        if (fs.existsSync('./vendor/bin/jigsaw')) {
8
            return path.normalize('./vendor/bin/jigsaw')
9
        }
10
11
        if (hasbin.sync('jigsaw')) {
12
            return 'jigsaw';
13
        }
14
15
        console.log('Could not find Jigsaw; please install it via Composer, either locally or globally.');
0 ignored issues
show
console.log looks like debug code. Are you sure you do not want to remove it?
Loading history...
16
17
        process.exit();
0 ignored issues
show
Compatibility Debugging Code Best Practice introduced by
Use of process.exit() is discouraged as it will potentially stop the complete node.js application. Consider quitting gracefully instead by throwing an Error.
Loading history...
18
    }
19
};
20