chiark / gitweb /
Unwanted dep removal search - difficulties
[topbloke.git] / DESIGN
diff --git a/DESIGN b/DESIGN
index 09cea32e66551b45d24848671b94e2251662db94..1569517b0634542925d0ed6b76b05529099e4761 100644 (file)
--- a/DESIGN
+++ b/DESIGN
@@ -22,7 +22,7 @@ Basic update algorithm:
 
        Find the (latest) common ancestor.
 
-       Check for unwanted dependency removals.  
+       Check for unwanted dependency removals.
        An unwanted dependency removal is
           A branch in the desired included deps
           Which exists in the common ancestor's actual included deps
@@ -112,7 +112,7 @@ Basic update algorithm:
 The "best order" for merges is in order of recency of common
 ancestor, most recent first, and if that does not distinguish,
 merging from local branches first.
-     
+
 "Recency" refers to the order from git-rev-list --date-order.
 
 Actual included deps:
@@ -225,7 +225,7 @@ OK so here is a plan:
   Check for merge success in the index and compare to exit status
   from git-merge (which is 1 if the merge failed).
   Adjust the metadata.
-  Print appropriate big fat warnings if we have merge conflicts in our 
+  Print appropriate big fat warnings if we have merge conflicts in our
   metadata.
   Commit, adjusting the parents of the new commit to the original
   parents if we made the merge with special massaged parents.
@@ -259,21 +259,62 @@ Unwanted removal search subgraphs:
 inc  inc..
 /  ???   \
 
-   rm          
+    rm
 inc..  rm..    merge of a removal, search down the rm path
 /  [inc]  \
 
   inc          ??? call it an inclusion, terminate the search
   rm
 
-  inc          merge of an inclusion, terminates search
+   inc         merge of an inclusion, terminates search
 inc..  rm..
 /  [rm]  \
 
-  inc          ??? call it an inclusion, terminate search
+   inc         ??? call it an inclusion, terminate search
 rm..  rm..
 /  ???    \
-  
+
 
   rm   inc       inc          rm       irrelevant
   rm   inc     inc inc..    rm rm..
+
+
+
+                                       proposed                       (elsewhere)
+                              /          \                        |   |
+                            /            \                |   |
+                            /              |                      |   |
+                  REMOVAL rm              |               |   |
+                          |               |               |   |
+                        inc               |               |   |
+                                / |               |               |   |
+                       /  inc             |               |   |
+                      |   | `------------ | ----<-------- | -.|
+                             inc  inc             |               |   *2
+                      |`- | ------------- | ----<--------.|   |
+                      `---inc             |              1*  /
+                          |               |               | /
+               RE-INCLUDE inc             rm REMOVAL      |'
+               \          |              /                |
+                * REMOVAL rm            /                 |
+                                  |           inc                 |
+                          inc         /                   |
+                          |          /                    |
+                          inc       /                     |
+                          |        /`--------<-----------.|
+                          inc     /                       |
+                          |      /                        |
+               RE-INCLUDE inc   /                         |
+                       \          |    /                          |
+                * REMOVAL rm  /                           |
+                           |  /                                   |
+                           inc                                    |
+                             \                            |
+                              `------------<-------------.|
+                                                          |
+                                                          |
+                                                         IT
+
+
+  Merge 1* and 2*, diff against some relevant base branch commit
+  or something, and apply to proposed.