Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
| Comment: | Emit diagnostic messages after the file operations have been done, not before. |
|---|---|
| Downloads: | Tarball | ZIP archive |
| Timelines: | family | ancestors | descendants | both | mvAndRmFiles |
| Files: | files | file ages | folders |
| SHA1: |
1dad8acaa2d44f2255cb754f8c1f5020 |
| User & Date: | mistachkin 2015-02-05 04:35:52.522 |
Context
|
2015-02-05
| ||
| 04:50 | Add help text for the new settings. ... (check-in: 6048a961a7 user: mistachkin tags: mvAndRmFiles) | |
| 04:35 | Emit diagnostic messages after the file operations have been done, not before. ... (check-in: 1dad8acaa2 user: mistachkin tags: mvAndRmFiles) | |
| 03:55 | Minor adjustment to some SQL. ... (check-in: dfc3dfa59c user: mistachkin tags: mvAndRmFiles) | |
Changes
Changes to src/add.c.
| ︙ | ︙ | |||
350 351 352 353 354 355 356 |
static void process_files_to_remove(
int dryRunFlag /* Non-zero to actually operate on the file-system. */
){
Stmt remove;
db_prepare(&remove, "SELECT x FROM fremove ORDER BY x;");
while( db_step(&remove)==SQLITE_ROW ){
const char *zOldName = db_column_text(&remove, 0);
| < > | 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 |
static void process_files_to_remove(
int dryRunFlag /* Non-zero to actually operate on the file-system. */
){
Stmt remove;
db_prepare(&remove, "SELECT x FROM fremove ORDER BY x;");
while( db_step(&remove)==SQLITE_ROW ){
const char *zOldName = db_column_text(&remove, 0);
if( !dryRunFlag ){
file_delete(zOldName);
}
fossil_print("REMOVED %s\n", zOldName);
}
db_finalize(&remove);
db_multi_exec("DROP TABLE fremove;");
}
/*
** COMMAND: rm
|
| ︙ | ︙ | |||
680 681 682 683 684 685 686 |
int dryRunFlag /* Non-zero to actually operate on the file-system. */
){
Stmt move;
db_prepare(&move, "SELECT x, y FROM fmove ORDER BY x;");
while( db_step(&move)==SQLITE_ROW ){
const char *zOldName = db_column_text(&move, 0);
const char *zNewName = db_column_text(&move, 1);
| < > | 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 |
int dryRunFlag /* Non-zero to actually operate on the file-system. */
){
Stmt move;
db_prepare(&move, "SELECT x, y FROM fmove ORDER BY x;");
while( db_step(&move)==SQLITE_ROW ){
const char *zOldName = db_column_text(&move, 0);
const char *zNewName = db_column_text(&move, 1);
if( !dryRunFlag ){
if( file_wd_islink(zOldName) ){
symlink_copy(zOldName, zNewName);
}else{
file_copy(zOldName, zNewName);
}
file_delete(zOldName);
}
fossil_print("MOVED %s %s\n", zOldName, zNewName);
}
db_finalize(&move);
db_multi_exec("DROP TABLE fmove;");
}
/*
** COMMAND: mv
|
| ︙ | ︙ |