You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Feature Request: Sync with upstream repository #6862
When working on an upstream repository, I will clone that into my own GitHub (origin) then connect that repository to Desktop. I only ever want to work on origin/branch, but want to keep the origin/master in sync with the upstream/master.
The only way I have found (assuming I have added the upstream already) is to, from the CLI, do
git pull upstream master
git push origin master
Being able to do this more easily would really help (I have to look it up every time).
@borpin we also have a "Notification of Diverging from Default Branch" feature that might help here. It was originally implemented in #4969 and has been around for a while, and I'd love to figure out why it's not working for you as the fork scenario is one that we had in mind when we implemented it.
An example of it in action:
We've wanted to prompt in a timely manner without being too disruptive, and maybe there's something with your setup that means this isn't showing up at the appropriate time. Is this something that interests you? If so, we can try and dig into why you're not seeing it.
Thanks, It could be I was not looking for it. I'll keep an eye out for it.
It does interest me. I'll keep an eye out and see if I just missed it. As it is in 'History' it is not as obvious as it might be. You could argue that, as it relates to changes perhaps it should appear on that tab.
One thing, in that screenshot, under 'Current Repository' it would be useful if it said where it was from, so for me, when I am on my fork, I'd see borpin/xxxxx and if I was on the upstream I'd see upstream-repo/xxxxx. At the moment as it just says xxxxx is is ambiguous.
@borpin that screenshot isn't ideal because it's not working from a fork (hence the different icon in the "Current Repository" area). If I were working in a fork, it would be comparing to upstream/[default-branch-name] which sounds like what you're interested in.
So this is the upstream (I see now the icon at the side changes for upstream v fork - very subtle) - I'd like to see the same text you see in the dropdown.
You can see here there is a dropdown arrow which is telling me I am 103 commits behind.
If I click on the arrow I now see,
Ah, it says origin remote, I'd expect it to say upstream (I'd thought origin was always the fork).
So I've worked out how to do it, thanks to your prompting, but I am not seeing it as a friendly message you showed above 😄.
@borpin thanks for the extra screenshot, this definitely helps me understand your situation further!
You've touched on a few different areas about how we deal with forks, but it's late on Friday here and I'd like to extract these out to independent items (or reference existing issues) so we can discuss and prioritize them accordingly.
Just opened a repo that I forked a while ago. GitHub web shows
But I am getting nothing in Desktop that indicates this (not even the arrow in the 'Current Repository' dropdown). I saw an issue regarding Desktop asking about adding in the remote upstream when a repository was cloned, but I did not see that as an option.
There is the Origin in the Repository settings, but no option to include an upstream.
@borpin some extra context on the flow you went through:
You can see here there is a dropdown arrow which is telling me I am 103 commits behind.
This arrow is used to show the ahead/behind details for your current branch, using tracking branch set in configuration (this will likely be on origin).
If I click on the arrow
This icon is not intended to be clickable, but this is an interesting bit of feedback about the UX.
Ah, it says origin remote, I'd expect it to say upstream (I'd thought origin was always the fork).
This is a new action that was added as part of #6445 and is also based on your current tracked branch. Git doesn't support tracking multiple branches, so this is where our prompt about "Your branch is XYZ commits behind [default branch]" comes in.
I've opened #6875 as a proposal to make this flow more intuitive, and I'd love to hear your input there based on your current experiences with working with forks in the app.
There is the Origin in the Repository settings, but no option to include an upstream.
Desktop should be adding an upstream remote for the fork once it's tracked in the app, if it's a GitHub repository. I've opened #6877 to discuss making this more prominent in the UI.
I'm going to close this out as I think those are the fork-specific issues worth discussing in more detail, but feel free to open fresh issues if there are other things you would like to see improved about how we handle forks in the app.
Activity
j-f1 commentedon Feb 15, 2019
You can go into the Compare tab and merge in
upstream/master.borpin commentedon Feb 15, 2019
Not seeing a compare tab (not saying it isn't there)
borpin commentedon Feb 15, 2019
OK yes I see now. Not obvious but great.
shiftkey commentedon Feb 15, 2019
@borpin we also have a "Notification of Diverging from Default Branch" feature that might help here. It was originally implemented in #4969 and has been around for a while, and I'd love to figure out why it's not working for you as the fork scenario is one that we had in mind when we implemented it.
An example of it in action:
We've wanted to prompt in a timely manner without being too disruptive, and maybe there's something with your setup that means this isn't showing up at the appropriate time. Is this something that interests you? If so, we can try and dig into why you're not seeing it.
borpin commentedon Feb 15, 2019
Thanks, It could be I was not looking for it. I'll keep an eye out for it.
It does interest me. I'll keep an eye out and see if I just missed it. As it is in 'History' it is not as obvious as it might be. You could argue that, as it relates to changes perhaps it should appear on that tab.
One thing, in that screenshot, under 'Current Repository' it would be useful if it said where it was from, so for me, when I am on my fork, I'd see
borpin/xxxxxand if I was on the upstream I'd seeupstream-repo/xxxxx. At the moment as it just saysxxxxxis is ambiguous.shiftkey commentedon Feb 15, 2019
@borpin that screenshot isn't ideal because it's not working from a fork (hence the different icon in the "Current Repository" area). If I were working in a fork, it would be comparing to
upstream/[default-branch-name]which sounds like what you're interested in.borpin commentedon Feb 15, 2019
So this is the upstream (I see now the icon at the side changes for upstream v fork - very subtle) - I'd like to see the same text you see in the dropdown.
You can see here there is a dropdown arrow which is telling me I am 103 commits behind.
If I click on the arrow I now see,
Ah, it says origin remote, I'd expect it to say upstream (I'd thought origin was always the fork).
So I've worked out how to do it, thanks to your prompting, but I am not seeing it as a friendly message you showed above 😄.
shiftkey commentedon Feb 15, 2019
@borpin thanks for the extra screenshot, this definitely helps me understand your situation further!
You've touched on a few different areas about how we deal with forks, but it's late on Friday here and I'd like to extract these out to independent items (or reference existing issues) so we can discuss and prioritize them accordingly.
borpin commentedon Feb 16, 2019
@shiftkey, happy with that. I'm on UK time.
borpin commentedon Feb 16, 2019
Just opened a repo that I forked a while ago. GitHub web shows
But I am getting nothing in Desktop that indicates this (not even the arrow in the 'Current Repository' dropdown). I saw an issue regarding Desktop asking about adding in the remote upstream when a repository was cloned, but I did not see that as an option.
There is the Origin in the Repository settings, but no option to include an upstream.

shiftkey commentedon Feb 19, 2019
@borpin some extra context on the flow you went through:
This arrow is used to show the ahead/behind details for your current branch, using tracking branch set in configuration (this will likely be on
origin).This icon is not intended to be clickable, but this is an interesting bit of feedback about the UX.
This is a new action that was added as part of #6445 and is also based on your current tracked branch. Git doesn't support tracking multiple branches, so this is where our prompt about "Your branch is XYZ commits behind [default branch]" comes in.
I've opened #6875 as a proposal to make this flow more intuitive, and I'd love to hear your input there based on your current experiences with working with forks in the app.
Desktop should be adding an upstream remote for the fork once it's tracked in the app, if it's a GitHub repository. I've opened #6877 to discuss making this more prominent in the UI.
I'm going to close this out as I think those are the fork-specific issues worth discussing in more detail, but feel free to open fresh issues if there are other things you would like to see improved about how we handle forks in the app.