Find nearest file in path var find = require('nearest-file');// Get content of nearest .gitconfig in given path from end to rootvar config = find(__dirname, '.gitconfig');