{"action":"created","comment":{"url":"https://api.github.com/repos/google/startup-os/pulls/comments/243792829","pull_request_review_id":187652942,"id":243792829,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDI0Mzc5MjgyOQ==","diff_hunk":"@@ -0,0 +1,16 @@\n+#!/usr/bin/env bash\n+\n+# Wrapper script for running shfmt\n+\n+platform=$(uname)\n+\n+if [[ \"$platform\" == \"Darwin\" ]]; then\n+  BINARY=$(find . -iwholename \"*shfmt_osx/file/downloaded\" | head -n1)\n+elif [[ \"$platform\" == \"Linux\" ]]; then\n+  BINARY=$(find . -iwholename \"*shfmt/file/downloaded\" | head -n1)\n+else\n+  echo \"shfmt does not have a binary for $platform\"\n+  exit 1\n+fi\n+\n+${BINARY} -i 2 -ci -w $*","path":"tools/bazel_tools/shfmt.sh","position":16,"original_position":16,"commit_id":"9d660ff9892534edaf27fe7ee127c0fee5b69aef","original_commit_id":"c3a1840ab60d59bae65fb12d1978f4c8d892b306","user":{"login":"vmax","id":499267,"node_id":"MDQ6VXNlcjQ5OTI2Nw==","avatar_url":"https://avatars1.githubusercontent.com/u/499267?v=4","gravatar_id":"","url":"https://api.github.com/users/vmax","html_url":"https://github.com/vmax","followers_url":"https://api.github.com/users/vmax/followers","following_url":"https://api.github.com/users/vmax/following{/other_user}","gists_url":"https://api.github.com/users/vmax/gists{/gist_id}","starred_url":"https://api.github.com/users/vmax/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vmax/subscriptions","organizations_url":"https://api.github.com/users/vmax/orgs","repos_url":"https://api.github.com/users/vmax/repos","events_url":"https://api.github.com/users/vmax/events{/privacy}","received_events_url":"https://api.github.com/users/vmax/received_events","type":"User","site_admin":false},"body":"@oferb\r\n`shfmt` says it follows Google's style [here](https://github.com/mvdan/sh/blame/master/README.md#L43)\r\nFlags mean \"2 spaces for indentation\" and \"indent branches in `switch` statement\"\r\nI'll leave a comment in code as well","created_at":"2018-12-24T07:05:07Z","updated_at":"2018-12-24T07:05:07Z","html_url":"https://github.com/google/startup-os/pull/478#discussion_r243792829","pull_request_url":"https://api.github.com/repos/google/startup-os/pulls/478","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/google/startup-os/pulls/comments/243792829"},"html":{"href":"https://github.com/google/startup-os/pull/478#discussion_r243792829"},"pull_request":{"href":"https://api.github.com/repos/google/startup-os/pulls/478"}},"in_reply_to_id":243791834},"pull_request":{"url":"https://api.github.com/repos/google/startup-os/pulls/478","id":240723863,"node_id":"MDExOlB1bGxSZXF1ZXN0MjQwNzIzODYz","html_url":"https://github.com/google/startup-os/pull/478","diff_url":"https://github.com/google/startup-os/pull/478.diff","patch_url":"https://github.com/google/startup-os/pull/478.patch","issue_url":"https://api.github.com/repos/google/startup-os/issues/478","number":478,"state":"open","locked":false,"title":"Integrate shfmt into FormatterTool","user":{"login":"vmax","id":499267,"node_id":"MDQ6VXNlcjQ5OTI2Nw==","avatar_url":"https://avatars1.githubusercontent.com/u/499267?v=4","gravatar_id":"","url":"https://api.github.com/users/vmax","html_url":"https://github.com/vmax","followers_url":"https://api.github.com/users/vmax/followers","following_url":"https://api.github.com/users/vmax/following{/other_user}","gists_url":"https://api.github.com/users/vmax/gists{/gist_id}","starred_url":"https://api.github.com/users/vmax/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vmax/subscriptions","organizations_url":"https://api.github.com/users/vmax/orgs","repos_url":"https://api.github.com/users/vmax/repos","events_url":"https://api.github.com/users/vmax/events{/privacy}","received_events_url":"https://api.github.com/users/vmax/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-12-24T05:51:58Z","updated_at":"2018-12-24T07:05:07Z","closed_at":null,"merged_at":null,"merge_commit_sha":"2830d1285b7e050f84f01b7da590c30713043529","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/google/startup-os/pulls/478/commits","review_comments_url":"https://api.github.com/repos/google/startup-os/pulls/478/comments","review_comment_url":"https://api.github.com/repos/google/startup-os/pulls/comments{/number}","comments_url":"https://api.github.com/repos/google/startup-os/issues/478/comments","statuses_url":"https://api.github.com/repos/google/startup-os/statuses/9d660ff9892534edaf27fe7ee127c0fee5b69aef","head":{"label":"google:integrate-shfmt","ref":"integrate-shfmt","sha":"9d660ff9892534edaf27fe7ee127c0fee5b69aef","user":{"login":"google","id":1342004,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEzNDIwMDQ=","avatar_url":"https://avatars1.githubusercontent.com/u/1342004?v=4","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"repo":{"id":122602787,"node_id":"MDEwOlJlcG9zaXRvcnkxMjI2MDI3ODc=","name":"startup-os","full_name":"google/startup-os","private":false,"owner":{"login":"google","id":1342004,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEzNDIwMDQ=","avatar_url":"https://avatars1.githubusercontent.com/u/1342004?v=4","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/google/startup-os","description":"Working examples of Google's Open Source stack and deployment to the cloud.","fork":false,"url":"https://api.github.com/repos/google/startup-os","forks_url":"https://api.github.com/repos/google/startup-os/forks","keys_url":"https://api.github.com/repos/google/startup-os/keys{/key_id}","collaborators_url":"https://api.github.com/repos/google/startup-os/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/google/startup-os/teams","hooks_url":"https://api.github.com/repos/google/startup-os/hooks","issue_events_url":"https://api.github.com/repos/google/startup-os/issues/events{/number}","events_url":"https://api.github.com/repos/google/startup-os/events","assignees_url":"https://api.github.com/repos/google/startup-os/assignees{/user}","branches_url":"https://api.github.com/repos/google/startup-os/branches{/branch}","tags_url":"https://api.github.com/repos/google/startup-os/tags","blobs_url":"https://api.github.com/repos/google/startup-os/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/google/startup-os/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/google/startup-os/git/refs{/sha}","trees_url":"https://api.github.com/repos/google/startup-os/git/trees{/sha}","statuses_url":"https://api.github.com/repos/google/startup-os/statuses/{sha}","languages_url":"https://api.github.com/repos/google/startup-os/languages","stargazers_url":"https://api.github.com/repos/google/startup-os/stargazers","contributors_url":"https://api.github.com/repos/google/startup-os/contributors","subscribers_url":"https://api.github.com/repos/google/startup-os/subscribers","subscription_url":"https://api.github.com/repos/google/startup-os/subscription","commits_url":"https://api.github.com/repos/google/startup-os/commits{/sha}","git_commits_url":"https://api.github.com/repos/google/startup-os/git/commits{/sha}","comments_url":"https://api.github.com/repos/google/startup-os/comments{/number}","issue_comment_url":"https://api.github.com/repos/google/startup-os/issues/comments{/number}","contents_url":"https://api.github.com/repos/google/startup-os/contents/{+path}","compare_url":"https://api.github.com/repos/google/startup-os/compare/{base}...{head}","merges_url":"https://api.github.com/repos/google/startup-os/merges","archive_url":"https://api.github.com/repos/google/startup-os/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/google/startup-os/downloads","issues_url":"https://api.github.com/repos/google/startup-os/issues{/number}","pulls_url":"https://api.github.com/repos/google/startup-os/pulls{/number}","milestones_url":"https://api.github.com/repos/google/startup-os/milestones{/number}","notifications_url":"https://api.github.com/repos/google/startup-os/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/google/startup-os/labels{/name}","releases_url":"https://api.github.com/repos/google/startup-os/releases{/id}","deployments_url":"https://api.github.com/repos/google/startup-os/deployments","created_at":"2018-02-23T09:48:29Z","updated_at":"2018-12-24T06:50:10Z","pushed_at":"2018-12-24T07:02:05Z","git_url":"git://github.com/google/startup-os.git","ssh_url":"git@github.com:google/startup-os.git","clone_url":"https://github.com/google/startup-os.git","svn_url":"https://github.com/google/startup-os","homepage":"","size":2515,"stargazers_count":233,"watchers_count":233,"language":"Java","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":51,"mirror_url":null,"archived":false,"open_issues_count":45,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":51,"open_issues":45,"watchers":233,"default_branch":"master"}},"base":{"label":"google:master","ref":"master","sha":"3a03ec180b81ee986c5d1504049b4ed41ef12a38","user":{"login":"google","id":1342004,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEzNDIwMDQ=","avatar_url":"https://avatars1.githubusercontent.com/u/1342004?v=4","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"repo":{"id":122602787,"node_id":"MDEwOlJlcG9zaXRvcnkxMjI2MDI3ODc=","name":"startup-os","full_name":"google/startup-os","private":false,"owner":{"login":"google","id":1342004,"node_id":"MDEyOk9yZ2FuaXphdGlvbjEzNDIwMDQ=","avatar_url":"https://avatars1.githubusercontent.com/u/1342004?v=4","gravatar_id":"","url":"https://api.github.com/users/google","html_url":"https://github.com/google","followers_url":"https://api.github.com/users/google/followers","following_url":"https://api.github.com/users/google/following{/other_user}","gists_url":"https://api.github.com/users/google/gists{/gist_id}","starred_url":"https://api.github.com/users/google/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/google/subscriptions","organizations_url":"https://api.github.com/users/google/orgs","repos_url":"https://api.github.com/users/google/repos","events_url":"https://api.github.com/users/google/events{/privacy}","received_events_url":"https://api.github.com/users/google/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/google/startup-os","description":"Working examples of Google's Open Source stack and deployment to the cloud.","fork":false,"url":"https://api.github.com/repos/google/startup-os","forks_url":"https://api.github.com/repos/google/startup-os/forks","keys_url":"https://api.github.com/repos/google/startup-os/keys{/key_id}","collaborators_url":"https://api.github.com/repos/google/startup-os/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/google/startup-os/teams","hooks_url":"https://api.github.com/repos/google/startup-os/hooks","issue_events_url":"https://api.github.com/repos/google/startup-os/issues/events{/number}","events_url":"https://api.github.com/repos/google/startup-os/events","assignees_url":"https://api.github.com/repos/google/startup-os/assignees{/user}","branches_url":"https://api.github.com/repos/google/startup-os/branches{/branch}","tags_url":"https://api.github.com/repos/google/startup-os/tags","blobs_url":"https://api.github.com/repos/google/startup-os/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/google/startup-os/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/google/startup-os/git/refs{/sha}","trees_url":"https://api.github.com/repos/google/startup-os/git/trees{/sha}","statuses_url":"https://api.github.com/repos/google/startup-os/statuses/{sha}","languages_url":"https://api.github.com/repos/google/startup-os/languages","stargazers_url":"https://api.github.com/repos/google/startup-os/stargazers","contributors_url":"https://api.github.com/repos/google/startup-os/contributors","subscribers_url":"https://api.github.com/repos/google/startup-os/subscribers","subscription_url":"https://api.github.com/repos/google/startup-os/subscription","commits_url":"https://api.github.com/repos/google/startup-os/commits{/sha}","git_commits_url":"https://api.github.com/repos/google/startup-os/git/commits{/sha}","comments_url":"https://api.github.com/repos/google/startup-os/comments{/number}","issue_comment_url":"https://api.github.com/repos/google/startup-os/issues/comments{/number}","contents_url":"https://api.github.com/repos/google/startup-os/contents/{+path}","compare_url":"https://api.github.com/repos/google/startup-os/compare/{base}...{head}","merges_url":"https://api.github.com/repos/google/startup-os/merges","archive_url":"https://api.github.com/repos/google/startup-os/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/google/startup-os/downloads","issues_url":"https://api.github.com/repos/google/startup-os/issues{/number}","pulls_url":"https://api.github.com/repos/google/startup-os/pulls{/number}","milestones_url":"https://api.github.com/repos/google/startup-os/milestones{/number}","notifications_url":"https://api.github.com/repos/google/startup-os/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/google/startup-os/labels{/name}","releases_url":"https://api.github.com/repos/google/startup-os/releases{/id}","deployments_url":"https://api.github.com/repos/google/startup-os/deployments","created_at":"2018-02-23T09:48:29Z","updated_at":"2018-12-24T06:50:10Z","pushed_at":"2018-12-24T07:02:05Z","git_url":"git://github.com/google/startup-os.git","ssh_url":"git@github.com:google/startup-os.git","clone_url":"https://github.com/google/startup-os.git","svn_url":"https://github.com/google/startup-os","homepage":"","size":2515,"stargazers_count":233,"watchers_count":233,"language":"Java","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":51,"mirror_url":null,"archived":false,"open_issues_count":45,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":51,"open_issues":45,"watchers":233,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/google/startup-os/pulls/478"},"html":{"href":"https://github.com/google/startup-os/pull/478"},"issue":{"href":"https://api.github.com/repos/google/startup-os/issues/478"},"comments":{"href":"https://api.github.com/repos/google/startup-os/issues/478/comments"},"review_comments":{"href":"https://api.github.com/repos/google/startup-os/pulls/478/comments"},"review_comment":{"href":"https://api.github.com/repos/google/startup-os/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/google/startup-os/pulls/478/commits"},"statuses":{"href":"https://api.github.com/repos/google/startup-os/statuses/9d660ff9892534edaf27fe7ee127c0fee5b69aef"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"vmax"}}