Fossil SCM
Fix [8ee231223d]: fossil ls --age --verbose ignores --verbose
Commit
40d152478a1e34314b6c9e633c79bbbd8230ac43
Parent
f6ad6979d773794…
1 file changed
+23
-19
+23
-19
| --- src/checkin.c | ||
| +++ src/checkin.c | ||
| @@ -315,30 +315,34 @@ | ||
| 315 | 315 | int isDeleted = db_column_int(&q, 1); |
| 316 | 316 | int isNew = db_column_int(&q,2)==0; |
| 317 | 317 | int chnged = db_column_int(&q,3); |
| 318 | 318 | int renamed = db_column_int(&q,4); |
| 319 | 319 | char *zFullName = mprintf("%s%s", g.zLocalRoot, zPathname); |
| 320 | + const char *type = ""; | |
| 321 | + if( verboseFlag ){ | |
| 322 | + if( isNew ){ | |
| 323 | + type = "ADDED "; | |
| 324 | + }else if( isDeleted ){ | |
| 325 | + type = "DELETED "; | |
| 326 | + }else if( !file_wd_isfile_or_link(zFullName) ){ | |
| 327 | + if( file_access(zFullName, 0)==0 ){ | |
| 328 | + type = "NOT_A_FILE "; | |
| 329 | + }else{ | |
| 330 | + type = "MISSING "; | |
| 331 | + } | |
| 332 | + }else if( chnged ){ | |
| 333 | + type = "EDITED "; | |
| 334 | + }else if( renamed ){ | |
| 335 | + type = "RENAMED "; | |
| 336 | + }else{ | |
| 337 | + type = "UNCHANGED "; | |
| 338 | + } | |
| 339 | + } | |
| 320 | 340 | if( showAge ){ |
| 321 | - fossil_print("%s %s\n", db_column_text(&q, 5), zPathname); | |
| 322 | - }else if( !verboseFlag ){ | |
| 323 | - fossil_print("%s\n", zPathname); | |
| 324 | - }else if( isNew ){ | |
| 325 | - fossil_print("ADDED %s\n", zPathname); | |
| 326 | - }else if( isDeleted ){ | |
| 327 | - fossil_print("DELETED %s\n", zPathname); | |
| 328 | - }else if( !file_wd_isfile_or_link(zFullName) ){ | |
| 329 | - if( file_access(zFullName, 0)==0 ){ | |
| 330 | - fossil_print("NOT_A_FILE %s\n", zPathname); | |
| 331 | - }else{ | |
| 332 | - fossil_print("MISSING %s\n", zPathname); | |
| 333 | - } | |
| 334 | - }else if( chnged ){ | |
| 335 | - fossil_print("EDITED %s\n", zPathname); | |
| 336 | - }else if( renamed ){ | |
| 337 | - fossil_print("RENAMED %s\n", zPathname); | |
| 338 | - }else{ | |
| 339 | - fossil_print("UNCHANGED %s\n", zPathname); | |
| 341 | + fossil_print("%s%s %s\n", type, db_column_text(&q, 5), zPathname); | |
| 342 | + }else{ | |
| 343 | + fossil_print("%s%s\n", type, zPathname); | |
| 340 | 344 | } |
| 341 | 345 | free(zFullName); |
| 342 | 346 | } |
| 343 | 347 | db_finalize(&q); |
| 344 | 348 | } |
| 345 | 349 |
| --- src/checkin.c | |
| +++ src/checkin.c | |
| @@ -315,30 +315,34 @@ | |
| 315 | int isDeleted = db_column_int(&q, 1); |
| 316 | int isNew = db_column_int(&q,2)==0; |
| 317 | int chnged = db_column_int(&q,3); |
| 318 | int renamed = db_column_int(&q,4); |
| 319 | char *zFullName = mprintf("%s%s", g.zLocalRoot, zPathname); |
| 320 | if( showAge ){ |
| 321 | fossil_print("%s %s\n", db_column_text(&q, 5), zPathname); |
| 322 | }else if( !verboseFlag ){ |
| 323 | fossil_print("%s\n", zPathname); |
| 324 | }else if( isNew ){ |
| 325 | fossil_print("ADDED %s\n", zPathname); |
| 326 | }else if( isDeleted ){ |
| 327 | fossil_print("DELETED %s\n", zPathname); |
| 328 | }else if( !file_wd_isfile_or_link(zFullName) ){ |
| 329 | if( file_access(zFullName, 0)==0 ){ |
| 330 | fossil_print("NOT_A_FILE %s\n", zPathname); |
| 331 | }else{ |
| 332 | fossil_print("MISSING %s\n", zPathname); |
| 333 | } |
| 334 | }else if( chnged ){ |
| 335 | fossil_print("EDITED %s\n", zPathname); |
| 336 | }else if( renamed ){ |
| 337 | fossil_print("RENAMED %s\n", zPathname); |
| 338 | }else{ |
| 339 | fossil_print("UNCHANGED %s\n", zPathname); |
| 340 | } |
| 341 | free(zFullName); |
| 342 | } |
| 343 | db_finalize(&q); |
| 344 | } |
| 345 |
| --- src/checkin.c | |
| +++ src/checkin.c | |
| @@ -315,30 +315,34 @@ | |
| 315 | int isDeleted = db_column_int(&q, 1); |
| 316 | int isNew = db_column_int(&q,2)==0; |
| 317 | int chnged = db_column_int(&q,3); |
| 318 | int renamed = db_column_int(&q,4); |
| 319 | char *zFullName = mprintf("%s%s", g.zLocalRoot, zPathname); |
| 320 | const char *type = ""; |
| 321 | if( verboseFlag ){ |
| 322 | if( isNew ){ |
| 323 | type = "ADDED "; |
| 324 | }else if( isDeleted ){ |
| 325 | type = "DELETED "; |
| 326 | }else if( !file_wd_isfile_or_link(zFullName) ){ |
| 327 | if( file_access(zFullName, 0)==0 ){ |
| 328 | type = "NOT_A_FILE "; |
| 329 | }else{ |
| 330 | type = "MISSING "; |
| 331 | } |
| 332 | }else if( chnged ){ |
| 333 | type = "EDITED "; |
| 334 | }else if( renamed ){ |
| 335 | type = "RENAMED "; |
| 336 | }else{ |
| 337 | type = "UNCHANGED "; |
| 338 | } |
| 339 | } |
| 340 | if( showAge ){ |
| 341 | fossil_print("%s%s %s\n", type, db_column_text(&q, 5), zPathname); |
| 342 | }else{ |
| 343 | fossil_print("%s%s\n", type, zPathname); |
| 344 | } |
| 345 | free(zFullName); |
| 346 | } |
| 347 | db_finalize(&q); |
| 348 | } |
| 349 |