{"action":"created","comment":{"url":"https://api.github.com/repos/ember-cli/ember-cli/pulls/comments/214159363","pull_request_review_id":151155145,"id":214159363,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxNDE1OTM2Mw==","diff_hunk":"@@ -385,14 +385,26 @@ let Blueprint = CoreObject.extend({\n   /**\n     @private\n     @method _checkInRepoAddonExists\n-    @param {String} inRepoAddon\n+    @param {Object} options\n   */\n-  _checkInRepoAddonExists(inRepoAddon) {\n-    if (inRepoAddon) {\n-      let addon = findAddonByName(this.project, inRepoAddon);\n+  _checkInRepoAddonExists(options) {\n+    let addon;\n+\n+    if (options.inRepoAddon) {\n+      addon = findAddonByName(this.project, options.inRepoAddon);\n+\n+      if (!addon) {\n+        throw new SilentError(`You specified the 'in-repo-addon' flag, but the ` +\n+          `in-repo-addon '${options.inRepoAddon}' does not exist. Please check the name and try again.`);\n+      }\n+    }\n+\n+    if (options.in) {\n+      addon = findAddonByPath(this.project, options.in);\n+\n       if (!addon) {\n-        throw new SilentError(`You specified the in-repo-addon flag, but the ` +\n-          `in-repo-addon '${inRepoAddon}' does not exist. Please check the name and try again.`);\n+        throw new SilentError(`You specified the 'in' flag, but the ` +\n+          `in-repo-addon '${options.inRepoAddon}' does not exist. Please check the name and try again.`);","path":"lib/models/blueprint.js","position":29,"original_position":29,"commit_id":"cb898827768e1fcf674605ab7650c4d317b63dcb","original_commit_id":"cb898827768e1fcf674605ab7650c4d317b63dcb","user":{"login":"scalvert","id":180990,"node_id":"MDQ6VXNlcjE4MDk5MA==","avatar_url":"https://avatars2.githubusercontent.com/u/180990?v=4","gravatar_id":"","url":"https://api.github.com/users/scalvert","html_url":"https://github.com/scalvert","followers_url":"https://api.github.com/users/scalvert/followers","following_url":"https://api.github.com/users/scalvert/following{/other_user}","gists_url":"https://api.github.com/users/scalvert/gists{/gist_id}","starred_url":"https://api.github.com/users/scalvert/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scalvert/subscriptions","organizations_url":"https://api.github.com/users/scalvert/orgs","repos_url":"https://api.github.com/users/scalvert/repos","events_url":"https://api.github.com/users/scalvert/events{/privacy}","received_events_url":"https://api.github.com/users/scalvert/received_events","type":"User","site_admin":false},"body":"That was a mistake. Good catch. ","created_at":"2018-08-30T19:50:46Z","updated_at":"2018-08-30T19:50:46Z","html_url":"https://github.com/ember-cli/ember-cli/pull/8000#discussion_r214159363","pull_request_url":"https://api.github.com/repos/ember-cli/ember-cli/pulls/8000","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/ember-cli/ember-cli/pulls/comments/214159363"},"html":{"href":"https://github.com/ember-cli/ember-cli/pull/8000#discussion_r214159363"},"pull_request":{"href":"https://api.github.com/repos/ember-cli/ember-cli/pulls/8000"}},"in_reply_to_id":214156747},"pull_request":{"url":"https://api.github.com/repos/ember-cli/ember-cli/pulls/8000","id":211570912,"node_id":"MDExOlB1bGxSZXF1ZXN0MjExNTcwOTEy","html_url":"https://github.com/ember-cli/ember-cli/pull/8000","diff_url":"https://github.com/ember-cli/ember-cli/pull/8000.diff","patch_url":"https://github.com/ember-cli/ember-cli/pull/8000.patch","issue_url":"https://api.github.com/repos/ember-cli/ember-cli/issues/8000","number":8000,"state":"open","locked":false,"title":"WIP - Adding `--in` option for customizing path for in repo addon blueprints","user":{"login":"scalvert","id":180990,"node_id":"MDQ6VXNlcjE4MDk5MA==","avatar_url":"https://avatars2.githubusercontent.com/u/180990?v=4","gravatar_id":"","url":"https://api.github.com/users/scalvert","html_url":"https://github.com/scalvert","followers_url":"https://api.github.com/users/scalvert/followers","following_url":"https://api.github.com/users/scalvert/following{/other_user}","gists_url":"https://api.github.com/users/scalvert/gists{/gist_id}","starred_url":"https://api.github.com/users/scalvert/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scalvert/subscriptions","organizations_url":"https://api.github.com/users/scalvert/orgs","repos_url":"https://api.github.com/users/scalvert/repos","events_url":"https://api.github.com/users/scalvert/events{/privacy}","received_events_url":"https://api.github.com/users/scalvert/received_events","type":"User","site_admin":false},"body":"Ember generate allows you to generate entities inside in-repo addons using the `--in-repo-addon` option (not to be confused with the `ember generate` `in-repo-addon` subcommand, which creates an in-repo addon). This option only partially accounts for custom directories (following [this PR](https://github.com/ember-cli/ember-cli/pull/7947)), which is a requirement in some larger applications. \r\n\r\nThis PR proposes removing `--in-repo-addon` in favor of a new option: `--in`. The `--in` option differs from the existing `--in-repo-addon` option as it takes a path pointing to the root of the **addon** you would like your blueprint run against.\r\n\r\nValid use cases for the `--in` option would be:\r\n\r\n\r\n### Case 1\r\n\r\nProjects contained in a subdirectory of the root of the repository (monorepos):\r\n\r\n```\r\nember generate component foo-bar --in ./subproject/baz\r\n```\r\n\r\n**Result**: \r\nWill create component files in:\r\n\r\n```\r\n// component blueprint \r\nsubproject/baz/app/components/foo-bar.js\r\nsubproject/baz/app/templates/components/foo-bar.hbs\r\n    \r\n// component-test blueprint\r\nsubproject/tests/integration/components/foo-bar-test.js\r\n```\r\n\r\n### Case 2\r\n\r\nStandard in repo addons (contained in lib):\r\n\r\n```\r\nember generate component foo-bar --in ./lib/baz\r\n```\r\n\r\n**Result**: \r\nWill create component files in:\r\n\r\n```\r\n// component blueprint\r\nlib/baz/addon/components/foo-bar.js\r\nlib/baz/addon/templates/components/foo-bar.hbs\r\n    \r\n// component-test blueprint\r\ntests/integration/components/foo-bar-test.js\r\n```\r\n\r\n### Case 3\r\n\r\nIn repo addon in custom root level path:\r\n\r\n```\r\nember generate component foo-bar --in ./custom/baz\r\n```\r\n\r\n**Result**: \r\nWill create component files in:\r\n\r\n```\r\n// component blueprint\r\ncustom/baz/addon/components/foo-bar.js\r\ncustom/baz/addon/templates/components/foo-bar.hbs\r\n    \r\n// component-test blueprint\r\ntests/integration/components/foo-bar-test.js\r\n```\r\n\r\n### Case 4\r\n\r\nIn repo addon in custom nested path:\r\n\r\n```\r\nember generate component foo-bar --in ./custom/sub/baz\r\n```\r\n\r\n**Result**: \r\nWill create component files in:\r\n\r\n```\r\n// component blueprint\r\ncustom/sub/baz/addon/components/foo-bar.js\r\ncustom/sub/baz/addon/templates/components/foo-bar.hbs\r\n    \r\n// component-test blueprint\r\ntests/integration/components/foo-bar-test.js\r\n```\r\n\r\n### Deprecation\r\n\r\nDeprecating the old `--in-repo-addon` option should be done via the following:\r\n\r\n- add a deprecation warning when using the `--in-repo-addon` option\r\n- deprecate at next LTS version of ember-cli\r\n","created_at":"2018-08-28T21:59:59Z","updated_at":"2018-08-30T19:50:46Z","closed_at":null,"merged_at":null,"merge_commit_sha":"add1f23e9a0f2ca1c98f4555d21223abad48a8dc","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/ember-cli/ember-cli/pulls/8000/commits","review_comments_url":"https://api.github.com/repos/ember-cli/ember-cli/pulls/8000/comments","review_comment_url":"https://api.github.com/repos/ember-cli/ember-cli/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ember-cli/ember-cli/issues/8000/comments","statuses_url":"https://api.github.com/repos/ember-cli/ember-cli/statuses/cb898827768e1fcf674605ab7650c4d317b63dcb","head":{"label":"scalvert:add-in-option","ref":"add-in-option","sha":"cb898827768e1fcf674605ab7650c4d317b63dcb","user":{"login":"scalvert","id":180990,"node_id":"MDQ6VXNlcjE4MDk5MA==","avatar_url":"https://avatars2.githubusercontent.com/u/180990?v=4","gravatar_id":"","url":"https://api.github.com/users/scalvert","html_url":"https://github.com/scalvert","followers_url":"https://api.github.com/users/scalvert/followers","following_url":"https://api.github.com/users/scalvert/following{/other_user}","gists_url":"https://api.github.com/users/scalvert/gists{/gist_id}","starred_url":"https://api.github.com/users/scalvert/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scalvert/subscriptions","organizations_url":"https://api.github.com/users/scalvert/orgs","repos_url":"https://api.github.com/users/scalvert/repos","events_url":"https://api.github.com/users/scalvert/events{/privacy}","received_events_url":"https://api.github.com/users/scalvert/received_events","type":"User","site_admin":false},"repo":{"id":105549101,"node_id":"MDEwOlJlcG9zaXRvcnkxMDU1NDkxMDE=","name":"ember-cli","full_name":"scalvert/ember-cli","owner":{"login":"scalvert","id":180990,"node_id":"MDQ6VXNlcjE4MDk5MA==","avatar_url":"https://avatars2.githubusercontent.com/u/180990?v=4","gravatar_id":"","url":"https://api.github.com/users/scalvert","html_url":"https://github.com/scalvert","followers_url":"https://api.github.com/users/scalvert/followers","following_url":"https://api.github.com/users/scalvert/following{/other_user}","gists_url":"https://api.github.com/users/scalvert/gists{/gist_id}","starred_url":"https://api.github.com/users/scalvert/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scalvert/subscriptions","organizations_url":"https://api.github.com/users/scalvert/orgs","repos_url":"https://api.github.com/users/scalvert/repos","events_url":"https://api.github.com/users/scalvert/events{/privacy}","received_events_url":"https://api.github.com/users/scalvert/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/scalvert/ember-cli","description":"The Ember.js command line utility","fork":true,"url":"https://api.github.com/repos/scalvert/ember-cli","forks_url":"https://api.github.com/repos/scalvert/ember-cli/forks","keys_url":"https://api.github.com/repos/scalvert/ember-cli/keys{/key_id}","collaborators_url":"https://api.github.com/repos/scalvert/ember-cli/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/scalvert/ember-cli/teams","hooks_url":"https://api.github.com/repos/scalvert/ember-cli/hooks","issue_events_url":"https://api.github.com/repos/scalvert/ember-cli/issues/events{/number}","events_url":"https://api.github.com/repos/scalvert/ember-cli/events","assignees_url":"https://api.github.com/repos/scalvert/ember-cli/assignees{/user}","branches_url":"https://api.github.com/repos/scalvert/ember-cli/branches{/branch}","tags_url":"https://api.github.com/repos/scalvert/ember-cli/tags","blobs_url":"https://api.github.com/repos/scalvert/ember-cli/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/scalvert/ember-cli/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/scalvert/ember-cli/git/refs{/sha}","trees_url":"https://api.github.com/repos/scalvert/ember-cli/git/trees{/sha}","statuses_url":"https://api.github.com/repos/scalvert/ember-cli/statuses/{sha}","languages_url":"https://api.github.com/repos/scalvert/ember-cli/languages","stargazers_url":"https://api.github.com/repos/scalvert/ember-cli/stargazers","contributors_url":"https://api.github.com/repos/scalvert/ember-cli/contributors","subscribers_url":"https://api.github.com/repos/scalvert/ember-cli/subscribers","subscription_url":"https://api.github.com/repos/scalvert/ember-cli/subscription","commits_url":"https://api.github.com/repos/scalvert/ember-cli/commits{/sha}","git_commits_url":"https://api.github.com/repos/scalvert/ember-cli/git/commits{/sha}","comments_url":"https://api.github.com/repos/scalvert/ember-cli/comments{/number}","issue_comment_url":"https://api.github.com/repos/scalvert/ember-cli/issues/comments{/number}","contents_url":"https://api.github.com/repos/scalvert/ember-cli/contents/{+path}","compare_url":"https://api.github.com/repos/scalvert/ember-cli/compare/{base}...{head}","merges_url":"https://api.github.com/repos/scalvert/ember-cli/merges","archive_url":"https://api.github.com/repos/scalvert/ember-cli/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/scalvert/ember-cli/downloads","issues_url":"https://api.github.com/repos/scalvert/ember-cli/issues{/number}","pulls_url":"https://api.github.com/repos/scalvert/ember-cli/pulls{/number}","milestones_url":"https://api.github.com/repos/scalvert/ember-cli/milestones{/number}","notifications_url":"https://api.github.com/repos/scalvert/ember-cli/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/scalvert/ember-cli/labels{/name}","releases_url":"https://api.github.com/repos/scalvert/ember-cli/releases{/id}","deployments_url":"https://api.github.com/repos/scalvert/ember-cli/deployments","created_at":"2017-10-02T15:10:30Z","updated_at":"2018-08-28T17:39:17Z","pushed_at":"2018-08-30T19:03:56Z","git_url":"git://github.com/scalvert/ember-cli.git","ssh_url":"git@github.com:scalvert/ember-cli.git","clone_url":"https://github.com/scalvert/ember-cli.git","svn_url":"https://github.com/scalvert/ember-cli","homepage":"http://ember-cli.com/","size":13493,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"ember-cli:beta","ref":"beta","sha":"c00e1067ff089785cb182036ce80d346eeb82606","user":{"login":"ember-cli","id":10262982,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMjYyOTgy","avatar_url":"https://avatars3.githubusercontent.com/u/10262982?v=4","gravatar_id":"","url":"https://api.github.com/users/ember-cli","html_url":"https://github.com/ember-cli","followers_url":"https://api.github.com/users/ember-cli/followers","following_url":"https://api.github.com/users/ember-cli/following{/other_user}","gists_url":"https://api.github.com/users/ember-cli/gists{/gist_id}","starred_url":"https://api.github.com/users/ember-cli/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ember-cli/subscriptions","organizations_url":"https://api.github.com/users/ember-cli/orgs","repos_url":"https://api.github.com/users/ember-cli/repos","events_url":"https://api.github.com/users/ember-cli/events{/privacy}","received_events_url":"https://api.github.com/users/ember-cli/received_events","type":"Organization","site_admin":false},"repo":{"id":14089735,"node_id":"MDEwOlJlcG9zaXRvcnkxNDA4OTczNQ==","name":"ember-cli","full_name":"ember-cli/ember-cli","owner":{"login":"ember-cli","id":10262982,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEwMjYyOTgy","avatar_url":"https://avatars3.githubusercontent.com/u/10262982?v=4","gravatar_id":"","url":"https://api.github.com/users/ember-cli","html_url":"https://github.com/ember-cli","followers_url":"https://api.github.com/users/ember-cli/followers","following_url":"https://api.github.com/users/ember-cli/following{/other_user}","gists_url":"https://api.github.com/users/ember-cli/gists{/gist_id}","starred_url":"https://api.github.com/users/ember-cli/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ember-cli/subscriptions","organizations_url":"https://api.github.com/users/ember-cli/orgs","repos_url":"https://api.github.com/users/ember-cli/repos","events_url":"https://api.github.com/users/ember-cli/events{/privacy}","received_events_url":"https://api.github.com/users/ember-cli/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ember-cli/ember-cli","description":"The Ember.js command line utility","fork":false,"url":"https://api.github.com/repos/ember-cli/ember-cli","forks_url":"https://api.github.com/repos/ember-cli/ember-cli/forks","keys_url":"https://api.github.com/repos/ember-cli/ember-cli/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ember-cli/ember-cli/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ember-cli/ember-cli/teams","hooks_url":"https://api.github.com/repos/ember-cli/ember-cli/hooks","issue_events_url":"https://api.github.com/repos/ember-cli/ember-cli/issues/events{/number}","events_url":"https://api.github.com/repos/ember-cli/ember-cli/events","assignees_url":"https://api.github.com/repos/ember-cli/ember-cli/assignees{/user}","branches_url":"https://api.github.com/repos/ember-cli/ember-cli/branches{/branch}","tags_url":"https://api.github.com/repos/ember-cli/ember-cli/tags","blobs_url":"https://api.github.com/repos/ember-cli/ember-cli/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ember-cli/ember-cli/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ember-cli/ember-cli/git/refs{/sha}","trees_url":"https://api.github.com/repos/ember-cli/ember-cli/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ember-cli/ember-cli/statuses/{sha}","languages_url":"https://api.github.com/repos/ember-cli/ember-cli/languages","stargazers_url":"https://api.github.com/repos/ember-cli/ember-cli/stargazers","contributors_url":"https://api.github.com/repos/ember-cli/ember-cli/contributors","subscribers_url":"https://api.github.com/repos/ember-cli/ember-cli/subscribers","subscription_url":"https://api.github.com/repos/ember-cli/ember-cli/subscription","commits_url":"https://api.github.com/repos/ember-cli/ember-cli/commits{/sha}","git_commits_url":"https://api.github.com/repos/ember-cli/ember-cli/git/commits{/sha}","comments_url":"https://api.github.com/repos/ember-cli/ember-cli/comments{/number}","issue_comment_url":"https://api.github.com/repos/ember-cli/ember-cli/issues/comments{/number}","contents_url":"https://api.github.com/repos/ember-cli/ember-cli/contents/{+path}","compare_url":"https://api.github.com/repos/ember-cli/ember-cli/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ember-cli/ember-cli/merges","archive_url":"https://api.github.com/repos/ember-cli/ember-cli/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ember-cli/ember-cli/downloads","issues_url":"https://api.github.com/repos/ember-cli/ember-cli/issues{/number}","pulls_url":"https://api.github.com/repos/ember-cli/ember-cli/pulls{/number}","milestones_url":"https://api.github.com/repos/ember-cli/ember-cli/milestones{/number}","notifications_url":"https://api.github.com/repos/ember-cli/ember-cli/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ember-cli/ember-cli/labels{/name}","releases_url":"https://api.github.com/repos/ember-cli/ember-cli/releases{/id}","deployments_url":"https://api.github.com/repos/ember-cli/ember-cli/deployments","created_at":"2013-11-03T17:34:43Z","updated_at":"2018-08-28T21:20:54Z","pushed_at":"2018-08-30T19:03:58Z","git_url":"git://github.com/ember-cli/ember-cli.git","ssh_url":"git@github.com:ember-cli/ember-cli.git","clone_url":"https://github.com/ember-cli/ember-cli.git","svn_url":"https://github.com/ember-cli/ember-cli","homepage":"http://ember-cli.com/","size":13494,"stargazers_count":3249,"watchers_count":3249,"language":"JavaScript","has_issues":true,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1061,"mirror_url":null,"archived":false,"open_issues_count":256,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":1061,"open_issues":256,"watchers":3249,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ember-cli/ember-cli/pulls/8000"},"html":{"href":"https://github.com/ember-cli/ember-cli/pull/8000"},"issue":{"href":"https://api.github.com/repos/ember-cli/ember-cli/issues/8000"},"comments":{"href":"https://api.github.com/repos/ember-cli/ember-cli/issues/8000/comments"},"review_comments":{"href":"https://api.github.com/repos/ember-cli/ember-cli/pulls/8000/comments"},"review_comment":{"href":"https://api.github.com/repos/ember-cli/ember-cli/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ember-cli/ember-cli/pulls/8000/commits"},"statuses":{"href":"https://api.github.com/repos/ember-cli/ember-cli/statuses/cb898827768e1fcf674605ab7650c4d317b63dcb"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"scalvert"}}