{"action":"created","comment":{"url":"https://api.github.com/repos/deis/deisrel/pulls/comments/73425460","id":73425460,"diff_hunk":"@@ -15,14 +15,38 @@ import (\n func GenerateIndividualChangelog(client *github.Client, dest io.Writer) func(*cli.Context) error {\n \treturn func(c *cli.Context) error {\n \t\trepoName := c.Args().Get(0)\n-\t\tsha := c.Args().Get(2)\n+\t\tsha := c.String(\"sha\")\n \t\tvals := &changelog.Values{\n-\t\t\tOldRelease: c.Args().Get(1),\n-\t\t\tNewRelease: c.Args().Get(3),\n+\t\t\tOldRelease: c.String(\"base-tag\"),\n+\t\t\tNewRelease: c.Args().Get(1),\n \t\t}\n-\t\tif vals.OldRelease == \"\" || vals.NewRelease == \"\" || sha == \"\" || repoName == \"\" {\n-\t\t\tlog.Fatal(\"Usage: changelog individual <repo> <old-release> <sha> <new-release>\")\n+\t\tif vals.NewRelease == \"\" || repoName == \"\" {\n+\t\t\tlog.Fatal(\"Usage: changelog individual <repo> <new-release>\")\n \t\t}\n+\n+\t\t// If sha isn't set, use the latest commit on master\n+\t\tif sha == \"\" {\n+\t\t\tmaster, _, err := client.Repositories.GetBranch(\"deis\", repoName, \"master\")\n+\t\t\tif err != nil {\n+\t\t\t\treturn err\n+\t\t\t}\n+\t\t\tsha = *master.Commit.SHA\n+\t\t}\n+\n+\t\t// If sha isn't set, use the latest commit on master","path":"actions/generate_individual_changelog.go","position":27,"original_position":27,"commit_id":"bfb332c689e1463d9fb622483c4d875e090d7765","original_commit_id":"bfb332c689e1463d9fb622483c4d875e090d7765","user":{"login":"vdice","id":9322017,"avatar_url":"https://avatars.githubusercontent.com/u/9322017?v=3","gravatar_id":"","url":"https://api.github.com/users/vdice","html_url":"https://github.com/vdice","followers_url":"https://api.github.com/users/vdice/followers","following_url":"https://api.github.com/users/vdice/following{/other_user}","gists_url":"https://api.github.com/users/vdice/gists{/gist_id}","starred_url":"https://api.github.com/users/vdice/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vdice/subscriptions","organizations_url":"https://api.github.com/users/vdice/orgs","repos_url":"https://api.github.com/users/vdice/repos","events_url":"https://api.github.com/users/vdice/events{/privacy}","received_events_url":"https://api.github.com/users/vdice/received_events","type":"User","site_admin":false},"body":"comment should refer to `base-tag` not being set, etc.","created_at":"2016-08-03T21:32:28Z","updated_at":"2016-08-03T21:32:28Z","html_url":"https://github.com/deis/deisrel/pull/127#discussion_r73425460","pull_request_url":"https://api.github.com/repos/deis/deisrel/pulls/127","_links":{"self":{"href":"https://api.github.com/repos/deis/deisrel/pulls/comments/73425460"},"html":{"href":"https://github.com/deis/deisrel/pull/127#discussion_r73425460"},"pull_request":{"href":"https://api.github.com/repos/deis/deisrel/pulls/127"}}},"pull_request":{"url":"https://api.github.com/repos/deis/deisrel/pulls/127","id":79961611,"html_url":"https://github.com/deis/deisrel/pull/127","diff_url":"https://github.com/deis/deisrel/pull/127.diff","patch_url":"https://github.com/deis/deisrel/pull/127.patch","issue_url":"https://api.github.com/repos/deis/deisrel/issues/127","number":127,"state":"open","locked":false,"title":"feat(changelog): assume tag and sha options","user":{"login":"Joshua-Anderson","id":3526404,"avatar_url":"https://avatars.githubusercontent.com/u/3526404?v=3","gravatar_id":"","url":"https://api.github.com/users/Joshua-Anderson","html_url":"https://github.com/Joshua-Anderson","followers_url":"https://api.github.com/users/Joshua-Anderson/followers","following_url":"https://api.github.com/users/Joshua-Anderson/following{/other_user}","gists_url":"https://api.github.com/users/Joshua-Anderson/gists{/gist_id}","starred_url":"https://api.github.com/users/Joshua-Anderson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Joshua-Anderson/subscriptions","organizations_url":"https://api.github.com/users/Joshua-Anderson/orgs","repos_url":"https://api.github.com/users/Joshua-Anderson/repos","events_url":"https://api.github.com/users/Joshua-Anderson/events{/privacy}","received_events_url":"https://api.github.com/users/Joshua-Anderson/received_events","type":"User","site_admin":false},"body":"```\r\n./deisrel changelog individual workflow-cli v2.3.0\r\nskipping commit 70df6e0b756798e3e5eec0c7192739a02768194b\r\nskipping commit 2b35225474135a56e13b9052563eb64f45ec1258\r\nskipping commit 75c43e75d3550cf47989c48ede02c7ef3fc8765c\r\nskipping commit 44f50850118d77553a5ec63181ec888f3549a4e2\r\nskipping commit 76b60b584704d325c933726061182f8c12966c34\r\nskipping commit 072ef3062049108c1995da6ffd8cbfc5fc1d2346\r\nskipping commit ac06c69d01466abeea9d43aad1a3ee445572067b\r\nskipping commit 0a66819b2d1fe49aff419f44fe7e05b9fda638bf\r\n\r\nCreating changelog for workflow-cli with tag v2.2.0 through commit 0a66819b2d1fe49aff419f44fe7e05b9fda638bf\r\n\r\n### v2.2.0 -> v2.3.0\r\n\r\n#### Features\r\n- [`5615bb4`](https://github.com/deis/workflow-cli/commit/5615bb40c59ee68217631132b49c731efe8f6a6e) ci: send emails to slack on e2e failure (#133)\r\n- [`6e2954d`](https://github.com/deis/workflow-cli/commit/6e2954dd656aa385af75867262566091cb2bffce) shortcuts: add shortcuts test\r\n- [`f59bb66`](https://github.com/deis/workflow-cli/commit/f59bb66a1bf55a88bd198171bfdef776e5433d85) Jenkinsfile: no retry prompt if master\r\n- [`8168ea1`](https://github.com/deis/workflow-cli/commit/8168ea1e9b02f7c553d7d6578d90305dd47bd3fd) cmd: add auth:whoami --all\r\n- [`5e78fc4`](https://github.com/deis/workflow-cli/commit/5e78fc47c5f7d2b9fb9235a023288d8b42b2b863) Jenkinsfile: override 'sh' to add colorized output\r\n- [`fb6ed28`](https://github.com/deis/workflow-cli/commit/fb6ed281f2425a60fd9c04a2f3d31d06c328c944) Jenkinsfile: get actual PR commit, if PR\r\n- [`1199b9e`](https://github.com/deis/workflow-cli/commit/1199b9e0ad14453d1eea84dc55d7db58d0e74209) ci: add codecov (#146)\r\n- [`caf1fd0`](https://github.com/deis/workflow-cli/commit/caf1fd02f267f746be90742ba7ad653f495ad1d0) git: add more flags to the git command (#141)\r\n\r\n#### Fixes\r\n- [`89e4177`](https://github.com/deis/workflow-cli/commit/89e41771867c88808a89d405b51e9a626a55fcf1) tests: set owner of files created by containers to the local user (#151)\r\n- [`c655ea0`](https://github.com/deis/workflow-cli/commit/c655ea0ceba12a077c6110ff10b873c1c48a4a35) test-style: make fmt fail style-test and fix existing formatting errors (#135)\r\n- [`f94b05f`](https://github.com/deis/workflow-cli/commit/f94b05f23ffd3f76833f866894c5b62d4eaeed8e) CI: don't allow untrusted commands when uploading (#154)\r\n- [`9d52c27`](https://github.com/deis/workflow-cli/commit/9d52c27824a6ec0cb38c54de0209df6cfcb79c34) git: fix linting error (#159)\r\n- [`1f412af`](https://github.com/deis/workflow-cli/commit/1f412afd5351b799c7b48a1caa26de472a4179c5) CI: False doesn't abort build (#158)\r\n- [`8c843a6`](https://github.com/deis/workflow-cli/commit/8c843a61edfb897a1281d28826b134d5f1f5336a) CI: add false to retry loop (#162)\r\n\r\n#### Maintenance\r\n- [`cc4f07e`](https://github.com/deis/workflow-cli/commit/cc4f07e2b89caabfc8947f77a9f2c1a1d7716ba6) *: upgrade docker-go-dev and use new linter (#155)\r\n- [`87820c4`](https://github.com/deis/workflow-cli/commit/87820c4a0dd1866a8110daa3021e7f8cf766bcdc) glide: update controller-sdk-go\r\n```\r\ncc @helgi\r\n\r\n","created_at":"2016-08-03T19:10:33Z","updated_at":"2016-08-03T21:32:28Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3adddb9c6571f69f72cc4a622b54156f5814b280","assignee":{"login":"Joshua-Anderson","id":3526404,"avatar_url":"https://avatars.githubusercontent.com/u/3526404?v=3","gravatar_id":"","url":"https://api.github.com/users/Joshua-Anderson","html_url":"https://github.com/Joshua-Anderson","followers_url":"https://api.github.com/users/Joshua-Anderson/followers","following_url":"https://api.github.com/users/Joshua-Anderson/following{/other_user}","gists_url":"https://api.github.com/users/Joshua-Anderson/gists{/gist_id}","starred_url":"https://api.github.com/users/Joshua-Anderson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Joshua-Anderson/subscriptions","organizations_url":"https://api.github.com/users/Joshua-Anderson/orgs","repos_url":"https://api.github.com/users/Joshua-Anderson/repos","events_url":"https://api.github.com/users/Joshua-Anderson/events{/privacy}","received_events_url":"https://api.github.com/users/Joshua-Anderson/received_events","type":"User","site_admin":false},"assignees":[{"login":"Joshua-Anderson","id":3526404,"avatar_url":"https://avatars.githubusercontent.com/u/3526404?v=3","gravatar_id":"","url":"https://api.github.com/users/Joshua-Anderson","html_url":"https://github.com/Joshua-Anderson","followers_url":"https://api.github.com/users/Joshua-Anderson/followers","following_url":"https://api.github.com/users/Joshua-Anderson/following{/other_user}","gists_url":"https://api.github.com/users/Joshua-Anderson/gists{/gist_id}","starred_url":"https://api.github.com/users/Joshua-Anderson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Joshua-Anderson/subscriptions","organizations_url":"https://api.github.com/users/Joshua-Anderson/orgs","repos_url":"https://api.github.com/users/Joshua-Anderson/repos","events_url":"https://api.github.com/users/Joshua-Anderson/events{/privacy}","received_events_url":"https://api.github.com/users/Joshua-Anderson/received_events","type":"User","site_admin":false}],"milestone":null,"commits_url":"https://api.github.com/repos/deis/deisrel/pulls/127/commits","review_comments_url":"https://api.github.com/repos/deis/deisrel/pulls/127/comments","review_comment_url":"https://api.github.com/repos/deis/deisrel/pulls/comments{/number}","comments_url":"https://api.github.com/repos/deis/deisrel/issues/127/comments","statuses_url":"https://api.github.com/repos/deis/deisrel/statuses/bfb332c689e1463d9fb622483c4d875e090d7765","head":{"label":"Joshua-Anderson:better-changelogs","ref":"better-changelogs","sha":"bfb332c689e1463d9fb622483c4d875e090d7765","user":{"login":"Joshua-Anderson","id":3526404,"avatar_url":"https://avatars.githubusercontent.com/u/3526404?v=3","gravatar_id":"","url":"https://api.github.com/users/Joshua-Anderson","html_url":"https://github.com/Joshua-Anderson","followers_url":"https://api.github.com/users/Joshua-Anderson/followers","following_url":"https://api.github.com/users/Joshua-Anderson/following{/other_user}","gists_url":"https://api.github.com/users/Joshua-Anderson/gists{/gist_id}","starred_url":"https://api.github.com/users/Joshua-Anderson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Joshua-Anderson/subscriptions","organizations_url":"https://api.github.com/users/Joshua-Anderson/orgs","repos_url":"https://api.github.com/users/Joshua-Anderson/repos","events_url":"https://api.github.com/users/Joshua-Anderson/events{/privacy}","received_events_url":"https://api.github.com/users/Joshua-Anderson/received_events","type":"User","site_admin":false},"repo":{"id":63979178,"name":"deisrel","full_name":"Joshua-Anderson/deisrel","owner":{"login":"Joshua-Anderson","id":3526404,"avatar_url":"https://avatars.githubusercontent.com/u/3526404?v=3","gravatar_id":"","url":"https://api.github.com/users/Joshua-Anderson","html_url":"https://github.com/Joshua-Anderson","followers_url":"https://api.github.com/users/Joshua-Anderson/followers","following_url":"https://api.github.com/users/Joshua-Anderson/following{/other_user}","gists_url":"https://api.github.com/users/Joshua-Anderson/gists{/gist_id}","starred_url":"https://api.github.com/users/Joshua-Anderson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Joshua-Anderson/subscriptions","organizations_url":"https://api.github.com/users/Joshua-Anderson/orgs","repos_url":"https://api.github.com/users/Joshua-Anderson/repos","events_url":"https://api.github.com/users/Joshua-Anderson/events{/privacy}","received_events_url":"https://api.github.com/users/Joshua-Anderson/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Joshua-Anderson/deisrel","description":"A releaser tool for Deis","fork":true,"url":"https://api.github.com/repos/Joshua-Anderson/deisrel","forks_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/forks","keys_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/teams","hooks_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/hooks","issue_events_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/issues/events{/number}","events_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/events","assignees_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/assignees{/user}","branches_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/branches{/branch}","tags_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/tags","blobs_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/git/refs{/sha}","trees_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/statuses/{sha}","languages_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/languages","stargazers_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/stargazers","contributors_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/contributors","subscribers_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/subscribers","subscription_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/subscription","commits_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/commits{/sha}","git_commits_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/git/commits{/sha}","comments_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/comments{/number}","issue_comment_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/issues/comments{/number}","contents_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/contents/{+path}","compare_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/merges","archive_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/downloads","issues_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/issues{/number}","pulls_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/pulls{/number}","milestones_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/milestones{/number}","notifications_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/labels{/name}","releases_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/releases{/id}","deployments_url":"https://api.github.com/repos/Joshua-Anderson/deisrel/deployments","created_at":"2016-07-22T19:47:03Z","updated_at":"2016-07-22T19:47:04Z","pushed_at":"2016-08-03T19:08:46Z","git_url":"git://github.com/Joshua-Anderson/deisrel.git","ssh_url":"git@github.com:Joshua-Anderson/deisrel.git","clone_url":"https://github.com/Joshua-Anderson/deisrel.git","svn_url":"https://github.com/Joshua-Anderson/deisrel","homepage":null,"size":141,"stargazers_count":0,"watchers_count":0,"language":"Go","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":"deis:master","ref":"master","sha":"c307ef928ccfda13e2ab63d586651e8cafae587a","user":{"login":"deis","id":6117407,"avatar_url":"https://avatars.githubusercontent.com/u/6117407?v=3","gravatar_id":"","url":"https://api.github.com/users/deis","html_url":"https://github.com/deis","followers_url":"https://api.github.com/users/deis/followers","following_url":"https://api.github.com/users/deis/following{/other_user}","gists_url":"https://api.github.com/users/deis/gists{/gist_id}","starred_url":"https://api.github.com/users/deis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/deis/subscriptions","organizations_url":"https://api.github.com/users/deis/orgs","repos_url":"https://api.github.com/users/deis/repos","events_url":"https://api.github.com/users/deis/events{/privacy}","received_events_url":"https://api.github.com/users/deis/received_events","type":"Organization","site_admin":false},"repo":{"id":57398434,"name":"deisrel","full_name":"deis/deisrel","owner":{"login":"deis","id":6117407,"avatar_url":"https://avatars.githubusercontent.com/u/6117407?v=3","gravatar_id":"","url":"https://api.github.com/users/deis","html_url":"https://github.com/deis","followers_url":"https://api.github.com/users/deis/followers","following_url":"https://api.github.com/users/deis/following{/other_user}","gists_url":"https://api.github.com/users/deis/gists{/gist_id}","starred_url":"https://api.github.com/users/deis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/deis/subscriptions","organizations_url":"https://api.github.com/users/deis/orgs","repos_url":"https://api.github.com/users/deis/repos","events_url":"https://api.github.com/users/deis/events{/privacy}","received_events_url":"https://api.github.com/users/deis/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/deis/deisrel","description":"A releaser tool for Deis","fork":true,"url":"https://api.github.com/repos/deis/deisrel","forks_url":"https://api.github.com/repos/deis/deisrel/forks","keys_url":"https://api.github.com/repos/deis/deisrel/keys{/key_id}","collaborators_url":"https://api.github.com/repos/deis/deisrel/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/deis/deisrel/teams","hooks_url":"https://api.github.com/repos/deis/deisrel/hooks","issue_events_url":"https://api.github.com/repos/deis/deisrel/issues/events{/number}","events_url":"https://api.github.com/repos/deis/deisrel/events","assignees_url":"https://api.github.com/repos/deis/deisrel/assignees{/user}","branches_url":"https://api.github.com/repos/deis/deisrel/branches{/branch}","tags_url":"https://api.github.com/repos/deis/deisrel/tags","blobs_url":"https://api.github.com/repos/deis/deisrel/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/deis/deisrel/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/deis/deisrel/git/refs{/sha}","trees_url":"https://api.github.com/repos/deis/deisrel/git/trees{/sha}","statuses_url":"https://api.github.com/repos/deis/deisrel/statuses/{sha}","languages_url":"https://api.github.com/repos/deis/deisrel/languages","stargazers_url":"https://api.github.com/repos/deis/deisrel/stargazers","contributors_url":"https://api.github.com/repos/deis/deisrel/contributors","subscribers_url":"https://api.github.com/repos/deis/deisrel/subscribers","subscription_url":"https://api.github.com/repos/deis/deisrel/subscription","commits_url":"https://api.github.com/repos/deis/deisrel/commits{/sha}","git_commits_url":"https://api.github.com/repos/deis/deisrel/git/commits{/sha}","comments_url":"https://api.github.com/repos/deis/deisrel/comments{/number}","issue_comment_url":"https://api.github.com/repos/deis/deisrel/issues/comments{/number}","contents_url":"https://api.github.com/repos/deis/deisrel/contents/{+path}","compare_url":"https://api.github.com/repos/deis/deisrel/compare/{base}...{head}","merges_url":"https://api.github.com/repos/deis/deisrel/merges","archive_url":"https://api.github.com/repos/deis/deisrel/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/deis/deisrel/downloads","issues_url":"https://api.github.com/repos/deis/deisrel/issues{/number}","pulls_url":"https://api.github.com/repos/deis/deisrel/pulls{/number}","milestones_url":"https://api.github.com/repos/deis/deisrel/milestones{/number}","notifications_url":"https://api.github.com/repos/deis/deisrel/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/deis/deisrel/labels{/name}","releases_url":"https://api.github.com/repos/deis/deisrel/releases{/id}","deployments_url":"https://api.github.com/repos/deis/deisrel/deployments","created_at":"2016-04-29T16:29:22Z","updated_at":"2016-05-21T22:00:39Z","pushed_at":"2016-08-03T19:10:34Z","git_url":"git://github.com/deis/deisrel.git","ssh_url":"git@github.com:deis/deisrel.git","clone_url":"https://github.com/deis/deisrel.git","svn_url":"https://github.com/deis/deisrel","homepage":null,"size":186,"stargazers_count":3,"watchers_count":3,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":9,"mirror_url":null,"open_issues_count":28,"forks":9,"open_issues":28,"watchers":3,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/deis/deisrel/pulls/127"},"html":{"href":"https://github.com/deis/deisrel/pull/127"},"issue":{"href":"https://api.github.com/repos/deis/deisrel/issues/127"},"comments":{"href":"https://api.github.com/repos/deis/deisrel/issues/127/comments"},"review_comments":{"href":"https://api.github.com/repos/deis/deisrel/pulls/127/comments"},"review_comment":{"href":"https://api.github.com/repos/deis/deisrel/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/deis/deisrel/pulls/127/commits"},"statuses":{"href":"https://api.github.com/repos/deis/deisrel/statuses/bfb332c689e1463d9fb622483c4d875e090d7765"}}}}
{"actor":{"display_login":"vdice"}}