1module.exports = prefix 2 3var npm = require('./npm.js') 4var output = require('./utils/output.js') 5 6prefix.usage = 'npm prefix [-g]' 7 8function prefix (args, silent, cb) { 9 if (typeof cb !== 'function') { 10 cb = silent 11 silent = false 12 } 13 if (!silent) output(npm.prefix) 14 process.nextTick(cb.bind(this, null, npm.prefix)) 15} 16