diff options
Diffstat (limited to 'spec2js.js')
-rwxr-xr-x | spec2js.js | 17 |
1 files changed, 0 insertions, 17 deletions
diff --git a/spec2js.js b/spec2js.js deleted file mode 100755 index 6bf366f..0000000 --- a/spec2js.js +++ /dev/null @@ -1,17 +0,0 @@ -#!/usr/bin/env node - -var fs = require('fs'); -var util = require('util'); - -fs.readFile('spec.txt', 'utf8', function(err, data) { - if (err) { - return console.log(err); - } - var examples = []; - data.replace(/^\.\n([\s\S]*?)^\.\n([\s\S]*?)^\.$/gm, - function(_,x,y){ - examples.push({markdown: x, html: y}); - }); - console.log(util.inspect(examples, { depth: null })); - console.warn(examples.length + ' examples'); -}); |