Fossil SCM

Recursive rm doesn't work

Closed

538d51575deedc8… · opened 15 years, 8 months ago

Type
Code_Defect
Priority
Severity
Important
Resolution
Overcome_By_Events
Subsystem
Created
Aug. 11, 2010 1:03 a.m.

Deletes done on a subdirectory don't make it into the commit set.

mike /Users/mike/temp/11/db-4.2.52 $ fossil status
repository:   /Users/mike/temp/11/x
local-root:   /Users/mike/temp/11/
server-code:  91fc8a118b8bdbc657cde65291f00826ada2e4d2
checkout:     398f524c8fdc5ee7ddcb5667f714fc773431dc0e 2010-08-11 00:24:39 UTC
parent:       e8e391df27dc580a3cdcfe43823d709258053400 2010-08-11 00:19:33 UTC
tags:         trunk
mike /Users/mike/temp/11/db-4.2.52 $ fossil rm xa
DELETED  xa/tags
DELETED  xa/xa.c
DELETED  xa/xa_db.c
DELETED  xa/xa_map.c
mike /Users/mike/temp/11/db-4.2.52 $ fossil status
repository:   /Users/mike/temp/11/x
local-root:   /Users/mike/temp/11/
server-code:  91fc8a118b8bdbc657cde65291f00826ada2e4d2
checkout:     398f524c8fdc5ee7ddcb5667f714fc773431dc0e 2010-08-11 00:24:39 UTC
parent:       e8e391df27dc580a3cdcfe43823d709258053400 2010-08-11 00:19:33 UTC
tags:         trunk
mike /Users/mike/temp/11/db-4.2.52 $ fossil commit -m "test"
fossil: nothing has changed

Had I done fossil rm xa/* the delete is added to the commits correctly. Suggested patch:

Index: src/add.c
===================================================================
--- src/add.c
+++ src/add.c
@@ -213,11 +213,11 @@
         if( !db_exists(
             "SELECT 1 FROM vfile WHERE pathname=%Q AND NOT deleted", zFilePath)
         ){
           printf("SKIPPED  %s\n", zPath);
         }else{
-          db_multi_exec("UPDATE vfile SET deleted=1 WHERE pathname=%Q", zPath);
+          db_multi_exec("UPDATE vfile SET deleted=1 WHERE pathname=%Q", zFilePath);
           printf("DELETED  %s\n", zPath);
         }
         blob_reset(&pathname;);
       }
       blob_resize(&path;, origSize);

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button