{"action":"created","comment":{"url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/pulls/comments/55060164","id":55060164,"diff_hunk":"@@ -15,12 +16,29 @@ class Monkey extends AdbTask {\n \n     @TaskAction\n     void exec() {\n-        def arguments = ['shell', 'monkey', '-p', packageName, '-v', getEvents()]\n+        def arguments = ['shell', 'monkey', '-p', packageName]\n+        arguments += getFormattedCategories()\n+        arguments += ['-v', getEvents()]\n         if (getSeed())\n             arguments += ['-s', getSeed()]\n         assertDeviceAndRunCommand(arguments)\n     }\n \n+    def getFormattedCategories() {\n+        def formattedCategories = []\n+        def categories = getCategories()\n+        categories.each {\n+            formattedCategories.add(\"-c \" + it)\n+        }\n+        formattedCategories\n+    }","path":"gradle-android-command-plugin/src/main/groovy/com/novoda/gradle/command/Monkey.groovy","position":28,"original_position":28,"commit_id":"5182db278ad08e7e8aa3d254d107615c88368911","original_commit_id":"5182db278ad08e7e8aa3d254d107615c88368911","user":{"login":"jonreeve","id":1180469,"avatar_url":"https://avatars.githubusercontent.com/u/1180469?v=3","gravatar_id":"","url":"https://api.github.com/users/jonreeve","html_url":"https://github.com/jonreeve","followers_url":"https://api.github.com/users/jonreeve/followers","following_url":"https://api.github.com/users/jonreeve/following{/other_user}","gists_url":"https://api.github.com/users/jonreeve/gists{/gist_id}","starred_url":"https://api.github.com/users/jonreeve/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonreeve/subscriptions","organizations_url":"https://api.github.com/users/jonreeve/orgs","repos_url":"https://api.github.com/users/jonreeve/repos","events_url":"https://api.github.com/users/jonreeve/events{/privacy}","received_events_url":"https://api.github.com/users/jonreeve/received_events","type":"User","site_admin":false},"body":"yup, exactly :smile: Closures ftw","created_at":"2016-03-04T17:29:04Z","updated_at":"2016-03-04T17:29:04Z","html_url":"https://github.com/novoda/gradle-android-command-plugin/pull/90#discussion_r55060164","pull_request_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/pulls/90","_links":{"self":{"href":"https://api.github.com/repos/novoda/gradle-android-command-plugin/pulls/comments/55060164"},"html":{"href":"https://github.com/novoda/gradle-android-command-plugin/pull/90#discussion_r55060164"},"pull_request":{"href":"https://api.github.com/repos/novoda/gradle-android-command-plugin/pulls/90"}}},"pull_request":{"url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/pulls/90","id":61741722,"html_url":"https://github.com/novoda/gradle-android-command-plugin/pull/90","diff_url":"https://github.com/novoda/gradle-android-command-plugin/pull/90.diff","patch_url":"https://github.com/novoda/gradle-android-command-plugin/pull/90.patch","issue_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/issues/90","number":90,"state":"open","locked":false,"title":"Adds feature to filter monkey by intent category","user":{"login":"jackSzm","id":6136159,"avatar_url":"https://avatars.githubusercontent.com/u/6136159?v=3","gravatar_id":"","url":"https://api.github.com/users/jackSzm","html_url":"https://github.com/jackSzm","followers_url":"https://api.github.com/users/jackSzm/followers","following_url":"https://api.github.com/users/jackSzm/following{/other_user}","gists_url":"https://api.github.com/users/jackSzm/gists{/gist_id}","starred_url":"https://api.github.com/users/jackSzm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jackSzm/subscriptions","organizations_url":"https://api.github.com/users/jackSzm/orgs","repos_url":"https://api.github.com/users/jackSzm/repos","events_url":"https://api.github.com/users/jackSzm/events{/privacy}","received_events_url":"https://api.github.com/users/jackSzm/received_events","type":"User","site_admin":false},"body":"This PR Adds feature to filter monkey by intent category. \r\n\r\nIt's done by adding `'-c' INTENT_FILTER` to the shell command. \r\nDefault to the monkeys normal categories if `-c` not specified\r\n\r\n\r\nPaired with @blundell ","created_at":"2016-03-04T17:11:44Z","updated_at":"2016-03-04T17:29:04Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a9491757a1eb26903c6fc70c3dce877cfa3c43af","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/pulls/90/commits","review_comments_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/pulls/90/comments","review_comment_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/pulls/comments{/number}","comments_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/issues/90/comments","statuses_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/statuses/5182db278ad08e7e8aa3d254d107615c88368911","head":{"label":"novoda:category_filter","ref":"category_filter","sha":"5182db278ad08e7e8aa3d254d107615c88368911","user":{"login":"novoda","id":74874,"avatar_url":"https://avatars.githubusercontent.com/u/74874?v=3","gravatar_id":"","url":"https://api.github.com/users/novoda","html_url":"https://github.com/novoda","followers_url":"https://api.github.com/users/novoda/followers","following_url":"https://api.github.com/users/novoda/following{/other_user}","gists_url":"https://api.github.com/users/novoda/gists{/gist_id}","starred_url":"https://api.github.com/users/novoda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/novoda/subscriptions","organizations_url":"https://api.github.com/users/novoda/orgs","repos_url":"https://api.github.com/users/novoda/repos","events_url":"https://api.github.com/users/novoda/events{/privacy}","received_events_url":"https://api.github.com/users/novoda/received_events","type":"Organization","site_admin":false},"repo":{"id":19490270,"name":"gradle-android-command-plugin","full_name":"novoda/gradle-android-command-plugin","owner":{"login":"novoda","id":74874,"avatar_url":"https://avatars.githubusercontent.com/u/74874?v=3","gravatar_id":"","url":"https://api.github.com/users/novoda","html_url":"https://github.com/novoda","followers_url":"https://api.github.com/users/novoda/followers","following_url":"https://api.github.com/users/novoda/following{/other_user}","gists_url":"https://api.github.com/users/novoda/gists{/gist_id}","starred_url":"https://api.github.com/users/novoda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/novoda/subscriptions","organizations_url":"https://api.github.com/users/novoda/orgs","repos_url":"https://api.github.com/users/novoda/repos","events_url":"https://api.github.com/users/novoda/events{/privacy}","received_events_url":"https://api.github.com/users/novoda/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/novoda/gradle-android-command-plugin","description":"Handy commands for testing Android on CI","fork":false,"url":"https://api.github.com/repos/novoda/gradle-android-command-plugin","forks_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/forks","keys_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/teams","hooks_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/hooks","issue_events_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/issues/events{/number}","events_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/events","assignees_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/assignees{/user}","branches_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/branches{/branch}","tags_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/tags","blobs_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/git/refs{/sha}","trees_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/statuses/{sha}","languages_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/languages","stargazers_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/stargazers","contributors_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/contributors","subscribers_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/subscribers","subscription_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/subscription","commits_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/commits{/sha}","git_commits_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/git/commits{/sha}","comments_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/comments{/number}","issue_comment_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/issues/comments{/number}","contents_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/contents/{+path}","compare_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/merges","archive_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/downloads","issues_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/issues{/number}","pulls_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/pulls{/number}","milestones_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/milestones{/number}","notifications_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/labels{/name}","releases_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/releases{/id}","deployments_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/deployments","created_at":"2014-05-06T10:29:18Z","updated_at":"2016-02-29T06:57:06Z","pushed_at":"2016-03-04T17:11:44Z","git_url":"git://github.com/novoda/gradle-android-command-plugin.git","ssh_url":"git@github.com:novoda/gradle-android-command-plugin.git","clone_url":"https://github.com/novoda/gradle-android-command-plugin.git","svn_url":"https://github.com/novoda/gradle-android-command-plugin","homepage":"","size":486,"stargazers_count":150,"watchers_count":150,"language":"Groovy","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":17,"mirror_url":null,"open_issues_count":15,"forks":17,"open_issues":15,"watchers":150,"default_branch":"develop"}},"base":{"label":"novoda:develop","ref":"develop","sha":"9c81f2d1b00d7195db037700670a4237037c784d","user":{"login":"novoda","id":74874,"avatar_url":"https://avatars.githubusercontent.com/u/74874?v=3","gravatar_id":"","url":"https://api.github.com/users/novoda","html_url":"https://github.com/novoda","followers_url":"https://api.github.com/users/novoda/followers","following_url":"https://api.github.com/users/novoda/following{/other_user}","gists_url":"https://api.github.com/users/novoda/gists{/gist_id}","starred_url":"https://api.github.com/users/novoda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/novoda/subscriptions","organizations_url":"https://api.github.com/users/novoda/orgs","repos_url":"https://api.github.com/users/novoda/repos","events_url":"https://api.github.com/users/novoda/events{/privacy}","received_events_url":"https://api.github.com/users/novoda/received_events","type":"Organization","site_admin":false},"repo":{"id":19490270,"name":"gradle-android-command-plugin","full_name":"novoda/gradle-android-command-plugin","owner":{"login":"novoda","id":74874,"avatar_url":"https://avatars.githubusercontent.com/u/74874?v=3","gravatar_id":"","url":"https://api.github.com/users/novoda","html_url":"https://github.com/novoda","followers_url":"https://api.github.com/users/novoda/followers","following_url":"https://api.github.com/users/novoda/following{/other_user}","gists_url":"https://api.github.com/users/novoda/gists{/gist_id}","starred_url":"https://api.github.com/users/novoda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/novoda/subscriptions","organizations_url":"https://api.github.com/users/novoda/orgs","repos_url":"https://api.github.com/users/novoda/repos","events_url":"https://api.github.com/users/novoda/events{/privacy}","received_events_url":"https://api.github.com/users/novoda/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/novoda/gradle-android-command-plugin","description":"Handy commands for testing Android on CI","fork":false,"url":"https://api.github.com/repos/novoda/gradle-android-command-plugin","forks_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/forks","keys_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/teams","hooks_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/hooks","issue_events_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/issues/events{/number}","events_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/events","assignees_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/assignees{/user}","branches_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/branches{/branch}","tags_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/tags","blobs_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/git/refs{/sha}","trees_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/statuses/{sha}","languages_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/languages","stargazers_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/stargazers","contributors_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/contributors","subscribers_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/subscribers","subscription_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/subscription","commits_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/commits{/sha}","git_commits_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/git/commits{/sha}","comments_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/comments{/number}","issue_comment_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/issues/comments{/number}","contents_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/contents/{+path}","compare_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/merges","archive_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/downloads","issues_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/issues{/number}","pulls_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/pulls{/number}","milestones_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/milestones{/number}","notifications_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/labels{/name}","releases_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/releases{/id}","deployments_url":"https://api.github.com/repos/novoda/gradle-android-command-plugin/deployments","created_at":"2014-05-06T10:29:18Z","updated_at":"2016-02-29T06:57:06Z","pushed_at":"2016-03-04T17:11:44Z","git_url":"git://github.com/novoda/gradle-android-command-plugin.git","ssh_url":"git@github.com:novoda/gradle-android-command-plugin.git","clone_url":"https://github.com/novoda/gradle-android-command-plugin.git","svn_url":"https://github.com/novoda/gradle-android-command-plugin","homepage":"","size":486,"stargazers_count":150,"watchers_count":150,"language":"Groovy","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":17,"mirror_url":null,"open_issues_count":15,"forks":17,"open_issues":15,"watchers":150,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/novoda/gradle-android-command-plugin/pulls/90"},"html":{"href":"https://github.com/novoda/gradle-android-command-plugin/pull/90"},"issue":{"href":"https://api.github.com/repos/novoda/gradle-android-command-plugin/issues/90"},"comments":{"href":"https://api.github.com/repos/novoda/gradle-android-command-plugin/issues/90/comments"},"review_comments":{"href":"https://api.github.com/repos/novoda/gradle-android-command-plugin/pulls/90/comments"},"review_comment":{"href":"https://api.github.com/repos/novoda/gradle-android-command-plugin/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/novoda/gradle-android-command-plugin/pulls/90/commits"},"statuses":{"href":"https://api.github.com/repos/novoda/gradle-android-command-plugin/statuses/5182db278ad08e7e8aa3d254d107615c88368911"}}}}