verb
Version:
A project without documentation is like a project that doesn't exist. Verb solves this by making it dead simple to generate docs, using simple markdown templates, with zero configuration required.
18 lines (15 loc) • 458 B
JavaScript
const path = require('path');
const find = require('find');
const verb = require('../../');
/**
* Resolve matches.
* @param {[type]} name [description]
* @param {[type]} filepath [description]
* @return {[type]} [description]
*/
module.exports = function(name, filepath) {
filepath = verb.cwd(filepath);
var dir = path.dirname(path.join(filepath, name));
name = path.basename(name);
return find.fileSync(name, dir);
};