b0rk, (edited )
@b0rk@jvns.ca avatar

what would you call a git commit that can no longer be reached from any branch or reference (for example because you ran git commit --amend or git rebase), but that you can still get to from git reflog?

I've considered "orphan", "dangling", and "unreachable" but none of these seem right:

  • orphan has another meaning in git
  • dangling only refers to the "tip" commits
  • "unreachable" means that you can't reach it at all

would love a term that's already used, I don't like inventing terms

shana,
@shana@mastodon.gamedev.place avatar

@b0rk Why wouldn't it be a dangling commit? It is the tip of its own branching history line, it just doesn't have a label associated with it.

b0rk,
@b0rk@jvns.ca avatar

@shana i also want to talk about some of that commit's parent commit(s), if they’re not in the history of any branch/reference either. not just the one that's the tip.

phord,
@phord@techhub.social avatar

@b0rk @shana I don't think it's correct to say "dangling only refers to the 'tip' commits". All commits are "tip commits" at some point; no commit is special in that regard, particularly when you remove references. How would you define such a thing? "This dangling commit is not a tip because some other dangling commit refers to it as its parent"? Ludicrous and unsupportable, imo.

b0rk,
@b0rk@jvns.ca avatar

@phord extremely not interested in getting into an argument about this but here's how the git glossary defines "dangling object"

https://git-scm.com/docs/gitglossary#Documentation/gitglossary.txt-aiddefdanglingobjectadanglingobject

py,
@py@androiddev.social avatar

@b0rk could be just me, but I think of "unreachable" as "cannot reach through any paths that starts from references". "Reaching" = traversing a path?

In other words, "unreachable" is short for "unreachable from references"?

b0rk,
@b0rk@jvns.ca avatar

@py it depends, git uses the word to mean multiple things in different contexts i think. that’s one of them

hypolite,

@b0rk "stranded" ? Although it isn't used anywhere else that I know of.

isagalaev,
@isagalaev@mastodon.social avatar

@b0rk orphan has another meaning? TIL!

acdha,
@acdha@code4lib.social avatar

@b0rk I call them unreachable because that's what git-fsck defines the term as (“objects that exist but that aren’t reachable from any of the reference nodes”) and I don't have a strong enough opinion to want to maintain a mental mapping for a different term.

isntitvacant,
@isntitvacant@hachyderm.io avatar

@b0rk in the vein of “unreferenced”, “unnamed”.

Drmowinckels,
@Drmowinckels@fosstodon.org avatar

@b0rk siloed? Can I turn silo into a verb? Yes I can!

bsmedberg,

@b0rk I totally thought "orphan" meant this, so now I'm really curious to know the difference between this and an orphan!

b0rk,
@b0rk@jvns.ca avatar
markw,
@markw@mstdn.social avatar

@b0rk @bsmedberg so, a commit without a parent?

b0rk,
@b0rk@jvns.ca avatar

@markw @bsmedberg confusingly:

  • people often use the term "orphan commit" to refer to a dangling/unreachable commit. git's source code even uses the term that way
  • people also use "orphan commit" to refer to a commit without a parent
  • people use "orphan branch" to mean either a branch that doesn't have any commits on it yet, or a branch which has a different root commit from your main branch
geeksam,
@geeksam@ruby.social avatar

@b0rk "endangered"? "limbo commit"? "hidden"?

tcely,
@tcely@fosstodon.org avatar

Endangered works for me because it will eventually go away.

@geeksam
@b0rk

  • All
  • Subscribed
  • Moderated
  • Favorites
  • random
  • ngwrru68w68
  • rosin
  • GTA5RPClips
  • osvaldo12
  • love
  • Youngstown
  • slotface
  • khanakhh
  • everett
  • kavyap
  • mdbf
  • DreamBathrooms
  • thenastyranch
  • magazineikmin
  • anitta
  • InstantRegret
  • normalnudes
  • tacticalgear
  • cubers
  • ethstaker
  • modclub
  • cisconetworking
  • Durango
  • provamag3
  • tester
  • Leos
  • megavids
  • JUstTest
  • All magazines