All of lore.kernel.org
 help / color / mirror / Atom feed
* using --force-with-lease after git rebase
@ 2018-10-31 19:13 Alexander Mills
  2018-11-01  0:58 ` brian m. carlson
  2018-11-01  1:19 ` Junio C Hamano
  0 siblings, 2 replies; 3+ messages in thread
From: Alexander Mills @ 2018-10-31 19:13 UTC (permalink / raw)
  To: git

I have been confused about the need for --force-with-lease after rebasing

Imagine I have a feature branch:

git checkout --no-track -b 'feature' 'origin/dev'
git push -u origin feature

I do some work, and then I rebase against origin/dev to keep up to
date with the integration branch.

git fetch origin/dev
git rebase origin/dev

then I try to push to the remote

git push origin feature

but that is rejected, I have to do:

git push --force-with-lease origin feature

why is that? Why do I need to force push my feature branch to the
remote tracking branch after rebasing against the integration branch?

-alex

related question:
https://stackoverflow.com/questions/52823692/git-push-force-with-lease-vs-force/53042745#53042745



-- 
Alexander D. Mills
¡¡¡ New cell phone number: (415)730-1805 !!!
alexander.d.mills@gmail.com

www.linkedin.com/pub/alexander-mills/b/7a5/418/

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-11-01  1:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-31 19:13 using --force-with-lease after git rebase Alexander Mills
2018-11-01  0:58 ` brian m. carlson
2018-11-01  1:19 ` Junio C Hamano

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.