{"action":"created","comment":{"url":"https://api.github.com/repos/coala-analyzer/coala-bears/pulls/comments/66713502","id":66713502,"diff_hunk":"@@ -1,22 +1,69 @@\n from coalib.bearlib.abstractions.Linter import linter\n+from coalib.bearlib.spacing.SpacingHelper import SpacingHelper\n from coalib.parsing.StringProcessing import escape\n \n \n+def _map_to_r_bool(py_bool):\n+    return 'TRUE' if py_bool else 'FALSE'\n+\n+\n @linter(executable='Rscript',\n         output_format='corrected',\n         prerequisite_check_command=('Rscript', '-e', 'library(formatR)'),\n         prerequisite_check_fail_message='Please install formatR for this bear '\n                                         'to work.')\n class FormatRBear:\n-\n     \"\"\"\n     Check and correct formatting of R Code using known formatR utility.\n     \"\"\"\n     LANGUAGES = \"R\"\n \n     @staticmethod\n-    def create_arguments(filename, file, config_file):\n+    def create_arguments(filename, file, config_file,\n+                         r_keep_comments: bool=True,\n+                         r_keep_blank_lines: bool=True,\n+                         r_braces_on_next_line: bool=False,\n+                         r_use_arrows: bool=False,\n+                         tab_width: int=SpacingHelper.DEFAULT_TAB_WIDTH,\n+                         r_max_expression_length: int=20):\n+        \"\"\"\n+        :param r_keep_comments:         Determines whether comments are\n+                                        kept or not.\n+        :param r_keep_blank_lines:      Determines whether blank lines\n+                                        are kept or not.\n+        :param r_braces_on_next_line:   Determines wheter a brace should\n+                                        be placed on the next line\n+                                        Example: if `True`,\n+                                        \"if (...)\n+                                        {\"   instead of \"if (...) {\"\n+        :param r_use_arrows:            Determines if either the assign\n+                                        operator ``=`` or the arrow ``<-``\n+                                        should be used\n+                                        Example: if `True`,\n+                                        \"x = 1\" becomes \"x <- 1\".","path":"bears/r/FormatRBear.py","position":63,"original_position":45,"commit_id":"e523138a51b315931fdbf96413ca230f202e4205","original_commit_id":"e523138a51b315931fdbf96413ca230f202e4205","user":{"login":"Asnelchristian","id":10449314,"avatar_url":"https://avatars.githubusercontent.com/u/10449314?v=3","gravatar_id":"","url":"https://api.github.com/users/Asnelchristian","html_url":"https://github.com/Asnelchristian","followers_url":"https://api.github.com/users/Asnelchristian/followers","following_url":"https://api.github.com/users/Asnelchristian/following{/other_user}","gists_url":"https://api.github.com/users/Asnelchristian/gists{/gist_id}","starred_url":"https://api.github.com/users/Asnelchristian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Asnelchristian/subscriptions","organizations_url":"https://api.github.com/users/Asnelchristian/orgs","repos_url":"https://api.github.com/users/Asnelchristian/repos","events_url":"https://api.github.com/users/Asnelchristian/events{/privacy}","received_events_url":"https://api.github.com/users/Asnelchristian/received_events","type":"User","site_admin":false},"body":"okay ","created_at":"2016-06-11T23:55:20Z","updated_at":"2016-06-11T23:55:20Z","html_url":"https://github.com/coala-analyzer/coala-bears/pull/465#discussion_r66713502","pull_request_url":"https://api.github.com/repos/coala-analyzer/coala-bears/pulls/465","_links":{"self":{"href":"https://api.github.com/repos/coala-analyzer/coala-bears/pulls/comments/66713502"},"html":{"href":"https://github.com/coala-analyzer/coala-bears/pull/465#discussion_r66713502"},"pull_request":{"href":"https://api.github.com/repos/coala-analyzer/coala-bears/pulls/465"}}},"pull_request":{"url":"https://api.github.com/repos/coala-analyzer/coala-bears/pulls/465","id":71729311,"html_url":"https://github.com/coala-analyzer/coala-bears/pull/465","diff_url":"https://github.com/coala-analyzer/coala-bears/pull/465.diff","patch_url":"https://github.com/coala-analyzer/coala-bears/pull/465.patch","issue_url":"https://api.github.com/repos/coala-analyzer/coala-bears/issues/465","number":465,"state":"open","locked":false,"title":"FormatRBear: Add configs to tidy_source","user":{"login":"Asnelchristian","id":10449314,"avatar_url":"https://avatars.githubusercontent.com/u/10449314?v=3","gravatar_id":"","url":"https://api.github.com/users/Asnelchristian","html_url":"https://github.com/Asnelchristian","followers_url":"https://api.github.com/users/Asnelchristian/followers","following_url":"https://api.github.com/users/Asnelchristian/following{/other_user}","gists_url":"https://api.github.com/users/Asnelchristian/gists{/gist_id}","starred_url":"https://api.github.com/users/Asnelchristian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Asnelchristian/subscriptions","organizations_url":"https://api.github.com/users/Asnelchristian/orgs","repos_url":"https://api.github.com/users/Asnelchristian/repos","events_url":"https://api.github.com/users/Asnelchristian/events{/privacy}","received_events_url":"https://api.github.com/users/Asnelchristian/received_events","type":"User","site_admin":false},"body":"\r\n\r\nFixes https://github.com/coala-analyzer/coala-bears/issues/376","created_at":"2016-05-27T15:17:03Z","updated_at":"2016-06-11T23:55:20Z","closed_at":null,"merged_at":null,"merge_commit_sha":"45d554ccbe0f9c0d92f7312a027943f4821f1da1","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/coala-analyzer/coala-bears/pulls/465/commits","review_comments_url":"https://api.github.com/repos/coala-analyzer/coala-bears/pulls/465/comments","review_comment_url":"https://api.github.com/repos/coala-analyzer/coala-bears/pulls/comments{/number}","comments_url":"https://api.github.com/repos/coala-analyzer/coala-bears/issues/465/comments","statuses_url":"https://api.github.com/repos/coala-analyzer/coala-bears/statuses/e523138a51b315931fdbf96413ca230f202e4205","head":{"label":"Asnelchristian:master","ref":"master","sha":"e523138a51b315931fdbf96413ca230f202e4205","user":{"login":"Asnelchristian","id":10449314,"avatar_url":"https://avatars.githubusercontent.com/u/10449314?v=3","gravatar_id":"","url":"https://api.github.com/users/Asnelchristian","html_url":"https://github.com/Asnelchristian","followers_url":"https://api.github.com/users/Asnelchristian/followers","following_url":"https://api.github.com/users/Asnelchristian/following{/other_user}","gists_url":"https://api.github.com/users/Asnelchristian/gists{/gist_id}","starred_url":"https://api.github.com/users/Asnelchristian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Asnelchristian/subscriptions","organizations_url":"https://api.github.com/users/Asnelchristian/orgs","repos_url":"https://api.github.com/users/Asnelchristian/repos","events_url":"https://api.github.com/users/Asnelchristian/events{/privacy}","received_events_url":"https://api.github.com/users/Asnelchristian/received_events","type":"User","site_admin":false},"repo":{"id":59282550,"name":"coala-bears","full_name":"Asnelchristian/coala-bears","owner":{"login":"Asnelchristian","id":10449314,"avatar_url":"https://avatars.githubusercontent.com/u/10449314?v=3","gravatar_id":"","url":"https://api.github.com/users/Asnelchristian","html_url":"https://github.com/Asnelchristian","followers_url":"https://api.github.com/users/Asnelchristian/followers","following_url":"https://api.github.com/users/Asnelchristian/following{/other_user}","gists_url":"https://api.github.com/users/Asnelchristian/gists{/gist_id}","starred_url":"https://api.github.com/users/Asnelchristian/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Asnelchristian/subscriptions","organizations_url":"https://api.github.com/users/Asnelchristian/orgs","repos_url":"https://api.github.com/users/Asnelchristian/repos","events_url":"https://api.github.com/users/Asnelchristian/events{/privacy}","received_events_url":"https://api.github.com/users/Asnelchristian/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Asnelchristian/coala-bears","description":"Bears for coala","fork":true,"url":"https://api.github.com/repos/Asnelchristian/coala-bears","forks_url":"https://api.github.com/repos/Asnelchristian/coala-bears/forks","keys_url":"https://api.github.com/repos/Asnelchristian/coala-bears/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Asnelchristian/coala-bears/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Asnelchristian/coala-bears/teams","hooks_url":"https://api.github.com/repos/Asnelchristian/coala-bears/hooks","issue_events_url":"https://api.github.com/repos/Asnelchristian/coala-bears/issues/events{/number}","events_url":"https://api.github.com/repos/Asnelchristian/coala-bears/events","assignees_url":"https://api.github.com/repos/Asnelchristian/coala-bears/assignees{/user}","branches_url":"https://api.github.com/repos/Asnelchristian/coala-bears/branches{/branch}","tags_url":"https://api.github.com/repos/Asnelchristian/coala-bears/tags","blobs_url":"https://api.github.com/repos/Asnelchristian/coala-bears/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Asnelchristian/coala-bears/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Asnelchristian/coala-bears/git/refs{/sha}","trees_url":"https://api.github.com/repos/Asnelchristian/coala-bears/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Asnelchristian/coala-bears/statuses/{sha}","languages_url":"https://api.github.com/repos/Asnelchristian/coala-bears/languages","stargazers_url":"https://api.github.com/repos/Asnelchristian/coala-bears/stargazers","contributors_url":"https://api.github.com/repos/Asnelchristian/coala-bears/contributors","subscribers_url":"https://api.github.com/repos/Asnelchristian/coala-bears/subscribers","subscription_url":"https://api.github.com/repos/Asnelchristian/coala-bears/subscription","commits_url":"https://api.github.com/repos/Asnelchristian/coala-bears/commits{/sha}","git_commits_url":"https://api.github.com/repos/Asnelchristian/coala-bears/git/commits{/sha}","comments_url":"https://api.github.com/repos/Asnelchristian/coala-bears/comments{/number}","issue_comment_url":"https://api.github.com/repos/Asnelchristian/coala-bears/issues/comments{/number}","contents_url":"https://api.github.com/repos/Asnelchristian/coala-bears/contents/{+path}","compare_url":"https://api.github.com/repos/Asnelchristian/coala-bears/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Asnelchristian/coala-bears/merges","archive_url":"https://api.github.com/repos/Asnelchristian/coala-bears/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Asnelchristian/coala-bears/downloads","issues_url":"https://api.github.com/repos/Asnelchristian/coala-bears/issues{/number}","pulls_url":"https://api.github.com/repos/Asnelchristian/coala-bears/pulls{/number}","milestones_url":"https://api.github.com/repos/Asnelchristian/coala-bears/milestones{/number}","notifications_url":"https://api.github.com/repos/Asnelchristian/coala-bears/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Asnelchristian/coala-bears/labels{/name}","releases_url":"https://api.github.com/repos/Asnelchristian/coala-bears/releases{/id}","deployments_url":"https://api.github.com/repos/Asnelchristian/coala-bears/deployments","created_at":"2016-05-20T09:33:44Z","updated_at":"2016-05-20T09:33:45Z","pushed_at":"2016-06-11T22:46:54Z","git_url":"git://github.com/Asnelchristian/coala-bears.git","ssh_url":"git@github.com:Asnelchristian/coala-bears.git","clone_url":"https://github.com/Asnelchristian/coala-bears.git","svn_url":"https://github.com/Asnelchristian/coala-bears","homepage":"http://coala-analyzer.org/","size":524,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"coala-analyzer:master","ref":"master","sha":"d90bd80c85adfeefc14c51466bab48bce7619c53","user":{"login":"coala-analyzer","id":10620750,"avatar_url":"https://avatars.githubusercontent.com/u/10620750?v=3","gravatar_id":"","url":"https://api.github.com/users/coala-analyzer","html_url":"https://github.com/coala-analyzer","followers_url":"https://api.github.com/users/coala-analyzer/followers","following_url":"https://api.github.com/users/coala-analyzer/following{/other_user}","gists_url":"https://api.github.com/users/coala-analyzer/gists{/gist_id}","starred_url":"https://api.github.com/users/coala-analyzer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/coala-analyzer/subscriptions","organizations_url":"https://api.github.com/users/coala-analyzer/orgs","repos_url":"https://api.github.com/users/coala-analyzer/repos","events_url":"https://api.github.com/users/coala-analyzer/events{/privacy}","received_events_url":"https://api.github.com/users/coala-analyzer/received_events","type":"Organization","site_admin":false},"repo":{"id":51688289,"name":"coala-bears","full_name":"coala-analyzer/coala-bears","owner":{"login":"coala-analyzer","id":10620750,"avatar_url":"https://avatars.githubusercontent.com/u/10620750?v=3","gravatar_id":"","url":"https://api.github.com/users/coala-analyzer","html_url":"https://github.com/coala-analyzer","followers_url":"https://api.github.com/users/coala-analyzer/followers","following_url":"https://api.github.com/users/coala-analyzer/following{/other_user}","gists_url":"https://api.github.com/users/coala-analyzer/gists{/gist_id}","starred_url":"https://api.github.com/users/coala-analyzer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/coala-analyzer/subscriptions","organizations_url":"https://api.github.com/users/coala-analyzer/orgs","repos_url":"https://api.github.com/users/coala-analyzer/repos","events_url":"https://api.github.com/users/coala-analyzer/events{/privacy}","received_events_url":"https://api.github.com/users/coala-analyzer/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/coala-analyzer/coala-bears","description":"Bears for coala","fork":false,"url":"https://api.github.com/repos/coala-analyzer/coala-bears","forks_url":"https://api.github.com/repos/coala-analyzer/coala-bears/forks","keys_url":"https://api.github.com/repos/coala-analyzer/coala-bears/keys{/key_id}","collaborators_url":"https://api.github.com/repos/coala-analyzer/coala-bears/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/coala-analyzer/coala-bears/teams","hooks_url":"https://api.github.com/repos/coala-analyzer/coala-bears/hooks","issue_events_url":"https://api.github.com/repos/coala-analyzer/coala-bears/issues/events{/number}","events_url":"https://api.github.com/repos/coala-analyzer/coala-bears/events","assignees_url":"https://api.github.com/repos/coala-analyzer/coala-bears/assignees{/user}","branches_url":"https://api.github.com/repos/coala-analyzer/coala-bears/branches{/branch}","tags_url":"https://api.github.com/repos/coala-analyzer/coala-bears/tags","blobs_url":"https://api.github.com/repos/coala-analyzer/coala-bears/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/coala-analyzer/coala-bears/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/coala-analyzer/coala-bears/git/refs{/sha}","trees_url":"https://api.github.com/repos/coala-analyzer/coala-bears/git/trees{/sha}","statuses_url":"https://api.github.com/repos/coala-analyzer/coala-bears/statuses/{sha}","languages_url":"https://api.github.com/repos/coala-analyzer/coala-bears/languages","stargazers_url":"https://api.github.com/repos/coala-analyzer/coala-bears/stargazers","contributors_url":"https://api.github.com/repos/coala-analyzer/coala-bears/contributors","subscribers_url":"https://api.github.com/repos/coala-analyzer/coala-bears/subscribers","subscription_url":"https://api.github.com/repos/coala-analyzer/coala-bears/subscription","commits_url":"https://api.github.com/repos/coala-analyzer/coala-bears/commits{/sha}","git_commits_url":"https://api.github.com/repos/coala-analyzer/coala-bears/git/commits{/sha}","comments_url":"https://api.github.com/repos/coala-analyzer/coala-bears/comments{/number}","issue_comment_url":"https://api.github.com/repos/coala-analyzer/coala-bears/issues/comments{/number}","contents_url":"https://api.github.com/repos/coala-analyzer/coala-bears/contents/{+path}","compare_url":"https://api.github.com/repos/coala-analyzer/coala-bears/compare/{base}...{head}","merges_url":"https://api.github.com/repos/coala-analyzer/coala-bears/merges","archive_url":"https://api.github.com/repos/coala-analyzer/coala-bears/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/coala-analyzer/coala-bears/downloads","issues_url":"https://api.github.com/repos/coala-analyzer/coala-bears/issues{/number}","pulls_url":"https://api.github.com/repos/coala-analyzer/coala-bears/pulls{/number}","milestones_url":"https://api.github.com/repos/coala-analyzer/coala-bears/milestones{/number}","notifications_url":"https://api.github.com/repos/coala-analyzer/coala-bears/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/coala-analyzer/coala-bears/labels{/name}","releases_url":"https://api.github.com/repos/coala-analyzer/coala-bears/releases{/id}","deployments_url":"https://api.github.com/repos/coala-analyzer/coala-bears/deployments","created_at":"2016-02-14T09:25:11Z","updated_at":"2016-05-31T23:09:27Z","pushed_at":"2016-06-11T22:46:55Z","git_url":"git://github.com/coala-analyzer/coala-bears.git","ssh_url":"git@github.com:coala-analyzer/coala-bears.git","clone_url":"https://github.com/coala-analyzer/coala-bears.git","svn_url":"https://github.com/coala-analyzer/coala-bears","homepage":"http://coala-analyzer.org/","size":640,"stargazers_count":43,"watchers_count":43,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":51,"mirror_url":null,"open_issues_count":117,"forks":51,"open_issues":117,"watchers":43,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/coala-analyzer/coala-bears/pulls/465"},"html":{"href":"https://github.com/coala-analyzer/coala-bears/pull/465"},"issue":{"href":"https://api.github.com/repos/coala-analyzer/coala-bears/issues/465"},"comments":{"href":"https://api.github.com/repos/coala-analyzer/coala-bears/issues/465/comments"},"review_comments":{"href":"https://api.github.com/repos/coala-analyzer/coala-bears/pulls/465/comments"},"review_comment":{"href":"https://api.github.com/repos/coala-analyzer/coala-bears/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/coala-analyzer/coala-bears/pulls/465/commits"},"statuses":{"href":"https://api.github.com/repos/coala-analyzer/coala-bears/statuses/e523138a51b315931fdbf96413ca230f202e4205"}}}}
{"actor":{"display_login":"Asnelchristian"}}