On Sat, 24 Oct 2015 17:29:30 -0700 (PDT)
ozzloy <ozz...@gmail.com> wrote:

> does `git commit` modify $GIT_DIR/index?
> i just diffed index from before and after a commit and found no
> difference.  i'm guessing this is reliable behavior, but i wanted to
> make sure.  it seems like the idea of index is that it's always ready
> and waiting to be turned into the next commit.  so commits wouldn't
> ever modify it.
> i'm writing a script that depends on this behavior and i want to make
> sure i have the concepts right.

Care to elaborate on why you want to depend on this?
(We should try to rule out a possible case of the "XY problem" here.)

The problem with your current approach is that Git seemingly says
nothing about how the index-as-a-regular-file behaves in which case
so it's free to change even in point releases.  I mean, I'd try to
avoid such dependancy at all costs until absolutely necessary.

BTW recently someone popped on the main Git list asking about the
current state of affairs in speeding up certain Git operations, and
one of the concepts which were discussed along the way was "split
index".  While I don't know the details it might mean making the Git
index hierarchical -- where some parts of its information are kept in
files, say, adjacent to the main one or whatever.

You received this message because you are subscribed to the Google Groups "Git 
for human beings" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to git-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to