home | list info | list archive | date index | thread index

[OCLUG-Tech] more trivial git questions: when will git refuse to delete a branch?

  • Subject: [OCLUG-Tech] more trivial git questions: when will git refuse to delete a branch?
  • From: "Robert P. J. Day" <rpjday [ at ] crashcourse [ dot ] ca>
  • Date: Thu, 18 Jun 2015 03:45:31 -0400 (EDT)
  still poring over the minutiae of git, and want to make sure i
understand the circumstances under which git will refuse to delete a
branch, or will at least generate a warning.

  first, git will typically refuse to delete a branch if it's not
"fully merged", but if i understand this correctly, the only checking
for being "fully merged" is two conditions:

* compare against current branch HEAD, or
* compare against upstream branch

  if the branch being deleted is not fully merged into the current
branch HEAD (ignore upstream for now), then you get the standard
error, "branch not fully merged, use -D ... etc etc ..." but just to
be clear, this check is being made *only* against the current branch
HEAD -- it's entirely possible that that branch could be fully merged
into some *other* branch in the repo, but that won't be tested.

  do i have that right? sometimes, the documentation is not as clear
as it could be.

rday


-- 

========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                        http://crashcourse.ca

Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================