Fossil SCM
Add the "abd" (Avoid Branch Detours) query flag on /timeline. Better descriptions of the resulting timeline with the "min" query flag.
Commit
d82b52aac459a155d75f8ce378804faf8b7eb60f5e4fef455597964649041a4c
Parent
6c35335fb183420…
1 file changed
+5
-3
+5
-3
| --- src/timeline.c | ||
| +++ src/timeline.c | ||
| @@ -1605,10 +1605,12 @@ | ||
| 1605 | 1605 | ** from=CHECKIN Path through common ancestor from... |
| 1606 | 1606 | ** to=CHECKIN ... to this |
| 1607 | 1607 | ** to2=CHECKIN ... backup name if to= doesn't resolve |
| 1608 | 1608 | ** shortest ... show only the shortest path |
| 1609 | 1609 | ** rel ... also show related checkins |
| 1610 | +** min ... only show key nodes of the path | |
| 1611 | +** abd ... avoid branch detours | |
| 1610 | 1612 | ** bt=PRIOR ... path from CHECKIN back to PRIOR |
| 1611 | 1613 | ** ft=LATER ... path from CHECKIN forward to LATER |
| 1612 | 1614 | ** me=CHECKIN Most direct path from... |
| 1613 | 1615 | ** you=CHECKIN ... to this |
| 1614 | 1616 | ** rel ... also show related checkins |
| @@ -2073,11 +2075,11 @@ | ||
| 2073 | 2075 | const char *zTo = 0; |
| 2074 | 2076 | Blob ins; |
| 2075 | 2077 | int nNodeOnPath = 0; |
| 2076 | 2078 | int commonAncs = 0; /* Common ancestors of me_rid and you_rid. */ |
| 2077 | 2079 | int earlierRid = 0, laterRid = 0; |
| 2078 | - int cost = bMin ? 100 : 0; | |
| 2080 | + int cost = bMin || P("abd")!=0 ? 100 : 0; | |
| 2079 | 2081 | |
| 2080 | 2082 | if( from_rid && to_rid ){ |
| 2081 | 2083 | if( from_to_mode==0 ){ |
| 2082 | 2084 | p = path_shortest(from_rid, to_rid, noMerge, 0, 0, cost); |
| 2083 | 2085 | }else if( from_to_mode==1 ){ |
| @@ -2205,12 +2207,12 @@ | ||
| 2205 | 2207 | style_submenu_checkbox("v", "Files", (zType[0]!='a' && zType[0]!='c'),0); |
| 2206 | 2208 | } |
| 2207 | 2209 | nNodeOnPath = db_int(0, "SELECT count(*) FROM temp.pathnode"); |
| 2208 | 2210 | if( nNodeOnPath==1 && from_to_mode>0 ){ |
| 2209 | 2211 | blob_appendf(&desc,"Check-in "); |
| 2210 | - }else if( from_to_mode>0 ){ | |
| 2211 | - blob_appendf(&desc, "%d check-ins on the shorted path from ",nNodeOnPath); | |
| 2212 | + }else if( bMin ){ | |
| 2213 | + blob_appendf(&desc, "%d check-ins along the path from ", nNodeOnPath); | |
| 2212 | 2214 | }else{ |
| 2213 | 2215 | blob_appendf(&desc, "%d check-ins going from ", nNodeOnPath); |
| 2214 | 2216 | } |
| 2215 | 2217 | if( from_rid==selectedRid ){ |
| 2216 | 2218 | blob_appendf(&desc, "<span class='timelineSelected'>"); |
| 2217 | 2219 |
| --- src/timeline.c | |
| +++ src/timeline.c | |
| @@ -1605,10 +1605,12 @@ | |
| 1605 | ** from=CHECKIN Path through common ancestor from... |
| 1606 | ** to=CHECKIN ... to this |
| 1607 | ** to2=CHECKIN ... backup name if to= doesn't resolve |
| 1608 | ** shortest ... show only the shortest path |
| 1609 | ** rel ... also show related checkins |
| 1610 | ** bt=PRIOR ... path from CHECKIN back to PRIOR |
| 1611 | ** ft=LATER ... path from CHECKIN forward to LATER |
| 1612 | ** me=CHECKIN Most direct path from... |
| 1613 | ** you=CHECKIN ... to this |
| 1614 | ** rel ... also show related checkins |
| @@ -2073,11 +2075,11 @@ | |
| 2073 | const char *zTo = 0; |
| 2074 | Blob ins; |
| 2075 | int nNodeOnPath = 0; |
| 2076 | int commonAncs = 0; /* Common ancestors of me_rid and you_rid. */ |
| 2077 | int earlierRid = 0, laterRid = 0; |
| 2078 | int cost = bMin ? 100 : 0; |
| 2079 | |
| 2080 | if( from_rid && to_rid ){ |
| 2081 | if( from_to_mode==0 ){ |
| 2082 | p = path_shortest(from_rid, to_rid, noMerge, 0, 0, cost); |
| 2083 | }else if( from_to_mode==1 ){ |
| @@ -2205,12 +2207,12 @@ | |
| 2205 | style_submenu_checkbox("v", "Files", (zType[0]!='a' && zType[0]!='c'),0); |
| 2206 | } |
| 2207 | nNodeOnPath = db_int(0, "SELECT count(*) FROM temp.pathnode"); |
| 2208 | if( nNodeOnPath==1 && from_to_mode>0 ){ |
| 2209 | blob_appendf(&desc,"Check-in "); |
| 2210 | }else if( from_to_mode>0 ){ |
| 2211 | blob_appendf(&desc, "%d check-ins on the shorted path from ",nNodeOnPath); |
| 2212 | }else{ |
| 2213 | blob_appendf(&desc, "%d check-ins going from ", nNodeOnPath); |
| 2214 | } |
| 2215 | if( from_rid==selectedRid ){ |
| 2216 | blob_appendf(&desc, "<span class='timelineSelected'>"); |
| 2217 |
| --- src/timeline.c | |
| +++ src/timeline.c | |
| @@ -1605,10 +1605,12 @@ | |
| 1605 | ** from=CHECKIN Path through common ancestor from... |
| 1606 | ** to=CHECKIN ... to this |
| 1607 | ** to2=CHECKIN ... backup name if to= doesn't resolve |
| 1608 | ** shortest ... show only the shortest path |
| 1609 | ** rel ... also show related checkins |
| 1610 | ** min ... only show key nodes of the path |
| 1611 | ** abd ... avoid branch detours |
| 1612 | ** bt=PRIOR ... path from CHECKIN back to PRIOR |
| 1613 | ** ft=LATER ... path from CHECKIN forward to LATER |
| 1614 | ** me=CHECKIN Most direct path from... |
| 1615 | ** you=CHECKIN ... to this |
| 1616 | ** rel ... also show related checkins |
| @@ -2073,11 +2075,11 @@ | |
| 2075 | const char *zTo = 0; |
| 2076 | Blob ins; |
| 2077 | int nNodeOnPath = 0; |
| 2078 | int commonAncs = 0; /* Common ancestors of me_rid and you_rid. */ |
| 2079 | int earlierRid = 0, laterRid = 0; |
| 2080 | int cost = bMin || P("abd")!=0 ? 100 : 0; |
| 2081 | |
| 2082 | if( from_rid && to_rid ){ |
| 2083 | if( from_to_mode==0 ){ |
| 2084 | p = path_shortest(from_rid, to_rid, noMerge, 0, 0, cost); |
| 2085 | }else if( from_to_mode==1 ){ |
| @@ -2205,12 +2207,12 @@ | |
| 2207 | style_submenu_checkbox("v", "Files", (zType[0]!='a' && zType[0]!='c'),0); |
| 2208 | } |
| 2209 | nNodeOnPath = db_int(0, "SELECT count(*) FROM temp.pathnode"); |
| 2210 | if( nNodeOnPath==1 && from_to_mode>0 ){ |
| 2211 | blob_appendf(&desc,"Check-in "); |
| 2212 | }else if( bMin ){ |
| 2213 | blob_appendf(&desc, "%d check-ins along the path from ", nNodeOnPath); |
| 2214 | }else{ |
| 2215 | blob_appendf(&desc, "%d check-ins going from ", nNodeOnPath); |
| 2216 | } |
| 2217 | if( from_rid==selectedRid ){ |
| 2218 | blob_appendf(&desc, "<span class='timelineSelected'>"); |
| 2219 |