last day (15 days later) » 

5:34 PM
0
A: Bitucket - How can a team member get the new branch pushed to the main repo which he forked?

RomainValerigit fetch is the tool for this. (doc) It gets the new branch refs from the remote, then updates the remote-tracking branches, on your local repo. These branches are not to be confused with your local branches. They are images of the remote branches, for all purposes of diff, etc. Then, after ...

 
Thanks. I know how to do this in Github but not in Bitbucket as I am new. My team member is trying to access the dev branch on the upstream (main) repository, not his own remote repository. He has tried your solution with git fetch, but after git branch, he did not see the dev branch
 
Yes, because git branch only lists local branches. He would see it with git branch -r, but as I suggested, he can just git checkout <branchName> and afterwards it'll appear with a simple git branch
 
We just refreshed now but the dev branch is not on his forked repository. On running git branch -r we saw only the branches he created @RomainValeri
 
@sudo_kaizen If so, something's not right, something you didn't mention here and is left out of the picture. He should see the new branch after a fetch from a repo which has it. Maybe double-check if he's fetching from the proper remote, not another one? (git fetch --all would be the sledgehammer approach here, all remotes are fetched)
 
Thank you very much for your continuous support. My team member forked the main repo and cloned his forked repo to his local, so his origin is his forked repo. I have updated the question to explain the issue more clearly. COuld you please check it out? Thanks again! @RomainValeri
 
5:34 PM
@sudo_kaizen OK, I get it. He's succesfully asking his fork : "hey, new branches?" to which his fork answers : "nope." (and rightfully so). He has to set your own github repo (the origin of the fork itself) as 'upstream' or something, and fetch from it. Do you know how to set a remote?
hi there :)
after 7k points on the site..... this is my very first chat session ;-)
 
Yes! Exactly! git remote add name_of_remote url_of_remote
 
spot on
 
Haha! Your first chat.. It's mine too
 
honored :-p
I keep the window open ... back in a minute, I let you try in the meantime
 
And I have tried that with url_of_remote being that of my own
 
5:45 PM
any results ?
 
Nope
:{
I'm trying to send a mail to the support team
 
something's amiss :-/
no rights problem between his account and your repo ?
ssh ok ?
 
There are. When I try to setup the upstream branch on his local with my repo's url, it reports access rights issues. I added my team member with write access to the repo, and I added him to another group with read access to the repo all in an effort to solve the problem
 
yes it should do :)
no worries, these things are often a bit sketchy to setup at first
 
But that solution still did not work
 
6:01 PM
aw
and now I have to go .... kids waiting at home
I hope you'll sort it out quickly
good luck to you pal
see you around
 
Thanks! Love love to your kids sir!
 

last day (15 days later) »