{"action":"created","comment":{"url":"https://api.github.com/repos/ParticularLabs/GitVersion/pulls/comments/32599197","id":32599197,"diff_hunk":"@@ -203,6 +205,9 @@ static void CreateMissingLocalBranchesFromRemoteTrackingOnes(Repository repo, st\n                 {\n                     repo.Refs.Add(localCanonicalName, new ObjectId(symbolicReference.ResolveToDirectReference().TargetIdentifier), true);\n                 }\n+\n+                var branch = repo.Branches[branchName];\n+                repo.Branches.Update(branch, b => b.TrackedBranch = remoteTrackingReferenceName);","path":"GitVersionCore/BuildServers/GitHelper.cs","position":17,"original_position":17,"commit_id":"c69bcb68b86845f13f059fca8f5d9cb2eefc471c","original_commit_id":"c69bcb68b86845f13f059fca8f5d9cb2eefc471c","user":{"login":"nulltoken","id":92363,"avatar_url":"https://avatars.githubusercontent.com/u/92363?v=3","gravatar_id":"","url":"https://api.github.com/users/nulltoken","html_url":"https://github.com/nulltoken","followers_url":"https://api.github.com/users/nulltoken/followers","following_url":"https://api.github.com/users/nulltoken/following{/other_user}","gists_url":"https://api.github.com/users/nulltoken/gists{/gist_id}","starred_url":"https://api.github.com/users/nulltoken/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nulltoken/subscriptions","organizations_url":"https://api.github.com/users/nulltoken/orgs","repos_url":"https://api.github.com/users/nulltoken/repos","events_url":"https://api.github.com/users/nulltoken/events{/privacy}","received_events_url":"https://api.github.com/users/nulltoken/received_events","type":"User","site_admin":false},"body":"Would GV be run on a development environment, this would blindly overwrite the potentially existing tracking configuration for every considered branch. Is this expected?\r\n\r\n/cc @JakeGinnivan ","created_at":"2015-06-17T06:49:34Z","updated_at":"2015-06-17T06:49:34Z","html_url":"https://github.com/ParticularLabs/GitVersion/pull/464#discussion_r32599197","pull_request_url":"https://api.github.com/repos/ParticularLabs/GitVersion/pulls/464","_links":{"self":{"href":"https://api.github.com/repos/ParticularLabs/GitVersion/pulls/comments/32599197"},"html":{"href":"https://github.com/ParticularLabs/GitVersion/pull/464#discussion_r32599197"},"pull_request":{"href":"https://api.github.com/repos/ParticularLabs/GitVersion/pulls/464"}}},"pull_request":{"url":"https://api.github.com/repos/ParticularLabs/GitVersion/pulls/464","id":37669873,"html_url":"https://github.com/ParticularLabs/GitVersion/pull/464","diff_url":"https://github.com/ParticularLabs/GitVersion/pull/464.diff","patch_url":"https://github.com/ParticularLabs/GitVersion/pull/464.patch","issue_url":"https://api.github.com/repos/ParticularLabs/GitVersion/issues/464","number":464,"state":"open","locked":false,"title":"Fix tracking branches in dynamic repositories","user":{"login":"eggapauli","id":237707,"avatar_url":"https://avatars.githubusercontent.com/u/237707?v=3","gravatar_id":"","url":"https://api.github.com/users/eggapauli","html_url":"https://github.com/eggapauli","followers_url":"https://api.github.com/users/eggapauli/followers","following_url":"https://api.github.com/users/eggapauli/following{/other_user}","gists_url":"https://api.github.com/users/eggapauli/gists{/gist_id}","starred_url":"https://api.github.com/users/eggapauli/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eggapauli/subscriptions","organizations_url":"https://api.github.com/users/eggapauli/orgs","repos_url":"https://api.github.com/users/eggapauli/repos","events_url":"https://api.github.com/users/eggapauli/events{/privacy}","received_events_url":"https://api.github.com/users/eggapauli/received_events","type":"User","site_admin":false},"body":"When running GitVersion with a dynamic repository using a new branch it cannot find a remote tracking branch. I dug a bit deeper and found that in `GitHelper.CreateMissingLocalBranchesFromRemoteTrackingOnes` the `remoteTrackingReference` is a `DirectReference`, but I think it should be a `SymbolicReference` for this to work.\r\n\r\nI'm not sure how to fix this as I'm not familiar with LibGit2Sharp. Any advice?","created_at":"2015-06-15T08:50:59Z","updated_at":"2015-06-17T06:49:34Z","closed_at":null,"merged_at":null,"merge_commit_sha":"14dc96f38a48d50ff4174275bda3e0fefa920a13","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ParticularLabs/GitVersion/pulls/464/commits","review_comments_url":"https://api.github.com/repos/ParticularLabs/GitVersion/pulls/464/comments","review_comment_url":"https://api.github.com/repos/ParticularLabs/GitVersion/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ParticularLabs/GitVersion/issues/464/comments","statuses_url":"https://api.github.com/repos/ParticularLabs/GitVersion/statuses/c69bcb68b86845f13f059fca8f5d9cb2eefc471c","head":{"label":"eggapauli:no-tracking-branch-in-dynamic-repo","ref":"no-tracking-branch-in-dynamic-repo","sha":"c69bcb68b86845f13f059fca8f5d9cb2eefc471c","user":{"login":"eggapauli","id":237707,"avatar_url":"https://avatars.githubusercontent.com/u/237707?v=3","gravatar_id":"","url":"https://api.github.com/users/eggapauli","html_url":"https://github.com/eggapauli","followers_url":"https://api.github.com/users/eggapauli/followers","following_url":"https://api.github.com/users/eggapauli/following{/other_user}","gists_url":"https://api.github.com/users/eggapauli/gists{/gist_id}","starred_url":"https://api.github.com/users/eggapauli/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eggapauli/subscriptions","organizations_url":"https://api.github.com/users/eggapauli/orgs","repos_url":"https://api.github.com/users/eggapauli/repos","events_url":"https://api.github.com/users/eggapauli/events{/privacy}","received_events_url":"https://api.github.com/users/eggapauli/received_events","type":"User","site_admin":false},"repo":{"id":31902015,"name":"GitVersion","full_name":"eggapauli/GitVersion","owner":{"login":"eggapauli","id":237707,"avatar_url":"https://avatars.githubusercontent.com/u/237707?v=3","gravatar_id":"","url":"https://api.github.com/users/eggapauli","html_url":"https://github.com/eggapauli","followers_url":"https://api.github.com/users/eggapauli/followers","following_url":"https://api.github.com/users/eggapauli/following{/other_user}","gists_url":"https://api.github.com/users/eggapauli/gists{/gist_id}","starred_url":"https://api.github.com/users/eggapauli/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eggapauli/subscriptions","organizations_url":"https://api.github.com/users/eggapauli/orgs","repos_url":"https://api.github.com/users/eggapauli/repos","events_url":"https://api.github.com/users/eggapauli/events{/privacy}","received_events_url":"https://api.github.com/users/eggapauli/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/eggapauli/GitVersion","description":"Easy Semantic Versioning (http://semver.org) for projects using Git","fork":true,"url":"https://api.github.com/repos/eggapauli/GitVersion","forks_url":"https://api.github.com/repos/eggapauli/GitVersion/forks","keys_url":"https://api.github.com/repos/eggapauli/GitVersion/keys{/key_id}","collaborators_url":"https://api.github.com/repos/eggapauli/GitVersion/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/eggapauli/GitVersion/teams","hooks_url":"https://api.github.com/repos/eggapauli/GitVersion/hooks","issue_events_url":"https://api.github.com/repos/eggapauli/GitVersion/issues/events{/number}","events_url":"https://api.github.com/repos/eggapauli/GitVersion/events","assignees_url":"https://api.github.com/repos/eggapauli/GitVersion/assignees{/user}","branches_url":"https://api.github.com/repos/eggapauli/GitVersion/branches{/branch}","tags_url":"https://api.github.com/repos/eggapauli/GitVersion/tags","blobs_url":"https://api.github.com/repos/eggapauli/GitVersion/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/eggapauli/GitVersion/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/eggapauli/GitVersion/git/refs{/sha}","trees_url":"https://api.github.com/repos/eggapauli/GitVersion/git/trees{/sha}","statuses_url":"https://api.github.com/repos/eggapauli/GitVersion/statuses/{sha}","languages_url":"https://api.github.com/repos/eggapauli/GitVersion/languages","stargazers_url":"https://api.github.com/repos/eggapauli/GitVersion/stargazers","contributors_url":"https://api.github.com/repos/eggapauli/GitVersion/contributors","subscribers_url":"https://api.github.com/repos/eggapauli/GitVersion/subscribers","subscription_url":"https://api.github.com/repos/eggapauli/GitVersion/subscription","commits_url":"https://api.github.com/repos/eggapauli/GitVersion/commits{/sha}","git_commits_url":"https://api.github.com/repos/eggapauli/GitVersion/git/commits{/sha}","comments_url":"https://api.github.com/repos/eggapauli/GitVersion/comments{/number}","issue_comment_url":"https://api.github.com/repos/eggapauli/GitVersion/issues/comments{/number}","contents_url":"https://api.github.com/repos/eggapauli/GitVersion/contents/{+path}","compare_url":"https://api.github.com/repos/eggapauli/GitVersion/compare/{base}...{head}","merges_url":"https://api.github.com/repos/eggapauli/GitVersion/merges","archive_url":"https://api.github.com/repos/eggapauli/GitVersion/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/eggapauli/GitVersion/downloads","issues_url":"https://api.github.com/repos/eggapauli/GitVersion/issues{/number}","pulls_url":"https://api.github.com/repos/eggapauli/GitVersion/pulls{/number}","milestones_url":"https://api.github.com/repos/eggapauli/GitVersion/milestones{/number}","notifications_url":"https://api.github.com/repos/eggapauli/GitVersion/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/eggapauli/GitVersion/labels{/name}","releases_url":"https://api.github.com/repos/eggapauli/GitVersion/releases{/id}","created_at":"2015-03-09T14:11:31Z","updated_at":"2015-03-09T14:18:35Z","pushed_at":"2015-06-17T05:40:08Z","git_url":"git://github.com/eggapauli/GitVersion.git","ssh_url":"git@github.com:eggapauli/GitVersion.git","clone_url":"https://github.com/eggapauli/GitVersion.git","svn_url":"https://github.com/eggapauli/GitVersion","homepage":"http://particularlabs.github.io/GitVersion/","size":5785,"stargazers_count":0,"watchers_count":0,"language":"C#","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"ParticularLabs:master","ref":"master","sha":"97dade82877fae86d6f0f106bc21aae9fa06d32c","user":{"login":"ParticularLabs","id":9639057,"avatar_url":"https://avatars.githubusercontent.com/u/9639057?v=3","gravatar_id":"","url":"https://api.github.com/users/ParticularLabs","html_url":"https://github.com/ParticularLabs","followers_url":"https://api.github.com/users/ParticularLabs/followers","following_url":"https://api.github.com/users/ParticularLabs/following{/other_user}","gists_url":"https://api.github.com/users/ParticularLabs/gists{/gist_id}","starred_url":"https://api.github.com/users/ParticularLabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ParticularLabs/subscriptions","organizations_url":"https://api.github.com/users/ParticularLabs/orgs","repos_url":"https://api.github.com/users/ParticularLabs/repos","events_url":"https://api.github.com/users/ParticularLabs/events{/privacy}","received_events_url":"https://api.github.com/users/ParticularLabs/received_events","type":"Organization","site_admin":false},"repo":{"id":12399790,"name":"GitVersion","full_name":"ParticularLabs/GitVersion","owner":{"login":"ParticularLabs","id":9639057,"avatar_url":"https://avatars.githubusercontent.com/u/9639057?v=3","gravatar_id":"","url":"https://api.github.com/users/ParticularLabs","html_url":"https://github.com/ParticularLabs","followers_url":"https://api.github.com/users/ParticularLabs/followers","following_url":"https://api.github.com/users/ParticularLabs/following{/other_user}","gists_url":"https://api.github.com/users/ParticularLabs/gists{/gist_id}","starred_url":"https://api.github.com/users/ParticularLabs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ParticularLabs/subscriptions","organizations_url":"https://api.github.com/users/ParticularLabs/orgs","repos_url":"https://api.github.com/users/ParticularLabs/repos","events_url":"https://api.github.com/users/ParticularLabs/events{/privacy}","received_events_url":"https://api.github.com/users/ParticularLabs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ParticularLabs/GitVersion","description":"Easy Semantic Versioning (http://semver.org) for projects using Git","fork":false,"url":"https://api.github.com/repos/ParticularLabs/GitVersion","forks_url":"https://api.github.com/repos/ParticularLabs/GitVersion/forks","keys_url":"https://api.github.com/repos/ParticularLabs/GitVersion/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ParticularLabs/GitVersion/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ParticularLabs/GitVersion/teams","hooks_url":"https://api.github.com/repos/ParticularLabs/GitVersion/hooks","issue_events_url":"https://api.github.com/repos/ParticularLabs/GitVersion/issues/events{/number}","events_url":"https://api.github.com/repos/ParticularLabs/GitVersion/events","assignees_url":"https://api.github.com/repos/ParticularLabs/GitVersion/assignees{/user}","branches_url":"https://api.github.com/repos/ParticularLabs/GitVersion/branches{/branch}","tags_url":"https://api.github.com/repos/ParticularLabs/GitVersion/tags","blobs_url":"https://api.github.com/repos/ParticularLabs/GitVersion/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ParticularLabs/GitVersion/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ParticularLabs/GitVersion/git/refs{/sha}","trees_url":"https://api.github.com/repos/ParticularLabs/GitVersion/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ParticularLabs/GitVersion/statuses/{sha}","languages_url":"https://api.github.com/repos/ParticularLabs/GitVersion/languages","stargazers_url":"https://api.github.com/repos/ParticularLabs/GitVersion/stargazers","contributors_url":"https://api.github.com/repos/ParticularLabs/GitVersion/contributors","subscribers_url":"https://api.github.com/repos/ParticularLabs/GitVersion/subscribers","subscription_url":"https://api.github.com/repos/ParticularLabs/GitVersion/subscription","commits_url":"https://api.github.com/repos/ParticularLabs/GitVersion/commits{/sha}","git_commits_url":"https://api.github.com/repos/ParticularLabs/GitVersion/git/commits{/sha}","comments_url":"https://api.github.com/repos/ParticularLabs/GitVersion/comments{/number}","issue_comment_url":"https://api.github.com/repos/ParticularLabs/GitVersion/issues/comments{/number}","contents_url":"https://api.github.com/repos/ParticularLabs/GitVersion/contents/{+path}","compare_url":"https://api.github.com/repos/ParticularLabs/GitVersion/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ParticularLabs/GitVersion/merges","archive_url":"https://api.github.com/repos/ParticularLabs/GitVersion/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ParticularLabs/GitVersion/downloads","issues_url":"https://api.github.com/repos/ParticularLabs/GitVersion/issues{/number}","pulls_url":"https://api.github.com/repos/ParticularLabs/GitVersion/pulls{/number}","milestones_url":"https://api.github.com/repos/ParticularLabs/GitVersion/milestones{/number}","notifications_url":"https://api.github.com/repos/ParticularLabs/GitVersion/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ParticularLabs/GitVersion/labels{/name}","releases_url":"https://api.github.com/repos/ParticularLabs/GitVersion/releases{/id}","created_at":"2013-08-27T07:30:20Z","updated_at":"2015-06-16T23:05:15Z","pushed_at":"2015-06-17T05:40:08Z","git_url":"git://github.com/ParticularLabs/GitVersion.git","ssh_url":"git@github.com:ParticularLabs/GitVersion.git","clone_url":"https://github.com/ParticularLabs/GitVersion.git","svn_url":"https://github.com/ParticularLabs/GitVersion","homepage":"http://particularlabs.github.io/GitVersion/","size":8269,"stargazers_count":208,"watchers_count":208,"language":"C#","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":70,"mirror_url":null,"open_issues_count":42,"forks":70,"open_issues":42,"watchers":208,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ParticularLabs/GitVersion/pulls/464"},"html":{"href":"https://github.com/ParticularLabs/GitVersion/pull/464"},"issue":{"href":"https://api.github.com/repos/ParticularLabs/GitVersion/issues/464"},"comments":{"href":"https://api.github.com/repos/ParticularLabs/GitVersion/issues/464/comments"},"review_comments":{"href":"https://api.github.com/repos/ParticularLabs/GitVersion/pulls/464/comments"},"review_comment":{"href":"https://api.github.com/repos/ParticularLabs/GitVersion/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ParticularLabs/GitVersion/pulls/464/commits"},"statuses":{"href":"https://api.github.com/repos/ParticularLabs/GitVersion/statuses/c69bcb68b86845f13f059fca8f5d9cb2eefc471c"}}}}