From 28d16eea642b03c8e10a40a9b23adc64039abf31 Mon Sep 17 00:00:00 2001 From: Richard Littauer Date: Mon, 8 May 2017 15:21:31 +0200 Subject: [PATCH] Add file --- cat.js | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 cat.js diff --git a/cat.js b/cat.js new file mode 100644 index 0000000..8235a44 --- /dev/null +++ b/cat.js @@ -0,0 +1,12 @@ +#! /usr/bin/env node + +const fs = require('fs') +const path = require('path') + +fs.readFile(path.join(process.cwd(), './spec.md'), {encoding: 'utf8'}, (err, file) => { + if (err) { + console.log('Unable to find file') + } + + console.log(file) +})