GitHub PullRequestEvent at 2014-10-02 19:22:30
Repository: eslint
Actor: btmills
Payload: {"action":"opened","number":1335,"pull_request":{"url":"https://api.github.com/repos/eslint/eslint/pulls/1335","id":22163612,"html_url":"https://github.com/eslint/eslint/pull/1335","diff_url":"https://github.com/eslint/eslint/pull/1335.diff","patch_url":"https://github.com/eslint/eslint/pull/1335.patch","issue_url":"https://api.github.com/repos/eslint/eslint/issues/1335","number":1335,"state":"open","locked":false,"title":"New: Add key-spacing rule (fixes #1280)","user":{"login":"btmills","id":1709537,"avatar_url":"https://avatars.githubusercontent.com/u/1709537?v=2","gravatar_id":"","url":"https://api.github.com/users/btmills","html_url":"https://github.com/btmills","followers_url":"https://api.github.com/users/btmills/followers","following_url":"https://api.github.com/users/btmills/following{/other_user}","gists_url":"https://api.github.com/users/btmills/gists{/gist_id}","starred_url":"https://api.github.com/users/btmills/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/btmills/subscriptions","organizations_url":"https://api.github.com/users/btmills/orgs","repos_url":"https://api.github.com/users/btmills/repos","events_url":"https://api.github.com/users/btmills/events{/privacy}","received_events_url":"https://api.github.com/users/btmills/received_events","type":"User","site_admin":false},"body":"I had a couple questions about this in [#1280 (comment)](https://github.com/eslint/eslint/issues/1280#issuecomment-57680914), but I went ahead with what I already had and can change it based on feedback:\r\n\r\n- On by default, no space between key and colon, one space between colon and value\r\n- Options are in order for after key and before value, with possible values being `\"always\"` or `\"never\"`.\r\n\r\nAdds a new method, `getTokensBetween`, to the tokens API. I believe this can be used in a couple other rules, so if this gets merged, I'll look for other rules that implement the same thing and switch them to use the new method.\r\n\r\nThis does not include the idea brought up by @lo1tuma in [#1280 (comment)](https://github.com/eslint/eslint/issues/1280#issuecomment-57683287), which would add additional options for vertically aligning multiple properties. I'm totally amenable to adding that to this PR if that's desirable.\r\n\r\nThere were changes to `Makefile.js`, `lib/rules/no-trailing-spaces.js`, `tests/lib/eslint.js`, and `tests/lib/rules/vars-on-top.js` required whitespace changes because this is on by default. If that's the wrong choice, I'll revert those changes.","created_at":"2014-10-02T19:22:29Z","updated_at":"2014-10-02T19:22:29Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/eslint/eslint/pulls/1335/commits","review_comments_url":"https://api.github.com/repos/eslint/eslint/pulls/1335/comments","review_comment_url":"https://api.github.com/repos/eslint/eslint/pulls/comments/{number}","comments_url":"https://api.github.com/repos/eslint/eslint/issues/1335/comments","statuses_url":"https://api.github.com/repos/eslint/eslint/statuses/7c4c069df380a8768e27d5807f9455e3e5d79f41","head":{"label":"btmills:key-spacing","ref":"key-spacing","sha":"7c4c069df380a8768e27d5807f9455e3e5d79f41","user":{"login":"btmills","id":1709537,"avatar_url":"https://avatars.githubusercontent.com/u/1709537?v=2","gravatar_id":"","url":"https://api.github.com/users/btmills","html_url":"https://github.com/btmills","followers_url":"https://api.github.com/users/btmills/followers","following_url":"https://api.github.com/users/btmills/following{/other_user}","gists_url":"https://api.github.com/users/btmills/gists{/gist_id}","starred_url":"https://api.github.com/users/btmills/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/btmills/subscriptions","organizations_url":"https://api.github.com/users/btmills/orgs","repos_url":"https://api.github.com/users/btmills/repos","events_url":"https://api.github.com/users/btmills/events{/privacy}","received_events_url":"https://api.github.com/users/btmills/received_events","type":"User","site_admin":false},"repo":{"id":16427781,"name":"eslint","full_name":"btmills/eslint","owner":{"login":"btmills","id":1709537,"avatar_url":"https://avatars.githubusercontent.com/u/1709537?v=2","gravatar_id":"","url":"https://api.github.com/users/btmills","html_url":"https://github.com/btmills","followers_url":"https://api.github.com/users/btmills/followers","following_url":"https://api.github.com/users/btmills/following{/other_user}","gists_url":"https://api.github.com/users/btmills/gists{/gist_id}","starred_url":"https://api.github.com/users/btmills/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/btmills/subscriptions","organizations_url":"https://api.github.com/users/btmills/orgs","repos_url":"https://api.github.com/users/btmills/repos","events_url":"https://api.github.com/users/btmills/events{/privacy}","received_events_url":"https://api.github.com/users/btmills/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/btmills/eslint","description":"A tool for identifying and reporting on patterns in JavaScript.","fork":true,"url":"https://api.github.com/repos/btmills/eslint","forks_url":"https://api.github.com/repos/btmills/eslint/forks","keys_url":"https://api.github.com/repos/btmills/eslint/keys{/key_id}","collaborators_url":"https://api.github.com/repos/btmills/eslint/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/btmills/eslint/teams","hooks_url":"https://api.github.com/repos/btmills/eslint/hooks","issue_events_url":"https://api.github.com/repos/btmills/eslint/issues/events{/number}","events_url":"https://api.github.com/repos/btmills/eslint/events","assignees_url":"https://api.github.com/repos/btmills/eslint/assignees{/user}","branches_url":"https://api.github.com/repos/btmills/eslint/branches{/branch}","tags_url":"https://api.github.com/repos/btmills/eslint/tags","blobs_url":"https://api.github.com/repos/btmills/eslint/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/btmills/eslint/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/btmills/eslint/git/refs{/sha}","trees_url":"https://api.github.com/repos/btmills/eslint/git/trees{/sha}","statuses_url":"https://api.github.com/repos/btmills/eslint/statuses/{sha}","languages_url":"https://api.github.com/repos/btmills/eslint/languages","stargazers_url":"https://api.github.com/repos/btmills/eslint/stargazers","contributors_url":"https://api.github.com/repos/btmills/eslint/contributors","subscribers_url":"https://api.github.com/repos/btmills/eslint/subscribers","subscription_url":"https://api.github.com/repos/btmills/eslint/subscription","commits_url":"https://api.github.com/repos/btmills/eslint/commits{/sha}","git_commits_url":"https://api.github.com/repos/btmills/eslint/git/commits{/sha}","comments_url":"https://api.github.com/repos/btmills/eslint/comments{/number}","issue_comment_url":"https://api.github.com/repos/btmills/eslint/issues/comments/{number}","contents_url":"https://api.github.com/repos/btmills/eslint/contents/{+path}","compare_url":"https://api.github.com/repos/btmills/eslint/compare/{base}...{head}","merges_url":"https://api.github.com/repos/btmills/eslint/merges","archive_url":"https://api.github.com/repos/btmills/eslint/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/btmills/eslint/downloads","issues_url":"https://api.github.com/repos/btmills/eslint/issues{/number}","pulls_url":"https://api.github.com/repos/btmills/eslint/pulls{/number}","milestones_url":"https://api.github.com/repos/btmills/eslint/milestones{/number}","notifications_url":"https://api.github.com/repos/btmills/eslint/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/btmills/eslint/labels{/name}","releases_url":"https://api.github.com/repos/btmills/eslint/releases{/id}","created_at":"2014-02-01T03:45:44Z","updated_at":"2014-08-02T17:41:54Z","pushed_at":"2014-10-02T19:21:22Z","git_url":"git://github.com/btmills/eslint.git","ssh_url":"git@github.com:btmills/eslint.git","clone_url":"https://github.com/btmills/eslint.git","svn_url":"https://github.com/btmills/eslint","homepage":null,"size":3293,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","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":"eslint:master","ref":"master","sha":"18246e5e114ebac170620638949b2ab8ebc6df47","user":{"login":"eslint","id":6019716,"avatar_url":"https://avatars.githubusercontent.com/u/6019716?v=2","gravatar_id":"","url":"https://api.github.com/users/eslint","html_url":"https://github.com/eslint","followers_url":"https://api.github.com/users/eslint/followers","following_url":"https://api.github.com/users/eslint/following{/other_user}","gists_url":"https://api.github.com/users/eslint/gists{/gist_id}","starred_url":"https://api.github.com/users/eslint/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eslint/subscriptions","organizations_url":"https://api.github.com/users/eslint/orgs","repos_url":"https://api.github.com/users/eslint/repos","events_url":"https://api.github.com/users/eslint/events{/privacy}","received_events_url":"https://api.github.com/users/eslint/received_events","type":"Organization","site_admin":false},"repo":{"id":11061773,"name":"eslint","full_name":"eslint/eslint","owner":{"login":"eslint","id":6019716,"avatar_url":"https://avatars.githubusercontent.com/u/6019716?v=2","gravatar_id":"","url":"https://api.github.com/users/eslint","html_url":"https://github.com/eslint","followers_url":"https://api.github.com/users/eslint/followers","following_url":"https://api.github.com/users/eslint/following{/other_user}","gists_url":"https://api.github.com/users/eslint/gists{/gist_id}","starred_url":"https://api.github.com/users/eslint/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eslint/subscriptions","organizations_url":"https://api.github.com/users/eslint/orgs","repos_url":"https://api.github.com/users/eslint/repos","events_url":"https://api.github.com/users/eslint/events{/privacy}","received_events_url":"https://api.github.com/users/eslint/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/eslint/eslint","description":"A fully pluggable tool for identifying and reporting on patterns in JavaScript.","fork":false,"url":"https://api.github.com/repos/eslint/eslint","forks_url":"https://api.github.com/repos/eslint/eslint/forks","keys_url":"https://api.github.com/repos/eslint/eslint/keys{/key_id}","collaborators_url":"https://api.github.com/repos/eslint/eslint/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/eslint/eslint/teams","hooks_url":"https://api.github.com/repos/eslint/eslint/hooks","issue_events_url":"https://api.github.com/repos/eslint/eslint/issues/events{/number}","events_url":"https://api.github.com/repos/eslint/eslint/events","assignees_url":"https://api.github.com/repos/eslint/eslint/assignees{/user}","branches_url":"https://api.github.com/repos/eslint/eslint/branches{/branch}","tags_url":"https://api.github.com/repos/eslint/eslint/tags","blobs_url":"https://api.github.com/repos/eslint/eslint/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/eslint/eslint/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/eslint/eslint/git/refs{/sha}","trees_url":"https://api.github.com/repos/eslint/eslint/git/trees{/sha}","statuses_url":"https://api.github.com/repos/eslint/eslint/statuses/{sha}","languages_url":"https://api.github.com/repos/eslint/eslint/languages","stargazers_url":"https://api.github.com/repos/eslint/eslint/stargazers","contributors_url":"https://api.github.com/repos/eslint/eslint/contributors","subscribers_url":"https://api.github.com/repos/eslint/eslint/subscribers","subscription_url":"https://api.github.com/repos/eslint/eslint/subscription","commits_url":"https://api.github.com/repos/eslint/eslint/commits{/sha}","git_commits_url":"https://api.github.com/repos/eslint/eslint/git/commits{/sha}","comments_url":"https://api.github.com/repos/eslint/eslint/comments{/number}","issue_comment_url":"https://api.github.com/repos/eslint/eslint/issues/comments/{number}","contents_url":"https://api.github.com/repos/eslint/eslint/contents/{+path}","compare_url":"https://api.github.com/repos/eslint/eslint/compare/{base}...{head}","merges_url":"https://api.github.com/repos/eslint/eslint/merges","archive_url":"https://api.github.com/repos/eslint/eslint/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/eslint/eslint/downloads","issues_url":"https://api.github.com/repos/eslint/eslint/issues{/number}","pulls_url":"https://api.github.com/repos/eslint/eslint/pulls{/number}","milestones_url":"https://api.github.com/repos/eslint/eslint/milestones{/number}","notifications_url":"https://api.github.com/repos/eslint/eslint/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/eslint/eslint/labels{/name}","releases_url":"https://api.github.com/repos/eslint/eslint/releases{/id}","created_at":"2013-06-29T23:59:48Z","updated_at":"2014-10-02T18:13:30Z","pushed_at":"2014-10-02T19:13:52Z","git_url":"git://github.com/eslint/eslint.git","ssh_url":"git@github.com:eslint/eslint.git","clone_url":"https://github.com/eslint/eslint.git","svn_url":"https://github.com/eslint/eslint","homepage":"http://eslint.org","size":10364,"stargazers_count":1253,"watchers_count":1253,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":198,"mirror_url":null,"open_issues_count":84,"forks":198,"open_issues":84,"watchers":1253,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/eslint/eslint/pulls/1335"},"html":{"href":"https://github.com/eslint/eslint/pull/1335"},"issue":{"href":"https://api.github.com/repos/eslint/eslint/issues/1335"},"comments":{"href":"https://api.github.com/repos/eslint/eslint/issues/1335/comments"},"review_comments":{"href":"https://api.github.com/repos/eslint/eslint/pulls/1335/comments"},"review_comment":{"href":"https://api.github.com/repos/eslint/eslint/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/eslint/eslint/pulls/1335/commits"},"statuses":{"href":"https://api.github.com/repos/eslint/eslint/statuses/7c4c069df380a8768e27d5807f9455e3e5d79f41"}},"merged":false,"mergeable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"commits":1,"additions":513,"deletions":345,"changed_files":11}}