{"action":"created","comment":{"url":"https://api.github.com/repos/Microsoft/TACO/pulls/comments/46202794","id":46202794,"diff_hunk":"@@ -779,22 +779,20 @@ class Kit extends commands.TacoCommandBase {\n \n     /* tslint:disable:member-ordering */\n     // tslint doesn't handle this case and considers subcommands as member function\n-    public subcommands: commands.ICommand[] = [\n+    public subcommands: commands.ISubCommand<Kit>[] = [\n         {\n             // List kits\n             name: \"list\",\n-            run: Kit.list,\n-            canHandleArgs(commandData: commands.ICommandData): boolean {\n-                return !commandData.remain[0] || commandData.remain[0] && commandData.remain[0].toLowerCase() === \"list\";\n+            run: (command, commandData) => command.list(commandData),\n+            canHandleArgs: (command, commandData) => {","path":"src/taco-cli/cli/kit.ts","position":31,"original_position":31,"commit_id":"58dbd62ecaf8678b868573ff9e1a95395ac14188","original_commit_id":"58dbd62ecaf8678b868573ff9e1a95395ac14188","user":{"login":"nisheetjain","id":12930977,"avatar_url":"https://avatars.githubusercontent.com/u/12930977?v=3","gravatar_id":"","url":"https://api.github.com/users/nisheetjain","html_url":"https://github.com/nisheetjain","followers_url":"https://api.github.com/users/nisheetjain/followers","following_url":"https://api.github.com/users/nisheetjain/following{/other_user}","gists_url":"https://api.github.com/users/nisheetjain/gists{/gist_id}","starred_url":"https://api.github.com/users/nisheetjain/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nisheetjain/subscriptions","organizations_url":"https://api.github.com/users/nisheetjain/orgs","repos_url":"https://api.github.com/users/nisheetjain/repos","events_url":"https://api.github.com/users/nisheetjain/events{/privacy}","received_events_url":"https://api.github.com/users/nisheetjain/received_events","type":"User","site_admin":false},"body":"this would point to the subcommand and that is the reason we need to pass along command object","created_at":"2015-11-30T21:00:07Z","updated_at":"2015-11-30T21:00:07Z","html_url":"https://github.com/Microsoft/TACO/pull/187#discussion_r46202794","pull_request_url":"https://api.github.com/repos/Microsoft/TACO/pulls/187","_links":{"self":{"href":"https://api.github.com/repos/Microsoft/TACO/pulls/comments/46202794"},"html":{"href":"https://github.com/Microsoft/TACO/pull/187#discussion_r46202794"},"pull_request":{"href":"https://api.github.com/repos/Microsoft/TACO/pulls/187"}}},"pull_request":{"url":"https://api.github.com/repos/Microsoft/TACO/pulls/187","id":52165711,"html_url":"https://github.com/Microsoft/TACO/pull/187","diff_url":"https://github.com/Microsoft/TACO/pull/187.diff","patch_url":"https://github.com/Microsoft/TACO/pull/187.patch","issue_url":"https://api.github.com/repos/Microsoft/TACO/issues/187","number":187,"state":"open","locked":false,"title":"Improving ICommand and ISubCommand interfaces","user":{"login":"nisheetjain","id":12930977,"avatar_url":"https://avatars.githubusercontent.com/u/12930977?v=3","gravatar_id":"","url":"https://api.github.com/users/nisheetjain","html_url":"https://github.com/nisheetjain","followers_url":"https://api.github.com/users/nisheetjain/followers","following_url":"https://api.github.com/users/nisheetjain/following{/other_user}","gists_url":"https://api.github.com/users/nisheetjain/gists{/gist_id}","starred_url":"https://api.github.com/users/nisheetjain/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nisheetjain/subscriptions","organizations_url":"https://api.github.com/users/nisheetjain/orgs","repos_url":"https://api.github.com/users/nisheetjain/repos","events_url":"https://api.github.com/users/nisheetjain/events{/privacy}","received_events_url":"https://api.github.com/users/nisheetjain/received_events","type":"User","site_admin":false},"body":"TacoCommandBase can now do a simple name based comparison to route\r\nsubcommands\r\nISubCommand has access to parent ICommand for alias resolving and\r\nredirection\r\nICommand.run takes string args","created_at":"2015-11-30T19:11:35Z","updated_at":"2015-11-30T21:00:07Z","closed_at":null,"merged_at":null,"merge_commit_sha":"7ead273233239c8a45cd733aae13ea6d06de7fa9","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/Microsoft/TACO/pulls/187/commits","review_comments_url":"https://api.github.com/repos/Microsoft/TACO/pulls/187/comments","review_comment_url":"https://api.github.com/repos/Microsoft/TACO/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Microsoft/TACO/issues/187/comments","statuses_url":"https://api.github.com/repos/Microsoft/TACO/statuses/58dbd62ecaf8678b868573ff9e1a95395ac14188","head":{"label":"Microsoft:commandsFix","ref":"commandsFix","sha":"58dbd62ecaf8678b868573ff9e1a95395ac14188","user":{"login":"Microsoft","id":6154722,"avatar_url":"https://avatars.githubusercontent.com/u/6154722?v=3","gravatar_id":"","url":"https://api.github.com/users/Microsoft","html_url":"https://github.com/Microsoft","followers_url":"https://api.github.com/users/Microsoft/followers","following_url":"https://api.github.com/users/Microsoft/following{/other_user}","gists_url":"https://api.github.com/users/Microsoft/gists{/gist_id}","starred_url":"https://api.github.com/users/Microsoft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Microsoft/subscriptions","organizations_url":"https://api.github.com/users/Microsoft/orgs","repos_url":"https://api.github.com/users/Microsoft/repos","events_url":"https://api.github.com/users/Microsoft/events{/privacy}","received_events_url":"https://api.github.com/users/Microsoft/received_events","type":"Organization","site_admin":false},"repo":{"id":41325355,"name":"TACO","full_name":"Microsoft/TACO","owner":{"login":"Microsoft","id":6154722,"avatar_url":"https://avatars.githubusercontent.com/u/6154722?v=3","gravatar_id":"","url":"https://api.github.com/users/Microsoft","html_url":"https://github.com/Microsoft","followers_url":"https://api.github.com/users/Microsoft/followers","following_url":"https://api.github.com/users/Microsoft/following{/other_user}","gists_url":"https://api.github.com/users/Microsoft/gists{/gist_id}","starred_url":"https://api.github.com/users/Microsoft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Microsoft/subscriptions","organizations_url":"https://api.github.com/users/Microsoft/orgs","repos_url":"https://api.github.com/users/Microsoft/repos","events_url":"https://api.github.com/users/Microsoft/events{/privacy}","received_events_url":"https://api.github.com/users/Microsoft/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Microsoft/TACO","description":"Tools for Apache Cordova","fork":false,"url":"https://api.github.com/repos/Microsoft/TACO","forks_url":"https://api.github.com/repos/Microsoft/TACO/forks","keys_url":"https://api.github.com/repos/Microsoft/TACO/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Microsoft/TACO/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Microsoft/TACO/teams","hooks_url":"https://api.github.com/repos/Microsoft/TACO/hooks","issue_events_url":"https://api.github.com/repos/Microsoft/TACO/issues/events{/number}","events_url":"https://api.github.com/repos/Microsoft/TACO/events","assignees_url":"https://api.github.com/repos/Microsoft/TACO/assignees{/user}","branches_url":"https://api.github.com/repos/Microsoft/TACO/branches{/branch}","tags_url":"https://api.github.com/repos/Microsoft/TACO/tags","blobs_url":"https://api.github.com/repos/Microsoft/TACO/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Microsoft/TACO/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Microsoft/TACO/git/refs{/sha}","trees_url":"https://api.github.com/repos/Microsoft/TACO/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Microsoft/TACO/statuses/{sha}","languages_url":"https://api.github.com/repos/Microsoft/TACO/languages","stargazers_url":"https://api.github.com/repos/Microsoft/TACO/stargazers","contributors_url":"https://api.github.com/repos/Microsoft/TACO/contributors","subscribers_url":"https://api.github.com/repos/Microsoft/TACO/subscribers","subscription_url":"https://api.github.com/repos/Microsoft/TACO/subscription","commits_url":"https://api.github.com/repos/Microsoft/TACO/commits{/sha}","git_commits_url":"https://api.github.com/repos/Microsoft/TACO/git/commits{/sha}","comments_url":"https://api.github.com/repos/Microsoft/TACO/comments{/number}","issue_comment_url":"https://api.github.com/repos/Microsoft/TACO/issues/comments{/number}","contents_url":"https://api.github.com/repos/Microsoft/TACO/contents/{+path}","compare_url":"https://api.github.com/repos/Microsoft/TACO/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Microsoft/TACO/merges","archive_url":"https://api.github.com/repos/Microsoft/TACO/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Microsoft/TACO/downloads","issues_url":"https://api.github.com/repos/Microsoft/TACO/issues{/number}","pulls_url":"https://api.github.com/repos/Microsoft/TACO/pulls{/number}","milestones_url":"https://api.github.com/repos/Microsoft/TACO/milestones{/number}","notifications_url":"https://api.github.com/repos/Microsoft/TACO/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Microsoft/TACO/labels{/name}","releases_url":"https://api.github.com/repos/Microsoft/TACO/releases{/id}","created_at":"2015-08-24T20:26:25Z","updated_at":"2015-11-30T08:42:04Z","pushed_at":"2015-11-30T19:23:08Z","git_url":"git://github.com/Microsoft/TACO.git","ssh_url":"git@github.com:Microsoft/TACO.git","clone_url":"https://github.com/Microsoft/TACO.git","svn_url":"https://github.com/Microsoft/TACO","homepage":null,"size":5545,"stargazers_count":107,"watchers_count":107,"language":"TypeScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":17,"mirror_url":null,"open_issues_count":10,"forks":17,"open_issues":10,"watchers":107,"default_branch":"master"}},"base":{"label":"Microsoft:master","ref":"master","sha":"24c65739392a807862bef468eb1195fcc8db8e6f","user":{"login":"Microsoft","id":6154722,"avatar_url":"https://avatars.githubusercontent.com/u/6154722?v=3","gravatar_id":"","url":"https://api.github.com/users/Microsoft","html_url":"https://github.com/Microsoft","followers_url":"https://api.github.com/users/Microsoft/followers","following_url":"https://api.github.com/users/Microsoft/following{/other_user}","gists_url":"https://api.github.com/users/Microsoft/gists{/gist_id}","starred_url":"https://api.github.com/users/Microsoft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Microsoft/subscriptions","organizations_url":"https://api.github.com/users/Microsoft/orgs","repos_url":"https://api.github.com/users/Microsoft/repos","events_url":"https://api.github.com/users/Microsoft/events{/privacy}","received_events_url":"https://api.github.com/users/Microsoft/received_events","type":"Organization","site_admin":false},"repo":{"id":41325355,"name":"TACO","full_name":"Microsoft/TACO","owner":{"login":"Microsoft","id":6154722,"avatar_url":"https://avatars.githubusercontent.com/u/6154722?v=3","gravatar_id":"","url":"https://api.github.com/users/Microsoft","html_url":"https://github.com/Microsoft","followers_url":"https://api.github.com/users/Microsoft/followers","following_url":"https://api.github.com/users/Microsoft/following{/other_user}","gists_url":"https://api.github.com/users/Microsoft/gists{/gist_id}","starred_url":"https://api.github.com/users/Microsoft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Microsoft/subscriptions","organizations_url":"https://api.github.com/users/Microsoft/orgs","repos_url":"https://api.github.com/users/Microsoft/repos","events_url":"https://api.github.com/users/Microsoft/events{/privacy}","received_events_url":"https://api.github.com/users/Microsoft/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Microsoft/TACO","description":"Tools for Apache Cordova","fork":false,"url":"https://api.github.com/repos/Microsoft/TACO","forks_url":"https://api.github.com/repos/Microsoft/TACO/forks","keys_url":"https://api.github.com/repos/Microsoft/TACO/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Microsoft/TACO/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Microsoft/TACO/teams","hooks_url":"https://api.github.com/repos/Microsoft/TACO/hooks","issue_events_url":"https://api.github.com/repos/Microsoft/TACO/issues/events{/number}","events_url":"https://api.github.com/repos/Microsoft/TACO/events","assignees_url":"https://api.github.com/repos/Microsoft/TACO/assignees{/user}","branches_url":"https://api.github.com/repos/Microsoft/TACO/branches{/branch}","tags_url":"https://api.github.com/repos/Microsoft/TACO/tags","blobs_url":"https://api.github.com/repos/Microsoft/TACO/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Microsoft/TACO/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Microsoft/TACO/git/refs{/sha}","trees_url":"https://api.github.com/repos/Microsoft/TACO/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Microsoft/TACO/statuses/{sha}","languages_url":"https://api.github.com/repos/Microsoft/TACO/languages","stargazers_url":"https://api.github.com/repos/Microsoft/TACO/stargazers","contributors_url":"https://api.github.com/repos/Microsoft/TACO/contributors","subscribers_url":"https://api.github.com/repos/Microsoft/TACO/subscribers","subscription_url":"https://api.github.com/repos/Microsoft/TACO/subscription","commits_url":"https://api.github.com/repos/Microsoft/TACO/commits{/sha}","git_commits_url":"https://api.github.com/repos/Microsoft/TACO/git/commits{/sha}","comments_url":"https://api.github.com/repos/Microsoft/TACO/comments{/number}","issue_comment_url":"https://api.github.com/repos/Microsoft/TACO/issues/comments{/number}","contents_url":"https://api.github.com/repos/Microsoft/TACO/contents/{+path}","compare_url":"https://api.github.com/repos/Microsoft/TACO/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Microsoft/TACO/merges","archive_url":"https://api.github.com/repos/Microsoft/TACO/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Microsoft/TACO/downloads","issues_url":"https://api.github.com/repos/Microsoft/TACO/issues{/number}","pulls_url":"https://api.github.com/repos/Microsoft/TACO/pulls{/number}","milestones_url":"https://api.github.com/repos/Microsoft/TACO/milestones{/number}","notifications_url":"https://api.github.com/repos/Microsoft/TACO/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Microsoft/TACO/labels{/name}","releases_url":"https://api.github.com/repos/Microsoft/TACO/releases{/id}","created_at":"2015-08-24T20:26:25Z","updated_at":"2015-11-30T08:42:04Z","pushed_at":"2015-11-30T19:23:08Z","git_url":"git://github.com/Microsoft/TACO.git","ssh_url":"git@github.com:Microsoft/TACO.git","clone_url":"https://github.com/Microsoft/TACO.git","svn_url":"https://github.com/Microsoft/TACO","homepage":null,"size":5545,"stargazers_count":107,"watchers_count":107,"language":"TypeScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":17,"mirror_url":null,"open_issues_count":10,"forks":17,"open_issues":10,"watchers":107,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Microsoft/TACO/pulls/187"},"html":{"href":"https://github.com/Microsoft/TACO/pull/187"},"issue":{"href":"https://api.github.com/repos/Microsoft/TACO/issues/187"},"comments":{"href":"https://api.github.com/repos/Microsoft/TACO/issues/187/comments"},"review_comments":{"href":"https://api.github.com/repos/Microsoft/TACO/pulls/187/comments"},"review_comment":{"href":"https://api.github.com/repos/Microsoft/TACO/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Microsoft/TACO/pulls/187/commits"},"statuses":{"href":"https://api.github.com/repos/Microsoft/TACO/statuses/58dbd62ecaf8678b868573ff9e1a95395ac14188"}}}}