Fossil SCM
Bugfix. When I introduced the 'revisionbranchchildren' table to pass 2 I forgot to update pass 4 as well. Added code to drop the excluded revisons from this table as well, as either parent of branches, or branch child of some other revision.
Commit
2516f4a56d8381a746bfa0a1487fc6f74f16d0c9
Parent
341d96be210caf6…
1 file changed
+8
| --- tools/cvs2fossil/lib/c2f_pfiltersym.tcl | ||
| +++ tools/cvs2fossil/lib/c2f_pfiltersym.tcl | ||
| @@ -47,10 +47,11 @@ | ||
| 47 | 47 | state reading symbol |
| 48 | 48 | state reading blocker |
| 49 | 49 | state reading parent |
| 50 | 50 | state reading preferedparent |
| 51 | 51 | state reading revision |
| 52 | + state reading revisionbranchchildren | |
| 52 | 53 | state reading branch |
| 53 | 54 | state reading tag |
| 54 | 55 | |
| 55 | 56 | state writing noop { |
| 56 | 57 | id INTEGER NOT NULL PRIMARY KEY, -- tag/branch reference |
| @@ -194,16 +195,23 @@ | ||
| 194 | 195 | # excluded symbols in some way. This is easy as we do not have |
| 195 | 196 | # to select them again and again from the base tables any |
| 196 | 197 | # longer. |
| 197 | 198 | |
| 198 | 199 | state run { |
| 200 | + CREATE TEMPORARY TABLE excludedrevisions AS | |
| 201 | + SELECT rid FROM revision WHERE lod IN excludedsymbols; | |
| 202 | + | |
| 199 | 203 | DELETE FROM revision WHERE lod IN excludedsymbols; |
| 200 | 204 | DELETE FROM tag WHERE lod IN excludedsymbols; |
| 201 | 205 | DELETE FROM tag WHERE sid IN excludedsymbols; |
| 202 | 206 | DELETE FROM branch WHERE lod IN excludedsymbols; |
| 203 | 207 | DELETE FROM branch WHERE sid IN excludedsymbols; |
| 204 | 208 | |
| 209 | + DELETE FROM revisionbranchchildren WHERE rid IN excludedrevisions; | |
| 210 | + DELETE FROM revisionbranchchildren WHERE brid IN excludedrevisions; | |
| 211 | + | |
| 212 | + DROP TABLE excludedrevisions; | |
| 205 | 213 | DROP TABLE excludedsymbols; |
| 206 | 214 | } |
| 207 | 215 | return |
| 208 | 216 | } |
| 209 | 217 | |
| 210 | 218 |
| --- tools/cvs2fossil/lib/c2f_pfiltersym.tcl | |
| +++ tools/cvs2fossil/lib/c2f_pfiltersym.tcl | |
| @@ -47,10 +47,11 @@ | |
| 47 | state reading symbol |
| 48 | state reading blocker |
| 49 | state reading parent |
| 50 | state reading preferedparent |
| 51 | state reading revision |
| 52 | state reading branch |
| 53 | state reading tag |
| 54 | |
| 55 | state writing noop { |
| 56 | id INTEGER NOT NULL PRIMARY KEY, -- tag/branch reference |
| @@ -194,16 +195,23 @@ | |
| 194 | # excluded symbols in some way. This is easy as we do not have |
| 195 | # to select them again and again from the base tables any |
| 196 | # longer. |
| 197 | |
| 198 | state run { |
| 199 | DELETE FROM revision WHERE lod IN excludedsymbols; |
| 200 | DELETE FROM tag WHERE lod IN excludedsymbols; |
| 201 | DELETE FROM tag WHERE sid IN excludedsymbols; |
| 202 | DELETE FROM branch WHERE lod IN excludedsymbols; |
| 203 | DELETE FROM branch WHERE sid IN excludedsymbols; |
| 204 | |
| 205 | DROP TABLE excludedsymbols; |
| 206 | } |
| 207 | return |
| 208 | } |
| 209 | |
| 210 |
| --- tools/cvs2fossil/lib/c2f_pfiltersym.tcl | |
| +++ tools/cvs2fossil/lib/c2f_pfiltersym.tcl | |
| @@ -47,10 +47,11 @@ | |
| 47 | state reading symbol |
| 48 | state reading blocker |
| 49 | state reading parent |
| 50 | state reading preferedparent |
| 51 | state reading revision |
| 52 | state reading revisionbranchchildren |
| 53 | state reading branch |
| 54 | state reading tag |
| 55 | |
| 56 | state writing noop { |
| 57 | id INTEGER NOT NULL PRIMARY KEY, -- tag/branch reference |
| @@ -194,16 +195,23 @@ | |
| 195 | # excluded symbols in some way. This is easy as we do not have |
| 196 | # to select them again and again from the base tables any |
| 197 | # longer. |
| 198 | |
| 199 | state run { |
| 200 | CREATE TEMPORARY TABLE excludedrevisions AS |
| 201 | SELECT rid FROM revision WHERE lod IN excludedsymbols; |
| 202 | |
| 203 | DELETE FROM revision WHERE lod IN excludedsymbols; |
| 204 | DELETE FROM tag WHERE lod IN excludedsymbols; |
| 205 | DELETE FROM tag WHERE sid IN excludedsymbols; |
| 206 | DELETE FROM branch WHERE lod IN excludedsymbols; |
| 207 | DELETE FROM branch WHERE sid IN excludedsymbols; |
| 208 | |
| 209 | DELETE FROM revisionbranchchildren WHERE rid IN excludedrevisions; |
| 210 | DELETE FROM revisionbranchchildren WHERE brid IN excludedrevisions; |
| 211 | |
| 212 | DROP TABLE excludedrevisions; |
| 213 | DROP TABLE excludedsymbols; |
| 214 | } |
| 215 | return |
| 216 | } |
| 217 | |
| 218 |