Git development
 help / color / mirror / Atom feed
* Some ASCII Art
@ 2005-10-06 18:05 Jon Loeliger
  2005-10-06 20:38 ` Junio C Hamano
  0 siblings, 1 reply; 4+ messages in thread
From: Jon Loeliger @ 2005-10-06 18:05 UTC (permalink / raw)
  To: Git List

Guys,

I tend to be a visual learner.  So I made up some ASCII
art and annotated it with some Git operations and stuff.

First, I'd love to have any feedback on these drawings,
especially if it actually misrepresents things.  If there
are obvious additions to these, that'd be nice to know too.

Second, if you think they are generally useful, please
feel free to add them to whatever documentation seems
appropriate.  (If you want a patch to a certain file
and a Sign-Off, let me know!)

Thanks,
jdl


Fundamental Git Index Operations
================================

                    +-----------+
                    | Object DB |
                    |  Backing  |
                    |   Store   |
                    +-----------+
                       ^
           write-tree  |     |
             tree obj  |     |
                       |     |  read-tree
                       |     |  tree obj
                             V
                    +-----------+
                    |   Index   |
                    |  "cache"  |
                    +-----------+
                       ^
         update-index  |     |
             blob obj  |     |
                       |     |  checkout-index
                       |     |  blob obj
                             V
                    +-----------+
                    |  Working  |
                    | Directory |
                    +-----------+


Git Index Operations
====================


                    +-----------+
                    | Object DB |
                    |  Backing  |
                    |   Store   | -----------+
                    +-----------+            |
                       ^                     |
          commit-tree  |     |               |
           commit obj  |     | read-tree -m  |
                       |     | tree obj      |
                       |     |               |
                             V               |
                    +-----------+            |
                    |   Index   | <- - - - - +
                    |  "cache"  | - - - - - >+
                    +-----------+            |
                       ^                     |
                       |                     |
         update-index  |     read-tree -m -u |
             blob obj  |            tree obj |
                       |                     |
                                             |
                    +-----------+            |
                    |  Working  |<-----------+
                    | Directory |
                    +-----------+



Git Diff Types
==============


                      diff-tree

                       +----+
                       |    |
                       |    |
                       V    V
                    +-----------+
                    | Object DB |
                    |  Backing  |
                    |   Store   |
                    +-----------+
                      ^    ^
                      |    |
                      |    |  diff-index --cached
                      |    |
          diff-index  |    V
                      |  +-----------+
                      |  |   Index   |
                      |  |  "cache"  |
                      |  +-----------+
                      |    ^
                      |    |
                      |    |  diff-files
                      |    |
                      V    V
                    +-----------+
                    |  Working  |
                    | Directory |
                    +-----------+


Commit DAG Revision Naming
==========================

Both node B and C are a commit parents of node A.

    G   H   I   J
     \ /     \ /
      D   E   F
       \  |  /
        \ | /
         \|/
          B     C
           \   /
            \ /
             A


    A = rev    = rev^0
    B = rev^   = rev^1     = rev~1
    D = rev^^  = rev^1^1   = rev~2
    G = rev^^^ = rev^1^1^1 = rev~3

Is there a way to name node C, E, F, H, I or J?
Is A also called rev~0?

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

end of thread, other threads:[~2005-10-07 19:42 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-10-06 18:05 Some ASCII Art Jon Loeliger
2005-10-06 20:38 ` Junio C Hamano
2005-10-07 19:35   ` Jon Loeliger
2005-10-07 19:42     ` Junio C Hamano

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox