lib/traverse.js
function find(kernelName) {
  return jp.dataDirs({ withSysPrefix: true }).then(dirs => {

    const kernelInfos = dirs.map(dir => ({
      name: kernelName,
      resourceDir: path.join(dir, 'kernels', kernelName),
    }))

    return extractKernelResources(kernelInfos);
  }).then(kernelResource => kernelResource[kernelName])
}
function find(kernelName) {
  return jp.dataDirs({ withSysPrefix: true }).then(dirs => {

    const kernelInfos = dirs.map(dir => ({
      name: kernelName,
      resourceDir: path.join(dir, 'kernels', kernelName),
    }))

    return extractKernelResources(kernelInfos);
  }).then(kernelResource => kernelResource[kernelName])
}
function find ( kernelName ) { return jp . dataDirs ( { withSysPrefix : true } ) . then ( dirs => { const kernelInfos = dirs . map ( dir => ( { name : kernelName , resourceDir : path . join ( dir , 'kernels' , kernelName ) , } ) ) return extractKernelResources ( kernelInfos ) ; } ) . then ( kernelResource => kernelResource [ kernelName ] ) }
find a kernel by name
@param  {string} kernelName the kernel to locate
@return {Object} kernelResource object
find a kernel by name