bfncs/codemod-imports-sort

Error: Cannot find module '../utils/requirePackage'

NameFILIP opened this issue · 0 comments

➜  project git:(sort-imports) codemod-imports-sort --version
module.js:471
    throw err;
    ^

Error: Cannot find module '../utils/requirePackage'
    at Function.Module._resolveFilename (module.js:469:15)
    at Function.Module._load (module.js:417:25)
    at Module.require (module.js:497:17)
    at require (internal/module.js:20:19)
    at Object.callback (/Users/fspiridonov/.nvm/versions/node/v6.10.0/lib/node_modules/codemod-imports-sort/bin/codemod-imports-sort:82:32)
    at Object.ArgParser.setOption (/Users/fspiridonov/.nvm/versions/node/v6.10.0/lib/node_modules/codemod-imports-sort/node_modules/nomnom/nomnom.js:447:26)
    at /Users/fspiridonov/.nvm/versions/node/v6.10.0/lib/node_modules/codemod-imports-sort/node_modules/nomnom/nomnom.js:274:14
    at Array.reduce (native)
    at Object.parse (/Users/fspiridonov/.nvm/versions/node/v6.10.0/lib/node_modules/codemod-imports-sort/node_modules/nomnom/nomnom.js:223:10)
    at Object.<anonymous> (/Users/fspiridonov/.nvm/versions/node/v6.10.0/lib/node_modules/codemod-imports-sort/bin/codemod-imports-sort:93:4)

In here: https://github.com/bfncs/codemod-imports-sort/blob/master/bin/codemod-imports-sort#L82

Should it be

const requirePackage = require('jscodeshift/utils/requirePackage');

?