{"action":"created","comment":{"url":"https://api.github.com/repos/keybase/client/pulls/comments/46609270","id":46609270,"diff_hunk":"@@ -0,0 +1,91 @@\n+// Copyright 2015 Keybase, Inc. All rights reserved. Use of\n+// this source code is governed by the included BSD license.\n+\n+package main\n+\n+import (\n+\t\"flag\"\n+\t\"fmt\"\n+\t\"log\"\n+\t\"os\"\n+\t\"runtime\"\n+\n+\t\"github.com/keybase/client/go/libkb\"\n+\tgh \"github.com/keybase/client/go/tools/release/github\"\n+)\n+\n+func githubToken() string {\n+\ttoken := os.Getenv(\"GITHUB_TOKEN\")\n+\tif token == \"\" {\n+\t\tlog.Fatal(\"No GITHUB_TOKEN set\")\n+\t}\n+\treturn token\n+}\n+\n+func tag(version string) string {\n+\treturn fmt.Sprintf(\"v%s\", version)\n+}\n+\n+var repo = flag.String(\"repo\", \"client\", \"Repository in keybase\")\n+var version = flag.String(\"version\", libkb.VersionString(), \"Version for tag\")\n+var src = flag.String(\"file\", \"\", \"Path to source file\")\n+var dest = flag.String(\"dest\", \"\", \"Path to destination file\")\n+\n+func main() {\n+\tflag.Parse()\n+\n+\tif len(flag.Args()) < 1 {\n+\t\tlog.Fatal(\"Specify action\")\n+\t}\n+\taction := flag.Arg(0)\n+\n+\tswitch action {\n+\tcase \"version\":\n+\t\tfmt.Printf(\"%s\", libkb.VersionString())\n+\tcase \"increment-build\":\n+\t\tvar file = flag.String(\"file\", \"\", \"Path to version file\")\n+\t\terr := libkb.WriteVersion(libkb.Version, libkb.Build+1, *file)","path":"go/tools/release/release.go","position":47,"original_position":47,"commit_id":"3f3e169555645c94e28473e836545f3d1b7726e4","original_commit_id":"3f3e169555645c94e28473e836545f3d1b7726e4","user":{"login":"oconnor663","id":860932,"avatar_url":"https://avatars.githubusercontent.com/u/860932?v=3","gravatar_id":"","url":"https://api.github.com/users/oconnor663","html_url":"https://github.com/oconnor663","followers_url":"https://api.github.com/users/oconnor663/followers","following_url":"https://api.github.com/users/oconnor663/following{/other_user}","gists_url":"https://api.github.com/users/oconnor663/gists{/gist_id}","starred_url":"https://api.github.com/users/oconnor663/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/oconnor663/subscriptions","organizations_url":"https://api.github.com/users/oconnor663/orgs","repos_url":"https://api.github.com/users/oconnor663/repos","events_url":"https://api.github.com/users/oconnor663/events{/privacy}","received_events_url":"https://api.github.com/users/oconnor663/received_events","type":"User","site_admin":false},"body":"Should this respect the `version` flag from above? Is that the way to increment fields other than the build number?","created_at":"2015-12-03T20:46:01Z","updated_at":"2015-12-03T20:46:01Z","html_url":"https://github.com/keybase/client/pull/1460#discussion_r46609270","pull_request_url":"https://api.github.com/repos/keybase/client/pulls/1460","_links":{"self":{"href":"https://api.github.com/repos/keybase/client/pulls/comments/46609270"},"html":{"href":"https://github.com/keybase/client/pull/1460#discussion_r46609270"},"pull_request":{"href":"https://api.github.com/repos/keybase/client/pulls/1460"}}},"pull_request":{"url":"https://api.github.com/repos/keybase/client/pulls/1460","id":52480555,"html_url":"https://github.com/keybase/client/pull/1460","diff_url":"https://github.com/keybase/client/pull/1460.diff","patch_url":"https://github.com/keybase/client/pull/1460.patch","issue_url":"https://api.github.com/repos/keybase/client/issues/1460","number":1460,"state":"open","locked":false,"title":"Release tool to create releases on github; Automated release; Increment build script","user":{"login":"gabriel","id":2669,"avatar_url":"https://avatars.githubusercontent.com/u/2669?v=3","gravatar_id":"","url":"https://api.github.com/users/gabriel","html_url":"https://github.com/gabriel","followers_url":"https://api.github.com/users/gabriel/followers","following_url":"https://api.github.com/users/gabriel/following{/other_user}","gists_url":"https://api.github.com/users/gabriel/gists{/gist_id}","starred_url":"https://api.github.com/users/gabriel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gabriel/subscriptions","organizations_url":"https://api.github.com/users/gabriel/orgs","repos_url":"https://api.github.com/users/gabriel/repos","events_url":"https://api.github.com/users/gabriel/events{/privacy}","received_events_url":"https://api.github.com/users/gabriel/received_events","type":"User","site_admin":false},"body":"The `packaging/increment_build.sh` will automatically increment build number, commit and tag.\r\n\r\nThe `packaging/keybase.sh` will build, create a release and upload tgz automatically (or do nothing if release already exists).\r\n\r\nI want to add `packaging/keybase.sh` to travis so a release gets built automatically whenever version changes.\r\n\r\nThen we can make the `packaging/increment_build.sh` happen every night, and then we have nightlies.\r\n","created_at":"2015-12-03T01:31:51Z","updated_at":"2015-12-03T20:46:01Z","closed_at":null,"merged_at":null,"merge_commit_sha":"aa6a60525c25bab3222bf4525e8bfa1701119d60","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/keybase/client/pulls/1460/commits","review_comments_url":"https://api.github.com/repos/keybase/client/pulls/1460/comments","review_comment_url":"https://api.github.com/repos/keybase/client/pulls/comments{/number}","comments_url":"https://api.github.com/repos/keybase/client/issues/1460/comments","statuses_url":"https://api.github.com/repos/keybase/client/statuses/3f3e169555645c94e28473e836545f3d1b7726e4","head":{"label":"keybase:generateversion2","ref":"generateversion2","sha":"3f3e169555645c94e28473e836545f3d1b7726e4","user":{"login":"keybase","id":5400834,"avatar_url":"https://avatars.githubusercontent.com/u/5400834?v=3","gravatar_id":"","url":"https://api.github.com/users/keybase","html_url":"https://github.com/keybase","followers_url":"https://api.github.com/users/keybase/followers","following_url":"https://api.github.com/users/keybase/following{/other_user}","gists_url":"https://api.github.com/users/keybase/gists{/gist_id}","starred_url":"https://api.github.com/users/keybase/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/keybase/subscriptions","organizations_url":"https://api.github.com/users/keybase/orgs","repos_url":"https://api.github.com/users/keybase/repos","events_url":"https://api.github.com/users/keybase/events{/privacy}","received_events_url":"https://api.github.com/users/keybase/received_events","type":"Organization","site_admin":false},"repo":{"id":29099181,"name":"client","full_name":"keybase/client","owner":{"login":"keybase","id":5400834,"avatar_url":"https://avatars.githubusercontent.com/u/5400834?v=3","gravatar_id":"","url":"https://api.github.com/users/keybase","html_url":"https://github.com/keybase","followers_url":"https://api.github.com/users/keybase/followers","following_url":"https://api.github.com/users/keybase/following{/other_user}","gists_url":"https://api.github.com/users/keybase/gists{/gist_id}","starred_url":"https://api.github.com/users/keybase/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/keybase/subscriptions","organizations_url":"https://api.github.com/users/keybase/orgs","repos_url":"https://api.github.com/users/keybase/repos","events_url":"https://api.github.com/users/keybase/events{/privacy}","received_events_url":"https://api.github.com/users/keybase/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/keybase/client","description":"Keybase Go Library, Client, Service, OS X, iOS, Android, Electron","fork":false,"url":"https://api.github.com/repos/keybase/client","forks_url":"https://api.github.com/repos/keybase/client/forks","keys_url":"https://api.github.com/repos/keybase/client/keys{/key_id}","collaborators_url":"https://api.github.com/repos/keybase/client/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/keybase/client/teams","hooks_url":"https://api.github.com/repos/keybase/client/hooks","issue_events_url":"https://api.github.com/repos/keybase/client/issues/events{/number}","events_url":"https://api.github.com/repos/keybase/client/events","assignees_url":"https://api.github.com/repos/keybase/client/assignees{/user}","branches_url":"https://api.github.com/repos/keybase/client/branches{/branch}","tags_url":"https://api.github.com/repos/keybase/client/tags","blobs_url":"https://api.github.com/repos/keybase/client/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/keybase/client/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/keybase/client/git/refs{/sha}","trees_url":"https://api.github.com/repos/keybase/client/git/trees{/sha}","statuses_url":"https://api.github.com/repos/keybase/client/statuses/{sha}","languages_url":"https://api.github.com/repos/keybase/client/languages","stargazers_url":"https://api.github.com/repos/keybase/client/stargazers","contributors_url":"https://api.github.com/repos/keybase/client/contributors","subscribers_url":"https://api.github.com/repos/keybase/client/subscribers","subscription_url":"https://api.github.com/repos/keybase/client/subscription","commits_url":"https://api.github.com/repos/keybase/client/commits{/sha}","git_commits_url":"https://api.github.com/repos/keybase/client/git/commits{/sha}","comments_url":"https://api.github.com/repos/keybase/client/comments{/number}","issue_comment_url":"https://api.github.com/repos/keybase/client/issues/comments{/number}","contents_url":"https://api.github.com/repos/keybase/client/contents/{+path}","compare_url":"https://api.github.com/repos/keybase/client/compare/{base}...{head}","merges_url":"https://api.github.com/repos/keybase/client/merges","archive_url":"https://api.github.com/repos/keybase/client/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/keybase/client/downloads","issues_url":"https://api.github.com/repos/keybase/client/issues{/number}","pulls_url":"https://api.github.com/repos/keybase/client/pulls{/number}","milestones_url":"https://api.github.com/repos/keybase/client/milestones{/number}","notifications_url":"https://api.github.com/repos/keybase/client/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/keybase/client/labels{/name}","releases_url":"https://api.github.com/repos/keybase/client/releases{/id}","created_at":"2015-01-11T17:17:12Z","updated_at":"2015-12-03T04:46:00Z","pushed_at":"2015-12-03T20:31:46Z","git_url":"git://github.com/keybase/client.git","ssh_url":"git@github.com:keybase/client.git","clone_url":"https://github.com/keybase/client.git","svn_url":"https://github.com/keybase/client","homepage":"","size":117375,"stargazers_count":30,"watchers_count":30,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":3,"mirror_url":null,"open_issues_count":17,"forks":3,"open_issues":17,"watchers":30,"default_branch":"master"}},"base":{"label":"keybase:master","ref":"master","sha":"2c9aa2ae5e107595750bea1118e05443d3ad7d16","user":{"login":"keybase","id":5400834,"avatar_url":"https://avatars.githubusercontent.com/u/5400834?v=3","gravatar_id":"","url":"https://api.github.com/users/keybase","html_url":"https://github.com/keybase","followers_url":"https://api.github.com/users/keybase/followers","following_url":"https://api.github.com/users/keybase/following{/other_user}","gists_url":"https://api.github.com/users/keybase/gists{/gist_id}","starred_url":"https://api.github.com/users/keybase/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/keybase/subscriptions","organizations_url":"https://api.github.com/users/keybase/orgs","repos_url":"https://api.github.com/users/keybase/repos","events_url":"https://api.github.com/users/keybase/events{/privacy}","received_events_url":"https://api.github.com/users/keybase/received_events","type":"Organization","site_admin":false},"repo":{"id":29099181,"name":"client","full_name":"keybase/client","owner":{"login":"keybase","id":5400834,"avatar_url":"https://avatars.githubusercontent.com/u/5400834?v=3","gravatar_id":"","url":"https://api.github.com/users/keybase","html_url":"https://github.com/keybase","followers_url":"https://api.github.com/users/keybase/followers","following_url":"https://api.github.com/users/keybase/following{/other_user}","gists_url":"https://api.github.com/users/keybase/gists{/gist_id}","starred_url":"https://api.github.com/users/keybase/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/keybase/subscriptions","organizations_url":"https://api.github.com/users/keybase/orgs","repos_url":"https://api.github.com/users/keybase/repos","events_url":"https://api.github.com/users/keybase/events{/privacy}","received_events_url":"https://api.github.com/users/keybase/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/keybase/client","description":"Keybase Go Library, Client, Service, OS X, iOS, Android, Electron","fork":false,"url":"https://api.github.com/repos/keybase/client","forks_url":"https://api.github.com/repos/keybase/client/forks","keys_url":"https://api.github.com/repos/keybase/client/keys{/key_id}","collaborators_url":"https://api.github.com/repos/keybase/client/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/keybase/client/teams","hooks_url":"https://api.github.com/repos/keybase/client/hooks","issue_events_url":"https://api.github.com/repos/keybase/client/issues/events{/number}","events_url":"https://api.github.com/repos/keybase/client/events","assignees_url":"https://api.github.com/repos/keybase/client/assignees{/user}","branches_url":"https://api.github.com/repos/keybase/client/branches{/branch}","tags_url":"https://api.github.com/repos/keybase/client/tags","blobs_url":"https://api.github.com/repos/keybase/client/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/keybase/client/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/keybase/client/git/refs{/sha}","trees_url":"https://api.github.com/repos/keybase/client/git/trees{/sha}","statuses_url":"https://api.github.com/repos/keybase/client/statuses/{sha}","languages_url":"https://api.github.com/repos/keybase/client/languages","stargazers_url":"https://api.github.com/repos/keybase/client/stargazers","contributors_url":"https://api.github.com/repos/keybase/client/contributors","subscribers_url":"https://api.github.com/repos/keybase/client/subscribers","subscription_url":"https://api.github.com/repos/keybase/client/subscription","commits_url":"https://api.github.com/repos/keybase/client/commits{/sha}","git_commits_url":"https://api.github.com/repos/keybase/client/git/commits{/sha}","comments_url":"https://api.github.com/repos/keybase/client/comments{/number}","issue_comment_url":"https://api.github.com/repos/keybase/client/issues/comments{/number}","contents_url":"https://api.github.com/repos/keybase/client/contents/{+path}","compare_url":"https://api.github.com/repos/keybase/client/compare/{base}...{head}","merges_url":"https://api.github.com/repos/keybase/client/merges","archive_url":"https://api.github.com/repos/keybase/client/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/keybase/client/downloads","issues_url":"https://api.github.com/repos/keybase/client/issues{/number}","pulls_url":"https://api.github.com/repos/keybase/client/pulls{/number}","milestones_url":"https://api.github.com/repos/keybase/client/milestones{/number}","notifications_url":"https://api.github.com/repos/keybase/client/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/keybase/client/labels{/name}","releases_url":"https://api.github.com/repos/keybase/client/releases{/id}","created_at":"2015-01-11T17:17:12Z","updated_at":"2015-12-03T04:46:00Z","pushed_at":"2015-12-03T20:31:46Z","git_url":"git://github.com/keybase/client.git","ssh_url":"git@github.com:keybase/client.git","clone_url":"https://github.com/keybase/client.git","svn_url":"https://github.com/keybase/client","homepage":"","size":117375,"stargazers_count":30,"watchers_count":30,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":3,"mirror_url":null,"open_issues_count":17,"forks":3,"open_issues":17,"watchers":30,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/keybase/client/pulls/1460"},"html":{"href":"https://github.com/keybase/client/pull/1460"},"issue":{"href":"https://api.github.com/repos/keybase/client/issues/1460"},"comments":{"href":"https://api.github.com/repos/keybase/client/issues/1460/comments"},"review_comments":{"href":"https://api.github.com/repos/keybase/client/pulls/1460/comments"},"review_comment":{"href":"https://api.github.com/repos/keybase/client/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/keybase/client/pulls/1460/commits"},"statuses":{"href":"https://api.github.com/repos/keybase/client/statuses/3f3e169555645c94e28473e836545f3d1b7726e4"}}}}