{"action":"closed","issue":{"url":"https://api.github.com/repos/yeoman/environment/issues/74","repository_url":"https://api.github.com/repos/yeoman/environment","labels_url":"https://api.github.com/repos/yeoman/environment/issues/74/labels{/name}","comments_url":"https://api.github.com/repos/yeoman/environment/issues/74/comments","events_url":"https://api.github.com/repos/yeoman/environment/issues/74/events","html_url":"https://github.com/yeoman/environment/issues/74","id":197278841,"number":74,"title":"Cannot find module when using Environment.getByPath","user":{"login":"duro","id":17632,"avatar_url":"https://avatars.githubusercontent.com/u/17632?v=3","gravatar_id":"","url":"https://api.github.com/users/duro","html_url":"https://github.com/duro","followers_url":"https://api.github.com/users/duro/followers","following_url":"https://api.github.com/users/duro/following{/other_user}","gists_url":"https://api.github.com/users/duro/gists{/gist_id}","starred_url":"https://api.github.com/users/duro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/duro/subscriptions","organizations_url":"https://api.github.com/users/duro/orgs","repos_url":"https://api.github.com/users/duro/repos","events_url":"https://api.github.com/users/duro/events{/privacy}","received_events_url":"https://api.github.com/users/duro/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":6,"created_at":"2016-12-22T22:22:02Z","updated_at":"2016-12-22T23:02:27Z","closed_at":"2016-12-22T23:02:26Z","body":"I am trying to embed my generator in my project using the `getByPath` method that was introduced here in PR #11 \r\n\r\nMy folder structure looks like this:\r\n\r\n```\r\n- /generators\r\n--- /adrizer     <---- My embeded generator\r\n------- /generators\r\n---------- /app\r\n------------- index.js\r\n---------- /test\r\n------------- index.js\r\n------- package.json\r\n```\r\n\r\nI am trying to test running this generator using this command:\r\n\r\n`./node_modules/.bin/yo ./generators/adrizer adrizer`\r\n\r\nAnd I get this error:\r\n\r\n```\r\nmodule.js:471\r\n    throw err;\r\n    ^\r\n\r\nError: Cannot find module '/Users/adamduro/Workspace/projects/adrizer-dashboard/generators/adrizer/'\r\n    at Function.Module._resolveFilename (module.js:469:15)\r\n    at Function.resolve (internal/module.js:27:19)\r\n    at Environment.resolveModulePath (/Users/adamduro/Workspace/projects/adrizer-dashboard/node_modules/yeoman-environment/lib/environment.js:461:18)\r\n    at Environment.register (/Users/adamduro/Workspace/projects/adrizer-dashboard/node_modules/yeoman-environment/lib/environment.js:161:25)\r\n    at Environment.getByPath (/Users/adamduro/Workspace/projects/adrizer-dashboard/node_modules/yeoman-environment/lib/environment.js:276:10)\r\n    at Environment.get (/Users/adamduro/Workspace/projects/adrizer-dashboard/node_modules/yeoman-environment/lib/environment.js:265:10)\r\n    at Environment.create (/Users/adamduro/Workspace/projects/adrizer-dashboard/node_modules/yeoman-environment/lib/environment.js:296:24)\r\n    at Environment.run (/Users/adamduro/Workspace/projects/adrizer-dashboard/node_modules/yeoman-environment/lib/environment.js:372:24)\r\n    at /Users/adamduro/Workspace/projects/adrizer-dashboard/node_modules/yo/lib/cli.js:140:11\r\n    at Array.forEach (native)\r\n```\r\n\r\nAny idea what I am doing wrong? Or was there a change to the way that `require.resolve` work in Node 6?"}}
{"actor":{"display_login":"SBoudrias"}}