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
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi,
I'm using
git
in the following waygit switch -c whatever upstream/main
This way my branch refers to upstream code (assuming here, the project I code is in upstream remote, and the up to date branch is main)
So I can rebase by using
git pull --rebase
I'm using this patterns for years.
I started using
gh
a few weeks ago.There is something I dislike when I use
gh pr create
The upstream branch is somehow set to the new branch I created on my fork. So
origin/whatever
I looked at documentation and CLI option, and I found no way to avoid this behavior.
So I often have to launch
git branch --set-upstream upstream/main
Is there something I'm missing? Is it a common practice I don't get? What could the need for
gh
to reset my upstream branch when I push code.Beta Was this translation helpful? Give feedback.
All reactions