Public Git repo
Jeff Kletsky
gnucash at allycomm.com
Mon Jan 10 10:56:41 EST 2011
At least as I understand it, branches in git are nothing more than a
pointer to the "head" commit and, structurally, are pretty much the same
(if not identical) to tags. A branch in git is a tag on point in
development that is moved to other commits if you commit "to" that
branch. In simpler words, it is a tag that gets conveniently moved each
time you commit. You really aren't "working on/in a branch" but are more
moving what the notion of the head of the branch is. Yeah, it's really
different from svn that way.
While there is the notion of "parent" and "child" commits (which can be
multiple) in git, one of the things that is different about git branches
is that there is no notion of a "branch point" or a "branch history" the
way there is in svn, for example. Sure, as long as you don't merge the
branch, you can determine where it diverges from another branch.
However, once you merge, that gets dicey to impossible. As long as you
don't really care where you came from and how, git branches are fine.
They can take care of
* most recent 2.2-Release version
* most recent 2.4-Release version
* most recent Stable version
* most recent Current (bleeding-edge) version
Git tags are really the "static" things to take care of the concept of:
* what are all the 2.2-Release versions?
* what are all the 2.4-Release versions?
On 01/10/2011 07:38 AM, Colin Law wrote:
> On 10 January 2011 15:12, Derek Atkins<warlord at mit.edu> wrote:
>> Geert Janssens<janssens-geert at telenet.be> writes:
>>
>>> On Wednesday 05 January 2011, Jeff Kletsky wrote:
>>>> I don't like that history is a pretty flexible thing and that "branches"
>>>> are just pointers to specific commits, rather than the kind of
>>>> "followable path" that svn provides.
>>>>
>>> That's interesting, because I feel exactly the oposite. I don't like it that
>>> for svn a branch or tag is a path into the repository. It has always felt
>>> artificial to me and if not treated with proper care could put you into very
>>> unwanted situations like people inadvertently committing changes to a tagged
>>> release.
>>> I guess this is mostly a matter of taste and what you are most used to
>>> though...
>> I like that branches are paths, because you DO want to be able to make
>> additional commits into a branch. So I don't agree with you there.
> I am not sure what you are suggesting here. Using git there is no
> problem committing to a branch, just checkout the branch, make the
> changes, and commit. The changes go onto the branch.
>
>> However, I do agree with you about tags.
>>
>> IMHO branches and tags are (and should be) fundamentally different. A
>> branch should be a path, but a tag is, well, a tag.
> I believe they *are* different in git, at least in terms of the normal
> usage via the git commands and utilities.
>
> Colin
> _______________________________________________
> gnucash-devel mailing list
> gnucash-devel at gnucash.org
> https://lists.gnucash.org/mailman/listinfo/gnucash-devel
More information about the gnucash-devel
mailing list