Fossil SCM
Reverse the logic of the "--brief|-b" flag of the finfo command so it fits with the flag name. (no functional change)
Commit
b8e378bcf85ae181aba685004c671d46556edb07452247de849c7442e91a8235
Parent
e897da20a083d12…
1 file changed
+3
-3
+3
-3
| --- src/finfo.c | ||
| +++ src/finfo.c | ||
| @@ -185,11 +185,11 @@ | ||
| 185 | 185 | zLimit = find_option("limit","n",1); |
| 186 | 186 | zWidth = find_option("width","W",1); |
| 187 | 187 | iLimit = zLimit ? atoi(zLimit) : -1; |
| 188 | 188 | zOffset = find_option("offset",0,1); |
| 189 | 189 | iOffset = zOffset ? atoi(zOffset) : 0; |
| 190 | - iBrief = (find_option("brief","b",0) == 0); | |
| 190 | + iBrief = find_option("brief","b",0) != 0; | |
| 191 | 191 | if( iLimit==0 ){ |
| 192 | 192 | iLimit = -1; |
| 193 | 193 | } |
| 194 | 194 | if( zWidth ){ |
| 195 | 195 | iWidth = atoi(zWidth); |
| @@ -228,11 +228,11 @@ | ||
| 228 | 228 | " ORDER BY event.mtime DESC LIMIT %d OFFSET %d", |
| 229 | 229 | TAG_BRANCH, zFilename, filename_collation(), |
| 230 | 230 | iLimit, iOffset |
| 231 | 231 | ); |
| 232 | 232 | blob_zero(&line); |
| 233 | - if( iBrief ){ | |
| 233 | + if( iBrief == 0 ){ | |
| 234 | 234 | fossil_print("History for %s\n", blob_str(&fname)); |
| 235 | 235 | } |
| 236 | 236 | while( db_step(&q)==SQLITE_ROW ){ |
| 237 | 237 | const char *zFileUuid = db_column_text(&q, 0); |
| 238 | 238 | const char *zCiUuid = db_column_text(&q,1); |
| @@ -240,11 +240,11 @@ | ||
| 240 | 240 | const char *zCom = db_column_text(&q, 3); |
| 241 | 241 | const char *zUser = db_column_text(&q, 4); |
| 242 | 242 | const char *zBr = db_column_text(&q, 5); |
| 243 | 243 | char *zOut; |
| 244 | 244 | if( zBr==0 ) zBr = "trunk"; |
| 245 | - if( iBrief ){ | |
| 245 | + if( iBrief == 0 ){ | |
| 246 | 246 | fossil_print("%s ", zDate); |
| 247 | 247 | zOut = mprintf( |
| 248 | 248 | "[%S] %s (user: %s, artifact: [%S], branch: %s)", |
| 249 | 249 | zCiUuid, zCom, zUser, zFileUuid, zBr); |
| 250 | 250 | comment_print(zOut, zCom, 11, iWidth, get_comment_format()); |
| 251 | 251 |
| --- src/finfo.c | |
| +++ src/finfo.c | |
| @@ -185,11 +185,11 @@ | |
| 185 | zLimit = find_option("limit","n",1); |
| 186 | zWidth = find_option("width","W",1); |
| 187 | iLimit = zLimit ? atoi(zLimit) : -1; |
| 188 | zOffset = find_option("offset",0,1); |
| 189 | iOffset = zOffset ? atoi(zOffset) : 0; |
| 190 | iBrief = (find_option("brief","b",0) == 0); |
| 191 | if( iLimit==0 ){ |
| 192 | iLimit = -1; |
| 193 | } |
| 194 | if( zWidth ){ |
| 195 | iWidth = atoi(zWidth); |
| @@ -228,11 +228,11 @@ | |
| 228 | " ORDER BY event.mtime DESC LIMIT %d OFFSET %d", |
| 229 | TAG_BRANCH, zFilename, filename_collation(), |
| 230 | iLimit, iOffset |
| 231 | ); |
| 232 | blob_zero(&line); |
| 233 | if( iBrief ){ |
| 234 | fossil_print("History for %s\n", blob_str(&fname)); |
| 235 | } |
| 236 | while( db_step(&q)==SQLITE_ROW ){ |
| 237 | const char *zFileUuid = db_column_text(&q, 0); |
| 238 | const char *zCiUuid = db_column_text(&q,1); |
| @@ -240,11 +240,11 @@ | |
| 240 | const char *zCom = db_column_text(&q, 3); |
| 241 | const char *zUser = db_column_text(&q, 4); |
| 242 | const char *zBr = db_column_text(&q, 5); |
| 243 | char *zOut; |
| 244 | if( zBr==0 ) zBr = "trunk"; |
| 245 | if( iBrief ){ |
| 246 | fossil_print("%s ", zDate); |
| 247 | zOut = mprintf( |
| 248 | "[%S] %s (user: %s, artifact: [%S], branch: %s)", |
| 249 | zCiUuid, zCom, zUser, zFileUuid, zBr); |
| 250 | comment_print(zOut, zCom, 11, iWidth, get_comment_format()); |
| 251 |
| --- src/finfo.c | |
| +++ src/finfo.c | |
| @@ -185,11 +185,11 @@ | |
| 185 | zLimit = find_option("limit","n",1); |
| 186 | zWidth = find_option("width","W",1); |
| 187 | iLimit = zLimit ? atoi(zLimit) : -1; |
| 188 | zOffset = find_option("offset",0,1); |
| 189 | iOffset = zOffset ? atoi(zOffset) : 0; |
| 190 | iBrief = find_option("brief","b",0) != 0; |
| 191 | if( iLimit==0 ){ |
| 192 | iLimit = -1; |
| 193 | } |
| 194 | if( zWidth ){ |
| 195 | iWidth = atoi(zWidth); |
| @@ -228,11 +228,11 @@ | |
| 228 | " ORDER BY event.mtime DESC LIMIT %d OFFSET %d", |
| 229 | TAG_BRANCH, zFilename, filename_collation(), |
| 230 | iLimit, iOffset |
| 231 | ); |
| 232 | blob_zero(&line); |
| 233 | if( iBrief == 0 ){ |
| 234 | fossil_print("History for %s\n", blob_str(&fname)); |
| 235 | } |
| 236 | while( db_step(&q)==SQLITE_ROW ){ |
| 237 | const char *zFileUuid = db_column_text(&q, 0); |
| 238 | const char *zCiUuid = db_column_text(&q,1); |
| @@ -240,11 +240,11 @@ | |
| 240 | const char *zCom = db_column_text(&q, 3); |
| 241 | const char *zUser = db_column_text(&q, 4); |
| 242 | const char *zBr = db_column_text(&q, 5); |
| 243 | char *zOut; |
| 244 | if( zBr==0 ) zBr = "trunk"; |
| 245 | if( iBrief == 0 ){ |
| 246 | fossil_print("%s ", zDate); |
| 247 | zOut = mprintf( |
| 248 | "[%S] %s (user: %s, artifact: [%S], branch: %s)", |
| 249 | zCiUuid, zCom, zUser, zFileUuid, zBr); |
| 250 | comment_print(zOut, zCom, 11, iWidth, get_comment_format()); |
| 251 |