diff --git a/index.js b/index.js index 8189df5..83b81b2 100755 --- a/index.js +++ b/index.js @@ -1,8 +1,9 @@ #! /usr/bin/env node var fs = require('fs'); +var path = require('path'); var args = process.argv.slice(2); -var tips = fs.readFileSync('./pragmaticprogrammer.txt'); +var tips = fs.readFileSync(path.join(__dirname, 'pragmaticprogrammer.txt')); var tipList = tips.toString().split('\n'); try {