diff options
author | tv <tv@xso> | 2011-08-28 17:23:45 +0200 |
---|---|---|
committer | tv <tv@xso> | 2011-08-28 17:24:30 +0200 |
commit | db1bd874aa518536f81d170facefd75e661afe30 (patch) | |
tree | b9c40c01b68d9478e26755e069c49388732d48fc | |
parent | 458a7f74adcb4ee433f16a5695a0c414da3b43f8 (diff) |
knut: add Error #1 ∧ Pro-Tip
-rwxr-xr-x | cholerab/knut/index.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/cholerab/knut/index.js b/cholerab/knut/index.js index 9c536006..b8951f1d 100755 --- a/cholerab/knut/index.js +++ b/cholerab/knut/index.js @@ -12,6 +12,16 @@ var spawn = require('child_process').spawn; var plugs = process.argv.slice(2); +if (plugs.length === 0) { + console.error('Error 1: You are made of stupid!' + + '\nPro-Tip: [32m' + + require('path').basename(process.argv[1]) + ' [31;1mPLUG[m' + + ' # PLUG ∈ {' + + require('fs').readdirSync(__dirname + '/plugs').join(',') + + '}^n, n ≥ 1'); + process.exit(23); +}; + http.createServer(function (req, res) { return slurp(req, function (data) { try { |