{"action":"created","comment":{"url":"https://api.github.com/repos/desktop/desktop/pulls/comments/183906017","pull_request_review_id":114995959,"id":183906017,"diff_hunk":"@@ -4,14 +4,29 @@ import { Repository } from '../../models/repository'\n import { Branch, BranchType, IAheadBehind } from '../../models/branch'\n \n /**\n- * Convert two refs into the Git range syntax.\n+ * Convert two refs into the Git range syntax representing the set of commits\n+ * that are reachable from `to` but excluding those that are reachable from\n+ * `from`.\n  *\n  * Each parameter can be the commit SHA or a ref name.\n  *\n  * @param from The start of the range\n  * @param to The end of the range\n  */\n-export function asRange(from: string, to: string) {\n+export function asDistinctRange(from: string, to: string) {\n+  return `${from}..${to}`","path":"app/src/lib/git/rev-list.ts","position":16,"original_position":16,"commit_id":"c44bd963f4d630042326647e0ebc509fb6769564","original_commit_id":"c44bd963f4d630042326647e0ebc509fb6769564","user":{"login":"shiftkey","id":359239,"avatar_url":"https://avatars2.githubusercontent.com/u/359239?v=4","gravatar_id":"","url":"https://api.github.com/users/shiftkey","html_url":"https://github.com/shiftkey","followers_url":"https://api.github.com/users/shiftkey/followers","following_url":"https://api.github.com/users/shiftkey/following{/other_user}","gists_url":"https://api.github.com/users/shiftkey/gists{/gist_id}","starred_url":"https://api.github.com/users/shiftkey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shiftkey/subscriptions","organizations_url":"https://api.github.com/users/shiftkey/orgs","repos_url":"https://api.github.com/users/shiftkey/repos","events_url":"https://api.github.com/users/shiftkey/events{/privacy}","received_events_url":"https://api.github.com/users/shiftkey/received_events","type":"User","site_admin":true},"body":"Nevermind, the existing behaviour was accurate - I'll update this PR to make it clearer.","created_at":"2018-04-24T23:10:26Z","updated_at":"2018-04-24T23:10:26Z","html_url":"https://github.com/desktop/desktop/pull/4516#discussion_r183906017","pull_request_url":"https://api.github.com/repos/desktop/desktop/pulls/4516","author_association":"OWNER","_links":{"self":{"href":"https://api.github.com/repos/desktop/desktop/pulls/comments/183906017"},"html":{"href":"https://github.com/desktop/desktop/pull/4516#discussion_r183906017"},"pull_request":{"href":"https://api.github.com/repos/desktop/desktop/pulls/4516"}},"in_reply_to_id":183819503},"pull_request":{"url":"https://api.github.com/repos/desktop/desktop/pulls/4516","id":183808862,"html_url":"https://github.com/desktop/desktop/pull/4516","diff_url":"https://github.com/desktop/desktop/pull/4516.diff","patch_url":"https://github.com/desktop/desktop/pull/4516.patch","issue_url":"https://api.github.com/repos/desktop/desktop/issues/4516","number":4516,"state":"open","locked":false,"title":"asRange tidy up","user":{"login":"shiftkey","id":359239,"avatar_url":"https://avatars2.githubusercontent.com/u/359239?v=4","gravatar_id":"","url":"https://api.github.com/users/shiftkey","html_url":"https://github.com/shiftkey","followers_url":"https://api.github.com/users/shiftkey/followers","following_url":"https://api.github.com/users/shiftkey/following{/other_user}","gists_url":"https://api.github.com/users/shiftkey/gists{/gist_id}","starred_url":"https://api.github.com/users/shiftkey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shiftkey/subscriptions","organizations_url":"https://api.github.com/users/shiftkey/orgs","repos_url":"https://api.github.com/users/shiftkey/repos","events_url":"https://api.github.com/users/shiftkey/events{/privacy}","received_events_url":"https://api.github.com/users/shiftkey/received_events","type":"User","site_admin":true},"body":"I was talking with @nerdneha last night about [dotted ranges](https://git-scm.com/docs/gitrevisions#_dotted_range_notations) in Git and realised that I should make `asRange` a bit more explicit, given that `..` and `...` have very different meaning in Git.\r\n\r\nTL;DR:\r\n\r\n - `asDistinctRange` aka `..` is the one that we should be using everywhere in Compare Branches, as this is the \"show everything reachable from `to` but exclude things reachable from `from`\" case.\r\n - `asSymmetricDifferenceRange` aka `...` is \"the set of commits that are reachable from either `from` or `to` but not from both\" and we have one usage of that\r\n","created_at":"2018-04-24T17:24:59Z","updated_at":"2018-04-24T23:10:26Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a798b32c39288f1402604447cdebd31415a7dc37","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/desktop/desktop/pulls/4516/commits","review_comments_url":"https://api.github.com/repos/desktop/desktop/pulls/4516/comments","review_comment_url":"https://api.github.com/repos/desktop/desktop/pulls/comments{/number}","comments_url":"https://api.github.com/repos/desktop/desktop/issues/4516/comments","statuses_url":"https://api.github.com/repos/desktop/desktop/statuses/c44bd963f4d630042326647e0ebc509fb6769564","head":{"label":"desktop:asrange-tidy-up","ref":"asrange-tidy-up","sha":"c44bd963f4d630042326647e0ebc509fb6769564","user":{"login":"desktop","id":13171334,"avatar_url":"https://avatars0.githubusercontent.com/u/13171334?v=4","gravatar_id":"","url":"https://api.github.com/users/desktop","html_url":"https://github.com/desktop","followers_url":"https://api.github.com/users/desktop/followers","following_url":"https://api.github.com/users/desktop/following{/other_user}","gists_url":"https://api.github.com/users/desktop/gists{/gist_id}","starred_url":"https://api.github.com/users/desktop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/desktop/subscriptions","organizations_url":"https://api.github.com/users/desktop/orgs","repos_url":"https://api.github.com/users/desktop/repos","events_url":"https://api.github.com/users/desktop/events{/privacy}","received_events_url":"https://api.github.com/users/desktop/received_events","type":"Organization","site_admin":false},"repo":{"id":58559694,"name":"desktop","full_name":"desktop/desktop","owner":{"login":"desktop","id":13171334,"avatar_url":"https://avatars0.githubusercontent.com/u/13171334?v=4","gravatar_id":"","url":"https://api.github.com/users/desktop","html_url":"https://github.com/desktop","followers_url":"https://api.github.com/users/desktop/followers","following_url":"https://api.github.com/users/desktop/following{/other_user}","gists_url":"https://api.github.com/users/desktop/gists{/gist_id}","starred_url":"https://api.github.com/users/desktop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/desktop/subscriptions","organizations_url":"https://api.github.com/users/desktop/orgs","repos_url":"https://api.github.com/users/desktop/repos","events_url":"https://api.github.com/users/desktop/events{/privacy}","received_events_url":"https://api.github.com/users/desktop/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/desktop/desktop","description":"Simple collaboration from your desktop","fork":false,"url":"https://api.github.com/repos/desktop/desktop","forks_url":"https://api.github.com/repos/desktop/desktop/forks","keys_url":"https://api.github.com/repos/desktop/desktop/keys{/key_id}","collaborators_url":"https://api.github.com/repos/desktop/desktop/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/desktop/desktop/teams","hooks_url":"https://api.github.com/repos/desktop/desktop/hooks","issue_events_url":"https://api.github.com/repos/desktop/desktop/issues/events{/number}","events_url":"https://api.github.com/repos/desktop/desktop/events","assignees_url":"https://api.github.com/repos/desktop/desktop/assignees{/user}","branches_url":"https://api.github.com/repos/desktop/desktop/branches{/branch}","tags_url":"https://api.github.com/repos/desktop/desktop/tags","blobs_url":"https://api.github.com/repos/desktop/desktop/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/desktop/desktop/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/desktop/desktop/git/refs{/sha}","trees_url":"https://api.github.com/repos/desktop/desktop/git/trees{/sha}","statuses_url":"https://api.github.com/repos/desktop/desktop/statuses/{sha}","languages_url":"https://api.github.com/repos/desktop/desktop/languages","stargazers_url":"https://api.github.com/repos/desktop/desktop/stargazers","contributors_url":"https://api.github.com/repos/desktop/desktop/contributors","subscribers_url":"https://api.github.com/repos/desktop/desktop/subscribers","subscription_url":"https://api.github.com/repos/desktop/desktop/subscription","commits_url":"https://api.github.com/repos/desktop/desktop/commits{/sha}","git_commits_url":"https://api.github.com/repos/desktop/desktop/git/commits{/sha}","comments_url":"https://api.github.com/repos/desktop/desktop/comments{/number}","issue_comment_url":"https://api.github.com/repos/desktop/desktop/issues/comments{/number}","contents_url":"https://api.github.com/repos/desktop/desktop/contents/{+path}","compare_url":"https://api.github.com/repos/desktop/desktop/compare/{base}...{head}","merges_url":"https://api.github.com/repos/desktop/desktop/merges","archive_url":"https://api.github.com/repos/desktop/desktop/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/desktop/desktop/downloads","issues_url":"https://api.github.com/repos/desktop/desktop/issues{/number}","pulls_url":"https://api.github.com/repos/desktop/desktop/pulls{/number}","milestones_url":"https://api.github.com/repos/desktop/desktop/milestones{/number}","notifications_url":"https://api.github.com/repos/desktop/desktop/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/desktop/desktop/labels{/name}","releases_url":"https://api.github.com/repos/desktop/desktop/releases{/id}","deployments_url":"https://api.github.com/repos/desktop/desktop/deployments","created_at":"2016-05-11T15:59:00Z","updated_at":"2018-04-24T22:13:14Z","pushed_at":"2018-04-24T23:00:47Z","git_url":"git://github.com/desktop/desktop.git","ssh_url":"git@github.com:desktop/desktop.git","clone_url":"https://github.com/desktop/desktop.git","svn_url":"https://github.com/desktop/desktop","homepage":"https://desktop.github.com","size":22451,"stargazers_count":4816,"watchers_count":4816,"language":"TypeScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1768,"mirror_url":null,"archived":false,"open_issues_count":319,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":1768,"open_issues":319,"watchers":4816,"default_branch":"master"}},"base":{"label":"desktop:master","ref":"master","sha":"2406f4b29a5641bbbf4c40db3add047bc8685074","user":{"login":"desktop","id":13171334,"avatar_url":"https://avatars0.githubusercontent.com/u/13171334?v=4","gravatar_id":"","url":"https://api.github.com/users/desktop","html_url":"https://github.com/desktop","followers_url":"https://api.github.com/users/desktop/followers","following_url":"https://api.github.com/users/desktop/following{/other_user}","gists_url":"https://api.github.com/users/desktop/gists{/gist_id}","starred_url":"https://api.github.com/users/desktop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/desktop/subscriptions","organizations_url":"https://api.github.com/users/desktop/orgs","repos_url":"https://api.github.com/users/desktop/repos","events_url":"https://api.github.com/users/desktop/events{/privacy}","received_events_url":"https://api.github.com/users/desktop/received_events","type":"Organization","site_admin":false},"repo":{"id":58559694,"name":"desktop","full_name":"desktop/desktop","owner":{"login":"desktop","id":13171334,"avatar_url":"https://avatars0.githubusercontent.com/u/13171334?v=4","gravatar_id":"","url":"https://api.github.com/users/desktop","html_url":"https://github.com/desktop","followers_url":"https://api.github.com/users/desktop/followers","following_url":"https://api.github.com/users/desktop/following{/other_user}","gists_url":"https://api.github.com/users/desktop/gists{/gist_id}","starred_url":"https://api.github.com/users/desktop/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/desktop/subscriptions","organizations_url":"https://api.github.com/users/desktop/orgs","repos_url":"https://api.github.com/users/desktop/repos","events_url":"https://api.github.com/users/desktop/events{/privacy}","received_events_url":"https://api.github.com/users/desktop/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/desktop/desktop","description":"Simple collaboration from your desktop","fork":false,"url":"https://api.github.com/repos/desktop/desktop","forks_url":"https://api.github.com/repos/desktop/desktop/forks","keys_url":"https://api.github.com/repos/desktop/desktop/keys{/key_id}","collaborators_url":"https://api.github.com/repos/desktop/desktop/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/desktop/desktop/teams","hooks_url":"https://api.github.com/repos/desktop/desktop/hooks","issue_events_url":"https://api.github.com/repos/desktop/desktop/issues/events{/number}","events_url":"https://api.github.com/repos/desktop/desktop/events","assignees_url":"https://api.github.com/repos/desktop/desktop/assignees{/user}","branches_url":"https://api.github.com/repos/desktop/desktop/branches{/branch}","tags_url":"https://api.github.com/repos/desktop/desktop/tags","blobs_url":"https://api.github.com/repos/desktop/desktop/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/desktop/desktop/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/desktop/desktop/git/refs{/sha}","trees_url":"https://api.github.com/repos/desktop/desktop/git/trees{/sha}","statuses_url":"https://api.github.com/repos/desktop/desktop/statuses/{sha}","languages_url":"https://api.github.com/repos/desktop/desktop/languages","stargazers_url":"https://api.github.com/repos/desktop/desktop/stargazers","contributors_url":"https://api.github.com/repos/desktop/desktop/contributors","subscribers_url":"https://api.github.com/repos/desktop/desktop/subscribers","subscription_url":"https://api.github.com/repos/desktop/desktop/subscription","commits_url":"https://api.github.com/repos/desktop/desktop/commits{/sha}","git_commits_url":"https://api.github.com/repos/desktop/desktop/git/commits{/sha}","comments_url":"https://api.github.com/repos/desktop/desktop/comments{/number}","issue_comment_url":"https://api.github.com/repos/desktop/desktop/issues/comments{/number}","contents_url":"https://api.github.com/repos/desktop/desktop/contents/{+path}","compare_url":"https://api.github.com/repos/desktop/desktop/compare/{base}...{head}","merges_url":"https://api.github.com/repos/desktop/desktop/merges","archive_url":"https://api.github.com/repos/desktop/desktop/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/desktop/desktop/downloads","issues_url":"https://api.github.com/repos/desktop/desktop/issues{/number}","pulls_url":"https://api.github.com/repos/desktop/desktop/pulls{/number}","milestones_url":"https://api.github.com/repos/desktop/desktop/milestones{/number}","notifications_url":"https://api.github.com/repos/desktop/desktop/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/desktop/desktop/labels{/name}","releases_url":"https://api.github.com/repos/desktop/desktop/releases{/id}","deployments_url":"https://api.github.com/repos/desktop/desktop/deployments","created_at":"2016-05-11T15:59:00Z","updated_at":"2018-04-24T22:13:14Z","pushed_at":"2018-04-24T23:00:47Z","git_url":"git://github.com/desktop/desktop.git","ssh_url":"git@github.com:desktop/desktop.git","clone_url":"https://github.com/desktop/desktop.git","svn_url":"https://github.com/desktop/desktop","homepage":"https://desktop.github.com","size":22451,"stargazers_count":4816,"watchers_count":4816,"language":"TypeScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1768,"mirror_url":null,"archived":false,"open_issues_count":319,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":1768,"open_issues":319,"watchers":4816,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/desktop/desktop/pulls/4516"},"html":{"href":"https://github.com/desktop/desktop/pull/4516"},"issue":{"href":"https://api.github.com/repos/desktop/desktop/issues/4516"},"comments":{"href":"https://api.github.com/repos/desktop/desktop/issues/4516/comments"},"review_comments":{"href":"https://api.github.com/repos/desktop/desktop/pulls/4516/comments"},"review_comment":{"href":"https://api.github.com/repos/desktop/desktop/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/desktop/desktop/pulls/4516/commits"},"statuses":{"href":"https://api.github.com/repos/desktop/desktop/statuses/c44bd963f4d630042326647e0ebc509fb6769564"}},"author_association":"OWNER"}}
{"actor":{"display_login":"shiftkey"}}