Fossil SCM
Break up the command-line commands into commonly-use and auxiliary commands and only show the commonly-used ones with "fossil help". Add a new command "fossil commands" to show auxiliary and test commands.
Commit
841772c858ac63a8a284f24111239ba485a2f3b5
Parent
d084043f7982777…
18 files changed
+2
-2
+1
-1
+3
-3
+1
-1
+1
-1
+2
-2
+2
-2
+45
-27
+29
-7
+4
-4
+1
-1
+1
-1
+1
-1
+1
-1
+1
-1
+1
-1
+1
-1
+1
-1
+2
-2
| --- src/add.c | ||
| +++ src/add.c | ||
| @@ -260,11 +260,11 @@ | ||
| 260 | 260 | db_end_transaction(0); |
| 261 | 261 | } |
| 262 | 262 | |
| 263 | 263 | /* |
| 264 | 264 | ** COMMAND: rm |
| 265 | -** COMMAND: delete | |
| 265 | +** COMMAND: delete* | |
| 266 | 266 | ** |
| 267 | 267 | ** Usage: %fossil rm FILE1 ?FILE2 ...? |
| 268 | 268 | ** or: %fossil delete FILE1 ?FILE2 ...? |
| 269 | 269 | ** |
| 270 | 270 | ** Remove one or more files or directories from the repository. |
| @@ -473,11 +473,11 @@ | ||
| 473 | 473 | ); |
| 474 | 474 | } |
| 475 | 475 | |
| 476 | 476 | /* |
| 477 | 477 | ** COMMAND: mv |
| 478 | -** COMMAND: rename | |
| 478 | +** COMMAND: rename* | |
| 479 | 479 | ** |
| 480 | 480 | ** Usage: %fossil mv|rename OLDNAME NEWNAME |
| 481 | 481 | ** or: %fossil mv|rename OLDNAME... DIR |
| 482 | 482 | ** |
| 483 | 483 | ** Move or rename one or more files or directories within the repository tree. |
| 484 | 484 |
| --- src/add.c | |
| +++ src/add.c | |
| @@ -260,11 +260,11 @@ | |
| 260 | db_end_transaction(0); |
| 261 | } |
| 262 | |
| 263 | /* |
| 264 | ** COMMAND: rm |
| 265 | ** COMMAND: delete |
| 266 | ** |
| 267 | ** Usage: %fossil rm FILE1 ?FILE2 ...? |
| 268 | ** or: %fossil delete FILE1 ?FILE2 ...? |
| 269 | ** |
| 270 | ** Remove one or more files or directories from the repository. |
| @@ -473,11 +473,11 @@ | |
| 473 | ); |
| 474 | } |
| 475 | |
| 476 | /* |
| 477 | ** COMMAND: mv |
| 478 | ** COMMAND: rename |
| 479 | ** |
| 480 | ** Usage: %fossil mv|rename OLDNAME NEWNAME |
| 481 | ** or: %fossil mv|rename OLDNAME... DIR |
| 482 | ** |
| 483 | ** Move or rename one or more files or directories within the repository tree. |
| 484 |
| --- src/add.c | |
| +++ src/add.c | |
| @@ -260,11 +260,11 @@ | |
| 260 | db_end_transaction(0); |
| 261 | } |
| 262 | |
| 263 | /* |
| 264 | ** COMMAND: rm |
| 265 | ** COMMAND: delete* |
| 266 | ** |
| 267 | ** Usage: %fossil rm FILE1 ?FILE2 ...? |
| 268 | ** or: %fossil delete FILE1 ?FILE2 ...? |
| 269 | ** |
| 270 | ** Remove one or more files or directories from the repository. |
| @@ -473,11 +473,11 @@ | |
| 473 | ); |
| 474 | } |
| 475 | |
| 476 | /* |
| 477 | ** COMMAND: mv |
| 478 | ** COMMAND: rename* |
| 479 | ** |
| 480 | ** Usage: %fossil mv|rename OLDNAME NEWNAME |
| 481 | ** or: %fossil mv|rename OLDNAME... DIR |
| 482 | ** |
| 483 | ** Move or rename one or more files or directories within the repository tree. |
| 484 |
+1
-1
| --- src/checkin.c | ||
| +++ src/checkin.c | ||
| @@ -825,11 +825,11 @@ | ||
| 825 | 825 | blob_reset(&fname); |
| 826 | 826 | } |
| 827 | 827 | } |
| 828 | 828 | |
| 829 | 829 | /* |
| 830 | -** COMMAND: ci | |
| 830 | +** COMMAND: ci* | |
| 831 | 831 | ** COMMAND: commit |
| 832 | 832 | ** |
| 833 | 833 | ** Usage: %fossil commit ?OPTIONS? ?FILE...? |
| 834 | 834 | ** |
| 835 | 835 | ** Create a new version containing all of the changes in the current |
| 836 | 836 |
| --- src/checkin.c | |
| +++ src/checkin.c | |
| @@ -825,11 +825,11 @@ | |
| 825 | blob_reset(&fname); |
| 826 | } |
| 827 | } |
| 828 | |
| 829 | /* |
| 830 | ** COMMAND: ci |
| 831 | ** COMMAND: commit |
| 832 | ** |
| 833 | ** Usage: %fossil commit ?OPTIONS? ?FILE...? |
| 834 | ** |
| 835 | ** Create a new version containing all of the changes in the current |
| 836 |
| --- src/checkin.c | |
| +++ src/checkin.c | |
| @@ -825,11 +825,11 @@ | |
| 825 | blob_reset(&fname); |
| 826 | } |
| 827 | } |
| 828 | |
| 829 | /* |
| 830 | ** COMMAND: ci* |
| 831 | ** COMMAND: commit |
| 832 | ** |
| 833 | ** Usage: %fossil commit ?OPTIONS? ?FILE...? |
| 834 | ** |
| 835 | ** Create a new version containing all of the changes in the current |
| 836 |
+3
-3
| --- src/checkout.c | ||
| +++ src/checkout.c | ||
| @@ -161,12 +161,12 @@ | ||
| 161 | 161 | } |
| 162 | 162 | |
| 163 | 163 | } |
| 164 | 164 | |
| 165 | 165 | /* |
| 166 | -** COMMAND: checkout | |
| 167 | -** COMMAND: co | |
| 166 | +** COMMAND: checkout* | |
| 167 | +** COMMAND: co* | |
| 168 | 168 | ** |
| 169 | 169 | ** Usage: %fossil checkout ?VERSION | --latest? ?OPTIONS? |
| 170 | 170 | ** or: %fossil co ?VERSION | --latest? ?OPTIONS? |
| 171 | 171 | ** |
| 172 | 172 | ** Check out a version specified on the command-line. This command |
| @@ -272,11 +272,11 @@ | ||
| 272 | 272 | } |
| 273 | 273 | } |
| 274 | 274 | } |
| 275 | 275 | |
| 276 | 276 | /* |
| 277 | -** COMMAND: close | |
| 277 | +** COMMAND: close* | |
| 278 | 278 | ** |
| 279 | 279 | ** Usage: %fossil close ?OPTIONS? |
| 280 | 280 | ** |
| 281 | 281 | ** The opposite of "open". Close the current database connection. |
| 282 | 282 | ** Require a -f or --force flag if there are unsaved changed in the |
| 283 | 283 |
| --- src/checkout.c | |
| +++ src/checkout.c | |
| @@ -161,12 +161,12 @@ | |
| 161 | } |
| 162 | |
| 163 | } |
| 164 | |
| 165 | /* |
| 166 | ** COMMAND: checkout |
| 167 | ** COMMAND: co |
| 168 | ** |
| 169 | ** Usage: %fossil checkout ?VERSION | --latest? ?OPTIONS? |
| 170 | ** or: %fossil co ?VERSION | --latest? ?OPTIONS? |
| 171 | ** |
| 172 | ** Check out a version specified on the command-line. This command |
| @@ -272,11 +272,11 @@ | |
| 272 | } |
| 273 | } |
| 274 | } |
| 275 | |
| 276 | /* |
| 277 | ** COMMAND: close |
| 278 | ** |
| 279 | ** Usage: %fossil close ?OPTIONS? |
| 280 | ** |
| 281 | ** The opposite of "open". Close the current database connection. |
| 282 | ** Require a -f or --force flag if there are unsaved changed in the |
| 283 |
| --- src/checkout.c | |
| +++ src/checkout.c | |
| @@ -161,12 +161,12 @@ | |
| 161 | } |
| 162 | |
| 163 | } |
| 164 | |
| 165 | /* |
| 166 | ** COMMAND: checkout* |
| 167 | ** COMMAND: co* |
| 168 | ** |
| 169 | ** Usage: %fossil checkout ?VERSION | --latest? ?OPTIONS? |
| 170 | ** or: %fossil co ?VERSION | --latest? ?OPTIONS? |
| 171 | ** |
| 172 | ** Check out a version specified on the command-line. This command |
| @@ -272,11 +272,11 @@ | |
| 272 | } |
| 273 | } |
| 274 | } |
| 275 | |
| 276 | /* |
| 277 | ** COMMAND: close* |
| 278 | ** |
| 279 | ** Usage: %fossil close ?OPTIONS? |
| 280 | ** |
| 281 | ** The opposite of "open". Close the current database connection. |
| 282 | ** Require a -f or --force flag if there are unsaved changed in the |
| 283 |
+1
-1
| --- src/configure.c | ||
| +++ src/configure.c | ||
| @@ -724,11 +724,11 @@ | ||
| 724 | 724 | blob_reset(&out); |
| 725 | 725 | } |
| 726 | 726 | |
| 727 | 727 | |
| 728 | 728 | /* |
| 729 | -** COMMAND: configuration | |
| 729 | +** COMMAND: configuration* | |
| 730 | 730 | ** |
| 731 | 731 | ** Usage: %fossil configuration METHOD ... ?OPTIONS? |
| 732 | 732 | ** |
| 733 | 733 | ** Where METHOD is one of: export import merge pull push reset. All methods |
| 734 | 734 | ** accept the -R or --repository option to specific a repository. |
| 735 | 735 |
| --- src/configure.c | |
| +++ src/configure.c | |
| @@ -724,11 +724,11 @@ | |
| 724 | blob_reset(&out); |
| 725 | } |
| 726 | |
| 727 | |
| 728 | /* |
| 729 | ** COMMAND: configuration |
| 730 | ** |
| 731 | ** Usage: %fossil configuration METHOD ... ?OPTIONS? |
| 732 | ** |
| 733 | ** Where METHOD is one of: export import merge pull push reset. All methods |
| 734 | ** accept the -R or --repository option to specific a repository. |
| 735 |
| --- src/configure.c | |
| +++ src/configure.c | |
| @@ -724,11 +724,11 @@ | |
| 724 | blob_reset(&out); |
| 725 | } |
| 726 | |
| 727 | |
| 728 | /* |
| 729 | ** COMMAND: configuration* |
| 730 | ** |
| 731 | ** Usage: %fossil configuration METHOD ... ?OPTIONS? |
| 732 | ** |
| 733 | ** Where METHOD is one of: export import merge pull push reset. All methods |
| 734 | ** accept the -R or --repository option to specific a repository. |
| 735 |
+1
-1
| --- src/content.c | ||
| +++ src/content.c | ||
| @@ -303,11 +303,11 @@ | ||
| 303 | 303 | } |
| 304 | 304 | return rc; |
| 305 | 305 | } |
| 306 | 306 | |
| 307 | 307 | /* |
| 308 | -** COMMAND: artifact | |
| 308 | +** COMMAND: artifact* | |
| 309 | 309 | ** |
| 310 | 310 | ** Usage: %fossil artifact ARTIFACT-ID ?OUTPUT-FILENAME? ?OPTIONS? |
| 311 | 311 | ** |
| 312 | 312 | ** Extract an artifact by its SHA1 hash and write the results on |
| 313 | 313 | ** standard output, or if the optional 4th argument is given, in |
| 314 | 314 |
| --- src/content.c | |
| +++ src/content.c | |
| @@ -303,11 +303,11 @@ | |
| 303 | } |
| 304 | return rc; |
| 305 | } |
| 306 | |
| 307 | /* |
| 308 | ** COMMAND: artifact |
| 309 | ** |
| 310 | ** Usage: %fossil artifact ARTIFACT-ID ?OUTPUT-FILENAME? ?OPTIONS? |
| 311 | ** |
| 312 | ** Extract an artifact by its SHA1 hash and write the results on |
| 313 | ** standard output, or if the optional 4th argument is given, in |
| 314 |
| --- src/content.c | |
| +++ src/content.c | |
| @@ -303,11 +303,11 @@ | |
| 303 | } |
| 304 | return rc; |
| 305 | } |
| 306 | |
| 307 | /* |
| 308 | ** COMMAND: artifact* |
| 309 | ** |
| 310 | ** Usage: %fossil artifact ARTIFACT-ID ?OUTPUT-FILENAME? ?OPTIONS? |
| 311 | ** |
| 312 | ** Extract an artifact by its SHA1 hash and write the results on |
| 313 | ** standard output, or if the optional 4th argument is given, in |
| 314 |
M
src/db.c
+2
-2
| --- src/db.c | ||
| +++ src/db.c | ||
| @@ -1164,11 +1164,11 @@ | ||
| 1164 | 1164 | manifest_crosslink(rid, &manifest); |
| 1165 | 1165 | } |
| 1166 | 1166 | } |
| 1167 | 1167 | |
| 1168 | 1168 | /* |
| 1169 | -** COMMAND: new | |
| 1169 | +** COMMAND: new* | |
| 1170 | 1170 | ** COMMAND: init |
| 1171 | 1171 | ** |
| 1172 | 1172 | ** Usage: %fossil new ?OPTIONS? FILENAME |
| 1173 | 1173 | ** Or: %fossil init ?OPTIONS? FILENAME |
| 1174 | 1174 | ** |
| @@ -1799,11 +1799,11 @@ | ||
| 1799 | 1799 | { 0,0,0,0,0 } |
| 1800 | 1800 | }; |
| 1801 | 1801 | |
| 1802 | 1802 | /* |
| 1803 | 1803 | ** COMMAND: settings |
| 1804 | -** COMMAND: unset | |
| 1804 | +** COMMAND: unset* | |
| 1805 | 1805 | ** |
| 1806 | 1806 | ** %fossil settings ?PROPERTY? ?VALUE? ?-global? |
| 1807 | 1807 | ** %fossil unset PROPERTY ?-global? |
| 1808 | 1808 | ** |
| 1809 | 1809 | ** The "settings" command with no arguments lists all properties and their |
| 1810 | 1810 |
| --- src/db.c | |
| +++ src/db.c | |
| @@ -1164,11 +1164,11 @@ | |
| 1164 | manifest_crosslink(rid, &manifest); |
| 1165 | } |
| 1166 | } |
| 1167 | |
| 1168 | /* |
| 1169 | ** COMMAND: new |
| 1170 | ** COMMAND: init |
| 1171 | ** |
| 1172 | ** Usage: %fossil new ?OPTIONS? FILENAME |
| 1173 | ** Or: %fossil init ?OPTIONS? FILENAME |
| 1174 | ** |
| @@ -1799,11 +1799,11 @@ | |
| 1799 | { 0,0,0,0,0 } |
| 1800 | }; |
| 1801 | |
| 1802 | /* |
| 1803 | ** COMMAND: settings |
| 1804 | ** COMMAND: unset |
| 1805 | ** |
| 1806 | ** %fossil settings ?PROPERTY? ?VALUE? ?-global? |
| 1807 | ** %fossil unset PROPERTY ?-global? |
| 1808 | ** |
| 1809 | ** The "settings" command with no arguments lists all properties and their |
| 1810 |
| --- src/db.c | |
| +++ src/db.c | |
| @@ -1164,11 +1164,11 @@ | |
| 1164 | manifest_crosslink(rid, &manifest); |
| 1165 | } |
| 1166 | } |
| 1167 | |
| 1168 | /* |
| 1169 | ** COMMAND: new* |
| 1170 | ** COMMAND: init |
| 1171 | ** |
| 1172 | ** Usage: %fossil new ?OPTIONS? FILENAME |
| 1173 | ** Or: %fossil init ?OPTIONS? FILENAME |
| 1174 | ** |
| @@ -1799,11 +1799,11 @@ | |
| 1799 | { 0,0,0,0,0 } |
| 1800 | }; |
| 1801 | |
| 1802 | /* |
| 1803 | ** COMMAND: settings |
| 1804 | ** COMMAND: unset* |
| 1805 | ** |
| 1806 | ** %fossil settings ?PROPERTY? ?VALUE? ?-global? |
| 1807 | ** %fossil unset PROPERTY ?-global? |
| 1808 | ** |
| 1809 | ** The "settings" command with no arguments lists all properties and their |
| 1810 |
+2
-2
| --- src/descendants.c | ||
| +++ src/descendants.c | ||
| @@ -263,11 +263,11 @@ | ||
| 263 | 263 | db_finalize(&ins); |
| 264 | 264 | db_finalize(&q); |
| 265 | 265 | } |
| 266 | 266 | |
| 267 | 267 | /* |
| 268 | -** COMMAND: descendants | |
| 268 | +** COMMAND: descendants* | |
| 269 | 269 | ** |
| 270 | 270 | ** Usage: %fossil descendants ?BASELINE-ID? ?OPTIONS? |
| 271 | 271 | ** |
| 272 | 272 | ** Find all leaf descendants of the baseline specified or if the argument |
| 273 | 273 | ** is omitted, of the baseline currently checked out. |
| @@ -298,11 +298,11 @@ | ||
| 298 | 298 | print_timeline(&q, 20, 0); |
| 299 | 299 | db_finalize(&q); |
| 300 | 300 | } |
| 301 | 301 | |
| 302 | 302 | /* |
| 303 | -** COMMAND: leaves | |
| 303 | +** COMMAND: leaves* | |
| 304 | 304 | ** |
| 305 | 305 | ** Usage: %fossil leaves ?OPTIONS? |
| 306 | 306 | ** |
| 307 | 307 | ** Find leaves of all branches. By default show only open leaves. |
| 308 | 308 | ** The --all flag causes all leaves (closed and open) to be shown. |
| 309 | 309 |
| --- src/descendants.c | |
| +++ src/descendants.c | |
| @@ -263,11 +263,11 @@ | |
| 263 | db_finalize(&ins); |
| 264 | db_finalize(&q); |
| 265 | } |
| 266 | |
| 267 | /* |
| 268 | ** COMMAND: descendants |
| 269 | ** |
| 270 | ** Usage: %fossil descendants ?BASELINE-ID? ?OPTIONS? |
| 271 | ** |
| 272 | ** Find all leaf descendants of the baseline specified or if the argument |
| 273 | ** is omitted, of the baseline currently checked out. |
| @@ -298,11 +298,11 @@ | |
| 298 | print_timeline(&q, 20, 0); |
| 299 | db_finalize(&q); |
| 300 | } |
| 301 | |
| 302 | /* |
| 303 | ** COMMAND: leaves |
| 304 | ** |
| 305 | ** Usage: %fossil leaves ?OPTIONS? |
| 306 | ** |
| 307 | ** Find leaves of all branches. By default show only open leaves. |
| 308 | ** The --all flag causes all leaves (closed and open) to be shown. |
| 309 |
| --- src/descendants.c | |
| +++ src/descendants.c | |
| @@ -263,11 +263,11 @@ | |
| 263 | db_finalize(&ins); |
| 264 | db_finalize(&q); |
| 265 | } |
| 266 | |
| 267 | /* |
| 268 | ** COMMAND: descendants* |
| 269 | ** |
| 270 | ** Usage: %fossil descendants ?BASELINE-ID? ?OPTIONS? |
| 271 | ** |
| 272 | ** Find all leaf descendants of the baseline specified or if the argument |
| 273 | ** is omitted, of the baseline currently checked out. |
| @@ -298,11 +298,11 @@ | |
| 298 | print_timeline(&q, 20, 0); |
| 299 | db_finalize(&q); |
| 300 | } |
| 301 | |
| 302 | /* |
| 303 | ** COMMAND: leaves* |
| 304 | ** |
| 305 | ** Usage: %fossil leaves ?OPTIONS? |
| 306 | ** |
| 307 | ** Find leaves of all branches. By default show only open leaves. |
| 308 | ** The --all flag causes all leaves (closed and open) to be shown. |
| 309 |
+45
-27
| --- src/main.c | ||
| +++ src/main.c | ||
| @@ -325,14 +325,17 @@ | ||
| 325 | 325 | argv = g.argv; |
| 326 | 326 | for(i=0; i<argc; i++) g.argv[i] = fossil_mbcs_to_utf8(argv[i]); |
| 327 | 327 | if( getenv("GATEWAY_INTERFACE")!=0 && !find_option("nocgi", 0, 0)){ |
| 328 | 328 | zCmdName = "cgi"; |
| 329 | 329 | }else if( argc<2 ){ |
| 330 | - fossil_fatal("Usage: %s COMMAND ...\n" | |
| 331 | - "\"%s help\" for a list of available commands\n" | |
| 332 | - "\"%s help COMMAND\" for specific details\n", | |
| 333 | - argv[0], argv[0], argv[0]); | |
| 330 | + fossil_print( | |
| 331 | + "Usage: %s COMMAND ...\n" | |
| 332 | + " or: %s help -- for a list of common commands\n" | |
| 333 | + " or: %s help COMMMAND -- for help with the named command\n" | |
| 334 | + " or: %s commands -- for a list of all commands\n", | |
| 335 | + argv[0], argv[0], argv[0], argv[0]); | |
| 336 | + fossil_exit(1); | |
| 334 | 337 | }else{ |
| 335 | 338 | g.fQuiet = find_option("quiet", 0, 0)!=0; |
| 336 | 339 | g.fSqlTrace = find_option("sqltrace", 0, 0)!=0; |
| 337 | 340 | g.fSqlStats = find_option("sqlstats", 0, 0)!=0; |
| 338 | 341 | g.fSystemTrace = find_option("systemtrace", 0, 0)!=0; |
| @@ -368,14 +371,15 @@ | ||
| 368 | 371 | for(i=0; i<count(aCommand); i++){ |
| 369 | 372 | if( memcmp(zCmdName, aCommand[i].zName, n)==0 ){ |
| 370 | 373 | blob_appendf(&couldbe, " %s", aCommand[i].zName); |
| 371 | 374 | } |
| 372 | 375 | } |
| 373 | - fossil_fatal("%s: ambiguous command prefix: %s\n" | |
| 376 | + fossil_print("%s: ambiguous command prefix: %s\n" | |
| 374 | 377 | "%s: could be any of:%s\n" |
| 375 | 378 | "%s: use \"help\" for more information\n", |
| 376 | 379 | argv[0], zCmdName, argv[0], blob_str(&couldbe), argv[0]); |
| 380 | + fossil_exit(1); | |
| 377 | 381 | } |
| 378 | 382 | aCommand[idx].xFunc(); |
| 379 | 383 | fossil_exit(0); |
| 380 | 384 | /*NOT_REACHED*/ |
| 381 | 385 | return 0; |
| @@ -693,38 +697,45 @@ | ||
| 693 | 697 | } |
| 694 | 698 | |
| 695 | 699 | /* |
| 696 | 700 | ** List of commands starting with zPrefix, or all commands if zPrefix is NULL. |
| 697 | 701 | */ |
| 698 | -static void cmd_cmd_list(const char *zPrefix){ | |
| 702 | +static void command_list(const char *zPrefix, int cmdMask){ | |
| 699 | 703 | int i, nCmd; |
| 700 | 704 | int nPrefix = zPrefix ? strlen(zPrefix) : 0; |
| 701 | 705 | const char *aCmd[count(aCommand)]; |
| 702 | 706 | for(i=nCmd=0; i<count(aCommand); i++){ |
| 703 | 707 | const char *z = aCommand[i].zName; |
| 704 | - if( memcmp(z,"test",4)==0 ) continue; | |
| 708 | + if( (aCommand[i].cmdFlags & cmdMask)==0 ) continue; | |
| 705 | 709 | if( zPrefix && memcmp(zPrefix, z, nPrefix)!=0 ) continue; |
| 706 | 710 | aCmd[nCmd++] = aCommand[i].zName; |
| 707 | 711 | } |
| 708 | 712 | multi_column_list(aCmd, nCmd); |
| 709 | 713 | } |
| 710 | 714 | |
| 711 | 715 | /* |
| 712 | -** COMMAND: test-commands | |
| 716 | +** COMMAND: commands | |
| 713 | 717 | ** |
| 714 | -** Usage: %fossil test-commands | |
| 718 | +** Usage: %fossil commands ?--test? ?--all? ?--aux? | |
| 715 | 719 | ** |
| 716 | -** List all commands used for testing and debugging. | |
| 720 | +** List available commands. If the --test option is used list only unsupported | |
| 721 | +** commands intended for testing and debugging. With --all, show all commands | |
| 722 | +** including test debugging commands. With --aux, show only the auxiliary | |
| 723 | +** and less often used commands, and/or command aliases. | |
| 717 | 724 | */ |
| 718 | -void cmd_test_cmd_list(void){ | |
| 719 | - int i, nCmd; | |
| 720 | - const char *aCmd[count(aCommand)]; | |
| 721 | - for(i=nCmd=0; i<count(aCommand); i++){ | |
| 722 | - if( strncmp(aCommand[i].zName,"test",4)!=0 ) continue; | |
| 723 | - aCmd[nCmd++] = aCommand[i].zName; | |
| 724 | - } | |
| 725 | - multi_column_list(aCmd, nCmd); | |
| 725 | +void cmd_command_list(void){ | |
| 726 | + int cmdFlags = CMDFLAG_1ST_TIER | CMDFLAG_2ND_TIER; | |
| 727 | + if( find_option("all",0,0)!=0 ){ | |
| 728 | + cmdFlags |= CMDFLAG_TEST; | |
| 729 | + }else if( find_option("test",0,0)!=0 ){ | |
| 730 | + cmdFlags = CMDFLAG_TEST; | |
| 731 | + }else if( find_option("aux",0,0)!=0 ){ | |
| 732 | + cmdFlags = CMDFLAG_2ND_TIER; | |
| 733 | + }else{ | |
| 734 | + fossil_print("Use --test or --all to see test and debug commands.\n"); | |
| 735 | + } | |
| 736 | + command_list(0, cmdFlags); | |
| 726 | 737 | } |
| 727 | 738 | |
| 728 | 739 | |
| 729 | 740 | /* |
| 730 | 741 | ** COMMAND: test-list-webpage |
| @@ -756,32 +767,39 @@ | ||
| 756 | 767 | |
| 757 | 768 | /* |
| 758 | 769 | ** COMMAND: help |
| 759 | 770 | ** |
| 760 | 771 | ** Usage: %fossil help COMMAND |
| 772 | +** or: %fossil COMMAND -help | |
| 773 | +** | |
| 774 | +** Display information on how to use COMMAND. To display a list of | |
| 775 | +** available commands use: | |
| 761 | 776 | ** |
| 762 | -** Display information on how to use COMMAND | |
| 777 | +** %fossil commands | |
| 763 | 778 | */ |
| 764 | 779 | void help_cmd(void){ |
| 765 | 780 | int rc, idx; |
| 766 | 781 | const char *z; |
| 767 | 782 | if( g.argc<3 ){ |
| 768 | - fossil_print("Usage: %s help COMMAND.\nAvailable COMMANDs:\n", | |
| 769 | - fossil_nameofexe()); | |
| 770 | - cmd_cmd_list(0); | |
| 783 | + z = fossil_nameofexe(); | |
| 784 | + fossil_print( | |
| 785 | + "Usage: %s help COMMAND\n" | |
| 786 | + "Common COMMANDs: (use \"%s commands\" for a complete list)\n", | |
| 787 | + z, z); | |
| 788 | + command_list(0, CMDFLAG_1ST_TIER); | |
| 771 | 789 | version_cmd(); |
| 772 | 790 | return; |
| 773 | 791 | } |
| 774 | 792 | rc = name_search(g.argv[2], aCommand, count(aCommand), &idx); |
| 775 | 793 | if( rc==1 ){ |
| 776 | 794 | fossil_print("unknown command: %s\nAvailable commands:\n", g.argv[2]); |
| 777 | - cmd_cmd_list(0); | |
| 795 | + command_list(0, 0xff); | |
| 778 | 796 | fossil_exit(1); |
| 779 | 797 | }else if( rc==2 ){ |
| 780 | 798 | fossil_print("ambiguous command prefix: %s\nMatching commands:\n", |
| 781 | 799 | g.argv[2]); |
| 782 | - cmd_cmd_list(g.argv[2]); | |
| 800 | + command_list(g.argv[2], 0xff); | |
| 783 | 801 | fossil_exit(1); |
| 784 | 802 | } |
| 785 | 803 | z = aCmdHelp[idx]; |
| 786 | 804 | if( z==0 ){ |
| 787 | 805 | fossil_fatal("no help available for the %s command", |
| @@ -1149,11 +1167,11 @@ | ||
| 1149 | 1167 | */ |
| 1150 | 1168 | cgi_reply(); |
| 1151 | 1169 | } |
| 1152 | 1170 | |
| 1153 | 1171 | /* |
| 1154 | -** COMMAND: cgi | |
| 1172 | +** COMMAND: cgi* | |
| 1155 | 1173 | ** |
| 1156 | 1174 | ** Usage: %fossil ?cgi? SCRIPT |
| 1157 | 1175 | ** |
| 1158 | 1176 | ** The SCRIPT argument is the name of a file that is the CGI script |
| 1159 | 1177 | ** that is being run. The command name, "cgi", may be omitted if |
| @@ -1336,11 +1354,11 @@ | ||
| 1336 | 1354 | ** |
| 1337 | 1355 | ** fossil http REPOSITORY INFILE OUTFILE IPADDR |
| 1338 | 1356 | ** |
| 1339 | 1357 | ** The argv==6 form is used by the win32 server only. |
| 1340 | 1358 | ** |
| 1341 | -** COMMAND: http | |
| 1359 | +** COMMAND: http* | |
| 1342 | 1360 | ** |
| 1343 | 1361 | ** Usage: %fossil http REPOSITORY [--notfound URL] [--host HOSTNAME] [--https] |
| 1344 | 1362 | ** |
| 1345 | 1363 | ** Handle a single HTTP request appearing on stdin. The resulting webpage |
| 1346 | 1364 | ** is delivered on stdout. This method is used to launch an HTTP request |
| @@ -1437,11 +1455,11 @@ | ||
| 1437 | 1455 | } |
| 1438 | 1456 | #endif |
| 1439 | 1457 | #endif |
| 1440 | 1458 | |
| 1441 | 1459 | /* |
| 1442 | -** COMMAND: server | |
| 1460 | +** COMMAND: server* | |
| 1443 | 1461 | ** COMMAND: ui |
| 1444 | 1462 | ** |
| 1445 | 1463 | ** Usage: %fossil server ?-P|--port TCPPORT? ?REPOSITORY? |
| 1446 | 1464 | ** Or: %fossil ui ?-P|--port TCPPORT? ?REPOSITORY? |
| 1447 | 1465 | ** |
| 1448 | 1466 |
| --- src/main.c | |
| +++ src/main.c | |
| @@ -325,14 +325,17 @@ | |
| 325 | argv = g.argv; |
| 326 | for(i=0; i<argc; i++) g.argv[i] = fossil_mbcs_to_utf8(argv[i]); |
| 327 | if( getenv("GATEWAY_INTERFACE")!=0 && !find_option("nocgi", 0, 0)){ |
| 328 | zCmdName = "cgi"; |
| 329 | }else if( argc<2 ){ |
| 330 | fossil_fatal("Usage: %s COMMAND ...\n" |
| 331 | "\"%s help\" for a list of available commands\n" |
| 332 | "\"%s help COMMAND\" for specific details\n", |
| 333 | argv[0], argv[0], argv[0]); |
| 334 | }else{ |
| 335 | g.fQuiet = find_option("quiet", 0, 0)!=0; |
| 336 | g.fSqlTrace = find_option("sqltrace", 0, 0)!=0; |
| 337 | g.fSqlStats = find_option("sqlstats", 0, 0)!=0; |
| 338 | g.fSystemTrace = find_option("systemtrace", 0, 0)!=0; |
| @@ -368,14 +371,15 @@ | |
| 368 | for(i=0; i<count(aCommand); i++){ |
| 369 | if( memcmp(zCmdName, aCommand[i].zName, n)==0 ){ |
| 370 | blob_appendf(&couldbe, " %s", aCommand[i].zName); |
| 371 | } |
| 372 | } |
| 373 | fossil_fatal("%s: ambiguous command prefix: %s\n" |
| 374 | "%s: could be any of:%s\n" |
| 375 | "%s: use \"help\" for more information\n", |
| 376 | argv[0], zCmdName, argv[0], blob_str(&couldbe), argv[0]); |
| 377 | } |
| 378 | aCommand[idx].xFunc(); |
| 379 | fossil_exit(0); |
| 380 | /*NOT_REACHED*/ |
| 381 | return 0; |
| @@ -693,38 +697,45 @@ | |
| 693 | } |
| 694 | |
| 695 | /* |
| 696 | ** List of commands starting with zPrefix, or all commands if zPrefix is NULL. |
| 697 | */ |
| 698 | static void cmd_cmd_list(const char *zPrefix){ |
| 699 | int i, nCmd; |
| 700 | int nPrefix = zPrefix ? strlen(zPrefix) : 0; |
| 701 | const char *aCmd[count(aCommand)]; |
| 702 | for(i=nCmd=0; i<count(aCommand); i++){ |
| 703 | const char *z = aCommand[i].zName; |
| 704 | if( memcmp(z,"test",4)==0 ) continue; |
| 705 | if( zPrefix && memcmp(zPrefix, z, nPrefix)!=0 ) continue; |
| 706 | aCmd[nCmd++] = aCommand[i].zName; |
| 707 | } |
| 708 | multi_column_list(aCmd, nCmd); |
| 709 | } |
| 710 | |
| 711 | /* |
| 712 | ** COMMAND: test-commands |
| 713 | ** |
| 714 | ** Usage: %fossil test-commands |
| 715 | ** |
| 716 | ** List all commands used for testing and debugging. |
| 717 | */ |
| 718 | void cmd_test_cmd_list(void){ |
| 719 | int i, nCmd; |
| 720 | const char *aCmd[count(aCommand)]; |
| 721 | for(i=nCmd=0; i<count(aCommand); i++){ |
| 722 | if( strncmp(aCommand[i].zName,"test",4)!=0 ) continue; |
| 723 | aCmd[nCmd++] = aCommand[i].zName; |
| 724 | } |
| 725 | multi_column_list(aCmd, nCmd); |
| 726 | } |
| 727 | |
| 728 | |
| 729 | /* |
| 730 | ** COMMAND: test-list-webpage |
| @@ -756,32 +767,39 @@ | |
| 756 | |
| 757 | /* |
| 758 | ** COMMAND: help |
| 759 | ** |
| 760 | ** Usage: %fossil help COMMAND |
| 761 | ** |
| 762 | ** Display information on how to use COMMAND |
| 763 | */ |
| 764 | void help_cmd(void){ |
| 765 | int rc, idx; |
| 766 | const char *z; |
| 767 | if( g.argc<3 ){ |
| 768 | fossil_print("Usage: %s help COMMAND.\nAvailable COMMANDs:\n", |
| 769 | fossil_nameofexe()); |
| 770 | cmd_cmd_list(0); |
| 771 | version_cmd(); |
| 772 | return; |
| 773 | } |
| 774 | rc = name_search(g.argv[2], aCommand, count(aCommand), &idx); |
| 775 | if( rc==1 ){ |
| 776 | fossil_print("unknown command: %s\nAvailable commands:\n", g.argv[2]); |
| 777 | cmd_cmd_list(0); |
| 778 | fossil_exit(1); |
| 779 | }else if( rc==2 ){ |
| 780 | fossil_print("ambiguous command prefix: %s\nMatching commands:\n", |
| 781 | g.argv[2]); |
| 782 | cmd_cmd_list(g.argv[2]); |
| 783 | fossil_exit(1); |
| 784 | } |
| 785 | z = aCmdHelp[idx]; |
| 786 | if( z==0 ){ |
| 787 | fossil_fatal("no help available for the %s command", |
| @@ -1149,11 +1167,11 @@ | |
| 1149 | */ |
| 1150 | cgi_reply(); |
| 1151 | } |
| 1152 | |
| 1153 | /* |
| 1154 | ** COMMAND: cgi |
| 1155 | ** |
| 1156 | ** Usage: %fossil ?cgi? SCRIPT |
| 1157 | ** |
| 1158 | ** The SCRIPT argument is the name of a file that is the CGI script |
| 1159 | ** that is being run. The command name, "cgi", may be omitted if |
| @@ -1336,11 +1354,11 @@ | |
| 1336 | ** |
| 1337 | ** fossil http REPOSITORY INFILE OUTFILE IPADDR |
| 1338 | ** |
| 1339 | ** The argv==6 form is used by the win32 server only. |
| 1340 | ** |
| 1341 | ** COMMAND: http |
| 1342 | ** |
| 1343 | ** Usage: %fossil http REPOSITORY [--notfound URL] [--host HOSTNAME] [--https] |
| 1344 | ** |
| 1345 | ** Handle a single HTTP request appearing on stdin. The resulting webpage |
| 1346 | ** is delivered on stdout. This method is used to launch an HTTP request |
| @@ -1437,11 +1455,11 @@ | |
| 1437 | } |
| 1438 | #endif |
| 1439 | #endif |
| 1440 | |
| 1441 | /* |
| 1442 | ** COMMAND: server |
| 1443 | ** COMMAND: ui |
| 1444 | ** |
| 1445 | ** Usage: %fossil server ?-P|--port TCPPORT? ?REPOSITORY? |
| 1446 | ** Or: %fossil ui ?-P|--port TCPPORT? ?REPOSITORY? |
| 1447 | ** |
| 1448 |
| --- src/main.c | |
| +++ src/main.c | |
| @@ -325,14 +325,17 @@ | |
| 325 | argv = g.argv; |
| 326 | for(i=0; i<argc; i++) g.argv[i] = fossil_mbcs_to_utf8(argv[i]); |
| 327 | if( getenv("GATEWAY_INTERFACE")!=0 && !find_option("nocgi", 0, 0)){ |
| 328 | zCmdName = "cgi"; |
| 329 | }else if( argc<2 ){ |
| 330 | fossil_print( |
| 331 | "Usage: %s COMMAND ...\n" |
| 332 | " or: %s help -- for a list of common commands\n" |
| 333 | " or: %s help COMMMAND -- for help with the named command\n" |
| 334 | " or: %s commands -- for a list of all commands\n", |
| 335 | argv[0], argv[0], argv[0], argv[0]); |
| 336 | fossil_exit(1); |
| 337 | }else{ |
| 338 | g.fQuiet = find_option("quiet", 0, 0)!=0; |
| 339 | g.fSqlTrace = find_option("sqltrace", 0, 0)!=0; |
| 340 | g.fSqlStats = find_option("sqlstats", 0, 0)!=0; |
| 341 | g.fSystemTrace = find_option("systemtrace", 0, 0)!=0; |
| @@ -368,14 +371,15 @@ | |
| 371 | for(i=0; i<count(aCommand); i++){ |
| 372 | if( memcmp(zCmdName, aCommand[i].zName, n)==0 ){ |
| 373 | blob_appendf(&couldbe, " %s", aCommand[i].zName); |
| 374 | } |
| 375 | } |
| 376 | fossil_print("%s: ambiguous command prefix: %s\n" |
| 377 | "%s: could be any of:%s\n" |
| 378 | "%s: use \"help\" for more information\n", |
| 379 | argv[0], zCmdName, argv[0], blob_str(&couldbe), argv[0]); |
| 380 | fossil_exit(1); |
| 381 | } |
| 382 | aCommand[idx].xFunc(); |
| 383 | fossil_exit(0); |
| 384 | /*NOT_REACHED*/ |
| 385 | return 0; |
| @@ -693,38 +697,45 @@ | |
| 697 | } |
| 698 | |
| 699 | /* |
| 700 | ** List of commands starting with zPrefix, or all commands if zPrefix is NULL. |
| 701 | */ |
| 702 | static void command_list(const char *zPrefix, int cmdMask){ |
| 703 | int i, nCmd; |
| 704 | int nPrefix = zPrefix ? strlen(zPrefix) : 0; |
| 705 | const char *aCmd[count(aCommand)]; |
| 706 | for(i=nCmd=0; i<count(aCommand); i++){ |
| 707 | const char *z = aCommand[i].zName; |
| 708 | if( (aCommand[i].cmdFlags & cmdMask)==0 ) continue; |
| 709 | if( zPrefix && memcmp(zPrefix, z, nPrefix)!=0 ) continue; |
| 710 | aCmd[nCmd++] = aCommand[i].zName; |
| 711 | } |
| 712 | multi_column_list(aCmd, nCmd); |
| 713 | } |
| 714 | |
| 715 | /* |
| 716 | ** COMMAND: commands |
| 717 | ** |
| 718 | ** Usage: %fossil commands ?--test? ?--all? ?--aux? |
| 719 | ** |
| 720 | ** List available commands. If the --test option is used list only unsupported |
| 721 | ** commands intended for testing and debugging. With --all, show all commands |
| 722 | ** including test debugging commands. With --aux, show only the auxiliary |
| 723 | ** and less often used commands, and/or command aliases. |
| 724 | */ |
| 725 | void cmd_command_list(void){ |
| 726 | int cmdFlags = CMDFLAG_1ST_TIER | CMDFLAG_2ND_TIER; |
| 727 | if( find_option("all",0,0)!=0 ){ |
| 728 | cmdFlags |= CMDFLAG_TEST; |
| 729 | }else if( find_option("test",0,0)!=0 ){ |
| 730 | cmdFlags = CMDFLAG_TEST; |
| 731 | }else if( find_option("aux",0,0)!=0 ){ |
| 732 | cmdFlags = CMDFLAG_2ND_TIER; |
| 733 | }else{ |
| 734 | fossil_print("Use --test or --all to see test and debug commands.\n"); |
| 735 | } |
| 736 | command_list(0, cmdFlags); |
| 737 | } |
| 738 | |
| 739 | |
| 740 | /* |
| 741 | ** COMMAND: test-list-webpage |
| @@ -756,32 +767,39 @@ | |
| 767 | |
| 768 | /* |
| 769 | ** COMMAND: help |
| 770 | ** |
| 771 | ** Usage: %fossil help COMMAND |
| 772 | ** or: %fossil COMMAND -help |
| 773 | ** |
| 774 | ** Display information on how to use COMMAND. To display a list of |
| 775 | ** available commands use: |
| 776 | ** |
| 777 | ** %fossil commands |
| 778 | */ |
| 779 | void help_cmd(void){ |
| 780 | int rc, idx; |
| 781 | const char *z; |
| 782 | if( g.argc<3 ){ |
| 783 | z = fossil_nameofexe(); |
| 784 | fossil_print( |
| 785 | "Usage: %s help COMMAND\n" |
| 786 | "Common COMMANDs: (use \"%s commands\" for a complete list)\n", |
| 787 | z, z); |
| 788 | command_list(0, CMDFLAG_1ST_TIER); |
| 789 | version_cmd(); |
| 790 | return; |
| 791 | } |
| 792 | rc = name_search(g.argv[2], aCommand, count(aCommand), &idx); |
| 793 | if( rc==1 ){ |
| 794 | fossil_print("unknown command: %s\nAvailable commands:\n", g.argv[2]); |
| 795 | command_list(0, 0xff); |
| 796 | fossil_exit(1); |
| 797 | }else if( rc==2 ){ |
| 798 | fossil_print("ambiguous command prefix: %s\nMatching commands:\n", |
| 799 | g.argv[2]); |
| 800 | command_list(g.argv[2], 0xff); |
| 801 | fossil_exit(1); |
| 802 | } |
| 803 | z = aCmdHelp[idx]; |
| 804 | if( z==0 ){ |
| 805 | fossil_fatal("no help available for the %s command", |
| @@ -1149,11 +1167,11 @@ | |
| 1167 | */ |
| 1168 | cgi_reply(); |
| 1169 | } |
| 1170 | |
| 1171 | /* |
| 1172 | ** COMMAND: cgi* |
| 1173 | ** |
| 1174 | ** Usage: %fossil ?cgi? SCRIPT |
| 1175 | ** |
| 1176 | ** The SCRIPT argument is the name of a file that is the CGI script |
| 1177 | ** that is being run. The command name, "cgi", may be omitted if |
| @@ -1336,11 +1354,11 @@ | |
| 1354 | ** |
| 1355 | ** fossil http REPOSITORY INFILE OUTFILE IPADDR |
| 1356 | ** |
| 1357 | ** The argv==6 form is used by the win32 server only. |
| 1358 | ** |
| 1359 | ** COMMAND: http* |
| 1360 | ** |
| 1361 | ** Usage: %fossil http REPOSITORY [--notfound URL] [--host HOSTNAME] [--https] |
| 1362 | ** |
| 1363 | ** Handle a single HTTP request appearing on stdin. The resulting webpage |
| 1364 | ** is delivered on stdout. This method is used to launch an HTTP request |
| @@ -1437,11 +1455,11 @@ | |
| 1455 | } |
| 1456 | #endif |
| 1457 | #endif |
| 1458 | |
| 1459 | /* |
| 1460 | ** COMMAND: server* |
| 1461 | ** COMMAND: ui |
| 1462 | ** |
| 1463 | ** Usage: %fossil server ?-P|--port TCPPORT? ?REPOSITORY? |
| 1464 | ** Or: %fossil ui ?-P|--port TCPPORT? ?REPOSITORY? |
| 1465 | ** |
| 1466 |
+29
-7
| --- src/mkindex.c | ||
| +++ src/mkindex.c | ||
| @@ -36,11 +36,13 @@ | ||
| 36 | 36 | ** We also scan for comments lines of this form: |
| 37 | 37 | ** |
| 38 | 38 | ** COMMAND: cmdname |
| 39 | 39 | ** |
| 40 | 40 | ** These entries build a constant table used to map command names into |
| 41 | -** functions. | |
| 41 | +** functions. If cmdname ends with "*" then the command is a second-tier | |
| 42 | +** command that is not displayed by the "fossil help" command. The | |
| 43 | +** final "*" is not considered to be part of the command name. | |
| 42 | 44 | ** |
| 43 | 45 | ** Comment text following COMMAND: through the end of the comment is |
| 44 | 46 | ** understood to be help text for the command specified. This help |
| 45 | 47 | ** text is accumulated and a table containing the text for each command |
| 46 | 48 | ** is generated. That table is used implement the "fossil help" command |
| @@ -224,28 +226,48 @@ | ||
| 224 | 226 | printf( |
| 225 | 227 | "typedef struct NameMap NameMap;\n" |
| 226 | 228 | "struct NameMap {\n" |
| 227 | 229 | " const char *zName;\n" |
| 228 | 230 | " void (*xFunc)(void);\n" |
| 231 | + " char cmdFlags;\n" | |
| 229 | 232 | "};\n" |
| 233 | + "#define CMDFLAG_1ST_TIER 0x01\n" | |
| 234 | + "#define CMDFLAG_2ND_TIER 0x02\n" | |
| 235 | + "#define CMDFLAG_TEST 0x04\n" | |
| 230 | 236 | "static const NameMap aWebpage[] = {\n" |
| 231 | 237 | ); |
| 232 | 238 | for(i=0; i<nFixed && aEntry[i].eType==0; i++){ |
| 233 | - printf(" { \"%s\",%*s %s },\n", | |
| 234 | - aEntry[i].zPath, (int)(25-strlen(aEntry[i].zPath)), "", | |
| 235 | - aEntry[i].zFunc | |
| 239 | + const char *z = aEntry[i].zPath; | |
| 240 | + int n = strlen(z); | |
| 241 | + printf(" { \"%s\",%*s %s,%*s 1 },\n", | |
| 242 | + z, | |
| 243 | + 25-n, "", | |
| 244 | + aEntry[i].zFunc, | |
| 245 | + (int)(35-strlen(aEntry[i].zFunc)), "" | |
| 236 | 246 | ); |
| 237 | 247 | } |
| 238 | 248 | printf("};\n"); |
| 239 | 249 | nType0 = i; |
| 240 | 250 | printf( |
| 241 | 251 | "static const NameMap aCommand[] = {\n" |
| 242 | 252 | ); |
| 243 | 253 | for(i=nType0; i<nFixed && aEntry[i].eType==1; i++){ |
| 244 | - printf(" { \"%s\",%*s %s },\n", | |
| 245 | - aEntry[i].zPath, (int)(25-strlen(aEntry[i].zPath)), "", | |
| 246 | - aEntry[i].zFunc | |
| 254 | + const char *z = aEntry[i].zPath; | |
| 255 | + int n = strlen(z); | |
| 256 | + int cmdFlags = 0x01; | |
| 257 | + if( z[n-1]=='*' ){ | |
| 258 | + n--; | |
| 259 | + cmdFlags = 0x02; | |
| 260 | + }else if( memcmp(z, "test-", 5)==0 ){ | |
| 261 | + cmdFlags = 0x04; | |
| 262 | + } | |
| 263 | + printf(" { \"%.*s\",%*s %s,%*s %d },\n", | |
| 264 | + n, z, | |
| 265 | + 25-n, "", | |
| 266 | + aEntry[i].zFunc, | |
| 267 | + (int)(35-strlen(aEntry[i].zFunc)), "", | |
| 268 | + cmdFlags | |
| 247 | 269 | ); |
| 248 | 270 | } |
| 249 | 271 | printf("};\n"); |
| 250 | 272 | for(i=nType0; i<nFixed; i++){ |
| 251 | 273 | char *z = aEntry[i].zHelp; |
| 252 | 274 |
| --- src/mkindex.c | |
| +++ src/mkindex.c | |
| @@ -36,11 +36,13 @@ | |
| 36 | ** We also scan for comments lines of this form: |
| 37 | ** |
| 38 | ** COMMAND: cmdname |
| 39 | ** |
| 40 | ** These entries build a constant table used to map command names into |
| 41 | ** functions. |
| 42 | ** |
| 43 | ** Comment text following COMMAND: through the end of the comment is |
| 44 | ** understood to be help text for the command specified. This help |
| 45 | ** text is accumulated and a table containing the text for each command |
| 46 | ** is generated. That table is used implement the "fossil help" command |
| @@ -224,28 +226,48 @@ | |
| 224 | printf( |
| 225 | "typedef struct NameMap NameMap;\n" |
| 226 | "struct NameMap {\n" |
| 227 | " const char *zName;\n" |
| 228 | " void (*xFunc)(void);\n" |
| 229 | "};\n" |
| 230 | "static const NameMap aWebpage[] = {\n" |
| 231 | ); |
| 232 | for(i=0; i<nFixed && aEntry[i].eType==0; i++){ |
| 233 | printf(" { \"%s\",%*s %s },\n", |
| 234 | aEntry[i].zPath, (int)(25-strlen(aEntry[i].zPath)), "", |
| 235 | aEntry[i].zFunc |
| 236 | ); |
| 237 | } |
| 238 | printf("};\n"); |
| 239 | nType0 = i; |
| 240 | printf( |
| 241 | "static const NameMap aCommand[] = {\n" |
| 242 | ); |
| 243 | for(i=nType0; i<nFixed && aEntry[i].eType==1; i++){ |
| 244 | printf(" { \"%s\",%*s %s },\n", |
| 245 | aEntry[i].zPath, (int)(25-strlen(aEntry[i].zPath)), "", |
| 246 | aEntry[i].zFunc |
| 247 | ); |
| 248 | } |
| 249 | printf("};\n"); |
| 250 | for(i=nType0; i<nFixed; i++){ |
| 251 | char *z = aEntry[i].zHelp; |
| 252 |
| --- src/mkindex.c | |
| +++ src/mkindex.c | |
| @@ -36,11 +36,13 @@ | |
| 36 | ** We also scan for comments lines of this form: |
| 37 | ** |
| 38 | ** COMMAND: cmdname |
| 39 | ** |
| 40 | ** These entries build a constant table used to map command names into |
| 41 | ** functions. If cmdname ends with "*" then the command is a second-tier |
| 42 | ** command that is not displayed by the "fossil help" command. The |
| 43 | ** final "*" is not considered to be part of the command name. |
| 44 | ** |
| 45 | ** Comment text following COMMAND: through the end of the comment is |
| 46 | ** understood to be help text for the command specified. This help |
| 47 | ** text is accumulated and a table containing the text for each command |
| 48 | ** is generated. That table is used implement the "fossil help" command |
| @@ -224,28 +226,48 @@ | |
| 226 | printf( |
| 227 | "typedef struct NameMap NameMap;\n" |
| 228 | "struct NameMap {\n" |
| 229 | " const char *zName;\n" |
| 230 | " void (*xFunc)(void);\n" |
| 231 | " char cmdFlags;\n" |
| 232 | "};\n" |
| 233 | "#define CMDFLAG_1ST_TIER 0x01\n" |
| 234 | "#define CMDFLAG_2ND_TIER 0x02\n" |
| 235 | "#define CMDFLAG_TEST 0x04\n" |
| 236 | "static const NameMap aWebpage[] = {\n" |
| 237 | ); |
| 238 | for(i=0; i<nFixed && aEntry[i].eType==0; i++){ |
| 239 | const char *z = aEntry[i].zPath; |
| 240 | int n = strlen(z); |
| 241 | printf(" { \"%s\",%*s %s,%*s 1 },\n", |
| 242 | z, |
| 243 | 25-n, "", |
| 244 | aEntry[i].zFunc, |
| 245 | (int)(35-strlen(aEntry[i].zFunc)), "" |
| 246 | ); |
| 247 | } |
| 248 | printf("};\n"); |
| 249 | nType0 = i; |
| 250 | printf( |
| 251 | "static const NameMap aCommand[] = {\n" |
| 252 | ); |
| 253 | for(i=nType0; i<nFixed && aEntry[i].eType==1; i++){ |
| 254 | const char *z = aEntry[i].zPath; |
| 255 | int n = strlen(z); |
| 256 | int cmdFlags = 0x01; |
| 257 | if( z[n-1]=='*' ){ |
| 258 | n--; |
| 259 | cmdFlags = 0x02; |
| 260 | }else if( memcmp(z, "test-", 5)==0 ){ |
| 261 | cmdFlags = 0x04; |
| 262 | } |
| 263 | printf(" { \"%.*s\",%*s %s,%*s %d },\n", |
| 264 | n, z, |
| 265 | 25-n, "", |
| 266 | aEntry[i].zFunc, |
| 267 | (int)(35-strlen(aEntry[i].zFunc)), "", |
| 268 | cmdFlags |
| 269 | ); |
| 270 | } |
| 271 | printf("};\n"); |
| 272 | for(i=nType0; i<nFixed; i++){ |
| 273 | char *z = aEntry[i].zHelp; |
| 274 |
+4
-4
| --- src/rebuild.c | ||
| +++ src/rebuild.c | ||
| @@ -487,11 +487,11 @@ | ||
| 487 | 487 | |
| 488 | 488 | db_end_transaction(0); |
| 489 | 489 | } |
| 490 | 490 | |
| 491 | 491 | /* |
| 492 | -** COMMAND: rebuild | |
| 492 | +** COMMAND: rebuild | |
| 493 | 493 | ** |
| 494 | 494 | ** Usage: %fossil rebuild ?REPOSITORY? ?OPTIONS? |
| 495 | 495 | ** |
| 496 | 496 | ** Reconstruct the named repository database from the core |
| 497 | 497 | ** records. Run this command after updating the fossil |
| @@ -720,11 +720,11 @@ | ||
| 720 | 720 | db_finalize(&q); |
| 721 | 721 | } |
| 722 | 722 | } |
| 723 | 723 | |
| 724 | 724 | /* |
| 725 | -** COMMAND: scrub | |
| 725 | +** COMMAND: scrub* | |
| 726 | 726 | ** %fossil scrub ?OPTIONS? ?REPOSITORY? |
| 727 | 727 | ** |
| 728 | 728 | ** The command removes sensitive information (such as passwords) from a |
| 729 | 729 | ** repository so that the respository can be sent to an untrusted reader. |
| 730 | 730 | ** |
| @@ -854,11 +854,11 @@ | ||
| 854 | 854 | } |
| 855 | 855 | fossil_mbcs_free(zMbcsPath); |
| 856 | 856 | } |
| 857 | 857 | |
| 858 | 858 | /* |
| 859 | -** COMMAND: reconstruct | |
| 859 | +** COMMAND: reconstruct* | |
| 860 | 860 | ** |
| 861 | 861 | ** Usage: %fossil reconstruct FILENAME DIRECTORY |
| 862 | 862 | ** |
| 863 | 863 | ** This command studies the artifacts (files) in DIRECTORY and |
| 864 | 864 | ** reconstructs the fossil record from them. It places the new |
| @@ -915,11 +915,11 @@ | ||
| 915 | 915 | zPassword = db_text(0, "SELECT pw FROM user WHERE login=%Q", g.zLogin); |
| 916 | 916 | fossil_print("admin-user: %s (initial password is \"%s\")\n", g.zLogin, zPassword); |
| 917 | 917 | } |
| 918 | 918 | |
| 919 | 919 | /* |
| 920 | -** COMMAND: deconstruct | |
| 920 | +** COMMAND: deconstruct* | |
| 921 | 921 | ** |
| 922 | 922 | ** Usage %fossil deconstruct ?OPTIONS? DESTINATION |
| 923 | 923 | ** |
| 924 | 924 | ** |
| 925 | 925 | ** This command exports all artifacts of a given repository and |
| 926 | 926 |
| --- src/rebuild.c | |
| +++ src/rebuild.c | |
| @@ -487,11 +487,11 @@ | |
| 487 | |
| 488 | db_end_transaction(0); |
| 489 | } |
| 490 | |
| 491 | /* |
| 492 | ** COMMAND: rebuild |
| 493 | ** |
| 494 | ** Usage: %fossil rebuild ?REPOSITORY? ?OPTIONS? |
| 495 | ** |
| 496 | ** Reconstruct the named repository database from the core |
| 497 | ** records. Run this command after updating the fossil |
| @@ -720,11 +720,11 @@ | |
| 720 | db_finalize(&q); |
| 721 | } |
| 722 | } |
| 723 | |
| 724 | /* |
| 725 | ** COMMAND: scrub |
| 726 | ** %fossil scrub ?OPTIONS? ?REPOSITORY? |
| 727 | ** |
| 728 | ** The command removes sensitive information (such as passwords) from a |
| 729 | ** repository so that the respository can be sent to an untrusted reader. |
| 730 | ** |
| @@ -854,11 +854,11 @@ | |
| 854 | } |
| 855 | fossil_mbcs_free(zMbcsPath); |
| 856 | } |
| 857 | |
| 858 | /* |
| 859 | ** COMMAND: reconstruct |
| 860 | ** |
| 861 | ** Usage: %fossil reconstruct FILENAME DIRECTORY |
| 862 | ** |
| 863 | ** This command studies the artifacts (files) in DIRECTORY and |
| 864 | ** reconstructs the fossil record from them. It places the new |
| @@ -915,11 +915,11 @@ | |
| 915 | zPassword = db_text(0, "SELECT pw FROM user WHERE login=%Q", g.zLogin); |
| 916 | fossil_print("admin-user: %s (initial password is \"%s\")\n", g.zLogin, zPassword); |
| 917 | } |
| 918 | |
| 919 | /* |
| 920 | ** COMMAND: deconstruct |
| 921 | ** |
| 922 | ** Usage %fossil deconstruct ?OPTIONS? DESTINATION |
| 923 | ** |
| 924 | ** |
| 925 | ** This command exports all artifacts of a given repository and |
| 926 |
| --- src/rebuild.c | |
| +++ src/rebuild.c | |
| @@ -487,11 +487,11 @@ | |
| 487 | |
| 488 | db_end_transaction(0); |
| 489 | } |
| 490 | |
| 491 | /* |
| 492 | ** COMMAND: rebuild |
| 493 | ** |
| 494 | ** Usage: %fossil rebuild ?REPOSITORY? ?OPTIONS? |
| 495 | ** |
| 496 | ** Reconstruct the named repository database from the core |
| 497 | ** records. Run this command after updating the fossil |
| @@ -720,11 +720,11 @@ | |
| 720 | db_finalize(&q); |
| 721 | } |
| 722 | } |
| 723 | |
| 724 | /* |
| 725 | ** COMMAND: scrub* |
| 726 | ** %fossil scrub ?OPTIONS? ?REPOSITORY? |
| 727 | ** |
| 728 | ** The command removes sensitive information (such as passwords) from a |
| 729 | ** repository so that the respository can be sent to an untrusted reader. |
| 730 | ** |
| @@ -854,11 +854,11 @@ | |
| 854 | } |
| 855 | fossil_mbcs_free(zMbcsPath); |
| 856 | } |
| 857 | |
| 858 | /* |
| 859 | ** COMMAND: reconstruct* |
| 860 | ** |
| 861 | ** Usage: %fossil reconstruct FILENAME DIRECTORY |
| 862 | ** |
| 863 | ** This command studies the artifacts (files) in DIRECTORY and |
| 864 | ** reconstructs the fossil record from them. It places the new |
| @@ -915,11 +915,11 @@ | |
| 915 | zPassword = db_text(0, "SELECT pw FROM user WHERE login=%Q", g.zLogin); |
| 916 | fossil_print("admin-user: %s (initial password is \"%s\")\n", g.zLogin, zPassword); |
| 917 | } |
| 918 | |
| 919 | /* |
| 920 | ** COMMAND: deconstruct* |
| 921 | ** |
| 922 | ** Usage %fossil deconstruct ?OPTIONS? DESTINATION |
| 923 | ** |
| 924 | ** |
| 925 | ** This command exports all artifacts of a given repository and |
| 926 |
+1
-1
| --- src/search.c | ||
| +++ src/search.c | ||
| @@ -165,11 +165,11 @@ | ||
| 165 | 165 | } |
| 166 | 166 | |
| 167 | 167 | /* |
| 168 | 168 | ** Testing the search function. |
| 169 | 169 | ** |
| 170 | -** COMMAND: search | |
| 170 | +** COMMAND: search* | |
| 171 | 171 | ** %fossil search pattern... |
| 172 | 172 | ** |
| 173 | 173 | ** Search for timeline entries matching the pattern. |
| 174 | 174 | */ |
| 175 | 175 | void search_cmd(void){ |
| 176 | 176 |
| --- src/search.c | |
| +++ src/search.c | |
| @@ -165,11 +165,11 @@ | |
| 165 | } |
| 166 | |
| 167 | /* |
| 168 | ** Testing the search function. |
| 169 | ** |
| 170 | ** COMMAND: search |
| 171 | ** %fossil search pattern... |
| 172 | ** |
| 173 | ** Search for timeline entries matching the pattern. |
| 174 | */ |
| 175 | void search_cmd(void){ |
| 176 |
| --- src/search.c | |
| +++ src/search.c | |
| @@ -165,11 +165,11 @@ | |
| 165 | } |
| 166 | |
| 167 | /* |
| 168 | ** Testing the search function. |
| 169 | ** |
| 170 | ** COMMAND: search* |
| 171 | ** %fossil search pattern... |
| 172 | ** |
| 173 | ** Search for timeline entries matching the pattern. |
| 174 | */ |
| 175 | void search_cmd(void){ |
| 176 |
+1
-1
| --- src/tar.c | ||
| +++ src/tar.c | ||
| @@ -523,11 +523,11 @@ | ||
| 523 | 523 | blob_reset(&filename); |
| 524 | 524 | tar_finish(pTar); |
| 525 | 525 | } |
| 526 | 526 | |
| 527 | 527 | /* |
| 528 | -** COMMAND: tarball | |
| 528 | +** COMMAND: tarball* | |
| 529 | 529 | ** |
| 530 | 530 | ** Usage: %fossil tarball VERSION OUTPUTFILE [--name DIRECTORYNAME] |
| 531 | 531 | ** |
| 532 | 532 | ** Generate a compressed tarball for a specified version. If the --name |
| 533 | 533 | ** option is used, its argument becomes the name of the top-level directory |
| 534 | 534 |
| --- src/tar.c | |
| +++ src/tar.c | |
| @@ -523,11 +523,11 @@ | |
| 523 | blob_reset(&filename); |
| 524 | tar_finish(pTar); |
| 525 | } |
| 526 | |
| 527 | /* |
| 528 | ** COMMAND: tarball |
| 529 | ** |
| 530 | ** Usage: %fossil tarball VERSION OUTPUTFILE [--name DIRECTORYNAME] |
| 531 | ** |
| 532 | ** Generate a compressed tarball for a specified version. If the --name |
| 533 | ** option is used, its argument becomes the name of the top-level directory |
| 534 |
| --- src/tar.c | |
| +++ src/tar.c | |
| @@ -523,11 +523,11 @@ | |
| 523 | blob_reset(&filename); |
| 524 | tar_finish(pTar); |
| 525 | } |
| 526 | |
| 527 | /* |
| 528 | ** COMMAND: tarball* |
| 529 | ** |
| 530 | ** Usage: %fossil tarball VERSION OUTPUTFILE [--name DIRECTORYNAME] |
| 531 | ** |
| 532 | ** Generate a compressed tarball for a specified version. If the --name |
| 533 | ** option is used, its argument becomes the name of the top-level directory |
| 534 |
+1
-1
| --- src/tkt.c | ||
| +++ src/tkt.c | ||
| @@ -837,11 +837,11 @@ | ||
| 837 | 837 | } |
| 838 | 838 | @ </ol> |
| 839 | 839 | } |
| 840 | 840 | |
| 841 | 841 | /* |
| 842 | -** COMMAND: ticket | |
| 842 | +** COMMAND: ticket* | |
| 843 | 843 | ** Usage: %fossil ticket SUBCOMMAND ... |
| 844 | 844 | ** |
| 845 | 845 | ** Run various subcommands to control tickets |
| 846 | 846 | ** |
| 847 | 847 | ** %fossil ticket show (REPORTTITLE|REPORTNR) ?TICKETFILTER? ?options? |
| 848 | 848 |
| --- src/tkt.c | |
| +++ src/tkt.c | |
| @@ -837,11 +837,11 @@ | |
| 837 | } |
| 838 | @ </ol> |
| 839 | } |
| 840 | |
| 841 | /* |
| 842 | ** COMMAND: ticket |
| 843 | ** Usage: %fossil ticket SUBCOMMAND ... |
| 844 | ** |
| 845 | ** Run various subcommands to control tickets |
| 846 | ** |
| 847 | ** %fossil ticket show (REPORTTITLE|REPORTNR) ?TICKETFILTER? ?options? |
| 848 |
| --- src/tkt.c | |
| +++ src/tkt.c | |
| @@ -837,11 +837,11 @@ | |
| 837 | } |
| 838 | @ </ol> |
| 839 | } |
| 840 | |
| 841 | /* |
| 842 | ** COMMAND: ticket* |
| 843 | ** Usage: %fossil ticket SUBCOMMAND ... |
| 844 | ** |
| 845 | ** Run various subcommands to control tickets |
| 846 | ** |
| 847 | ** %fossil ticket show (REPORTTITLE|REPORTNR) ?TICKETFILTER? ?options? |
| 848 |
+1
-1
| --- src/undo.c | ||
| +++ src/undo.c | ||
| @@ -348,11 +348,11 @@ | ||
| 348 | 348 | undo_all_filesystem(0); |
| 349 | 349 | } |
| 350 | 350 | |
| 351 | 351 | /* |
| 352 | 352 | ** COMMAND: undo |
| 353 | -** COMMAND: redo | |
| 353 | +** COMMAND: redo* | |
| 354 | 354 | ** |
| 355 | 355 | ** Usage: %fossil undo ?--explain? ?FILENAME...? |
| 356 | 356 | ** or: %fossil redo ?--explain? ?FILENAME...? |
| 357 | 357 | ** |
| 358 | 358 | ** Undo the changes to the working checkout caused by the most recent |
| 359 | 359 |
| --- src/undo.c | |
| +++ src/undo.c | |
| @@ -348,11 +348,11 @@ | |
| 348 | undo_all_filesystem(0); |
| 349 | } |
| 350 | |
| 351 | /* |
| 352 | ** COMMAND: undo |
| 353 | ** COMMAND: redo |
| 354 | ** |
| 355 | ** Usage: %fossil undo ?--explain? ?FILENAME...? |
| 356 | ** or: %fossil redo ?--explain? ?FILENAME...? |
| 357 | ** |
| 358 | ** Undo the changes to the working checkout caused by the most recent |
| 359 |
| --- src/undo.c | |
| +++ src/undo.c | |
| @@ -348,11 +348,11 @@ | |
| 348 | undo_all_filesystem(0); |
| 349 | } |
| 350 | |
| 351 | /* |
| 352 | ** COMMAND: undo |
| 353 | ** COMMAND: redo* |
| 354 | ** |
| 355 | ** Usage: %fossil undo ?--explain? ?FILENAME...? |
| 356 | ** or: %fossil redo ?--explain? ?FILENAME...? |
| 357 | ** |
| 358 | ** Undo the changes to the working checkout caused by the most recent |
| 359 |
+1
-1
| --- src/user.c | ||
| +++ src/user.c | ||
| @@ -142,11 +142,11 @@ | ||
| 142 | 142 | } |
| 143 | 143 | } |
| 144 | 144 | |
| 145 | 145 | |
| 146 | 146 | /* |
| 147 | -** COMMAND: user | |
| 147 | +** COMMAND: user* | |
| 148 | 148 | ** |
| 149 | 149 | ** Usage: %fossil user SUBCOMMAND ... ?-R|--repository FILE? |
| 150 | 150 | ** |
| 151 | 151 | ** Run various subcommands on users of the open repository or of |
| 152 | 152 | ** the repository identified by the -R or --repository option. |
| 153 | 153 |
| --- src/user.c | |
| +++ src/user.c | |
| @@ -142,11 +142,11 @@ | |
| 142 | } |
| 143 | } |
| 144 | |
| 145 | |
| 146 | /* |
| 147 | ** COMMAND: user |
| 148 | ** |
| 149 | ** Usage: %fossil user SUBCOMMAND ... ?-R|--repository FILE? |
| 150 | ** |
| 151 | ** Run various subcommands on users of the open repository or of |
| 152 | ** the repository identified by the -R or --repository option. |
| 153 |
| --- src/user.c | |
| +++ src/user.c | |
| @@ -142,11 +142,11 @@ | |
| 142 | } |
| 143 | } |
| 144 | |
| 145 | |
| 146 | /* |
| 147 | ** COMMAND: user* |
| 148 | ** |
| 149 | ** Usage: %fossil user SUBCOMMAND ... ?-R|--repository FILE? |
| 150 | ** |
| 151 | ** Run various subcommands on users of the open repository or of |
| 152 | ** the repository identified by the -R or --repository option. |
| 153 |
+1
-1
| --- src/wiki.c | ||
| +++ src/wiki.c | ||
| @@ -826,11 +826,11 @@ | ||
| 826 | 826 | db_end_transaction(0); |
| 827 | 827 | return 1; |
| 828 | 828 | } |
| 829 | 829 | |
| 830 | 830 | /* |
| 831 | -** COMMAND: wiki | |
| 831 | +** COMMAND: wiki* | |
| 832 | 832 | ** |
| 833 | 833 | ** Usage: %fossil wiki (export|create|commit|list) WikiName |
| 834 | 834 | ** |
| 835 | 835 | ** Run various subcommands to work with wiki entries. |
| 836 | 836 | ** |
| 837 | 837 |
| --- src/wiki.c | |
| +++ src/wiki.c | |
| @@ -826,11 +826,11 @@ | |
| 826 | db_end_transaction(0); |
| 827 | return 1; |
| 828 | } |
| 829 | |
| 830 | /* |
| 831 | ** COMMAND: wiki |
| 832 | ** |
| 833 | ** Usage: %fossil wiki (export|create|commit|list) WikiName |
| 834 | ** |
| 835 | ** Run various subcommands to work with wiki entries. |
| 836 | ** |
| 837 |
| --- src/wiki.c | |
| +++ src/wiki.c | |
| @@ -826,11 +826,11 @@ | |
| 826 | db_end_transaction(0); |
| 827 | return 1; |
| 828 | } |
| 829 | |
| 830 | /* |
| 831 | ** COMMAND: wiki* |
| 832 | ** |
| 833 | ** Usage: %fossil wiki (export|create|commit|list) WikiName |
| 834 | ** |
| 835 | ** Run various subcommands to work with wiki entries. |
| 836 | ** |
| 837 |
+1
-1
| --- src/winhttp.c | ||
| +++ src/winhttp.c | ||
| @@ -432,11 +432,11 @@ | ||
| 432 | 432 | } |
| 433 | 433 | return 0; |
| 434 | 434 | } |
| 435 | 435 | |
| 436 | 436 | /* |
| 437 | -** COMMAND: winsrv | |
| 437 | +** COMMAND: winsrv* | |
| 438 | 438 | ** Usage: fossil winsrv METHOD ?SERVICE-NAME? ?OPTIONS? |
| 439 | 439 | ** |
| 440 | 440 | ** Where METHOD is one of: create delete show start stop. |
| 441 | 441 | ** |
| 442 | 442 | ** The winsrv command manages Fossil as a Windows service. This allows |
| 443 | 443 |
| --- src/winhttp.c | |
| +++ src/winhttp.c | |
| @@ -432,11 +432,11 @@ | |
| 432 | } |
| 433 | return 0; |
| 434 | } |
| 435 | |
| 436 | /* |
| 437 | ** COMMAND: winsrv |
| 438 | ** Usage: fossil winsrv METHOD ?SERVICE-NAME? ?OPTIONS? |
| 439 | ** |
| 440 | ** Where METHOD is one of: create delete show start stop. |
| 441 | ** |
| 442 | ** The winsrv command manages Fossil as a Windows service. This allows |
| 443 |
| --- src/winhttp.c | |
| +++ src/winhttp.c | |
| @@ -432,11 +432,11 @@ | |
| 432 | } |
| 433 | return 0; |
| 434 | } |
| 435 | |
| 436 | /* |
| 437 | ** COMMAND: winsrv* |
| 438 | ** Usage: fossil winsrv METHOD ?SERVICE-NAME? ?OPTIONS? |
| 439 | ** |
| 440 | ** Where METHOD is one of: create delete show start stop. |
| 441 | ** |
| 442 | ** The winsrv command manages Fossil as a Windows service. This allows |
| 443 |
+1
-1
| --- src/zip.c | ||
| +++ src/zip.c | ||
| @@ -377,11 +377,11 @@ | ||
| 377 | 377 | blob_reset(&filename); |
| 378 | 378 | zip_close(pZip); |
| 379 | 379 | } |
| 380 | 380 | |
| 381 | 381 | /* |
| 382 | -** COMMAND: zip | |
| 382 | +** COMMAND: zip* | |
| 383 | 383 | ** |
| 384 | 384 | ** Usage: %fossil zip VERSION OUTPUTFILE [--name DIRECTORYNAME] |
| 385 | 385 | ** |
| 386 | 386 | ** Generate a ZIP archive for a specified version. If the --name option is |
| 387 | 387 | ** used, it argument becomes the name of the top-level directory in the |
| 388 | 388 |
| --- src/zip.c | |
| +++ src/zip.c | |
| @@ -377,11 +377,11 @@ | |
| 377 | blob_reset(&filename); |
| 378 | zip_close(pZip); |
| 379 | } |
| 380 | |
| 381 | /* |
| 382 | ** COMMAND: zip |
| 383 | ** |
| 384 | ** Usage: %fossil zip VERSION OUTPUTFILE [--name DIRECTORYNAME] |
| 385 | ** |
| 386 | ** Generate a ZIP archive for a specified version. If the --name option is |
| 387 | ** used, it argument becomes the name of the top-level directory in the |
| 388 |
| --- src/zip.c | |
| +++ src/zip.c | |
| @@ -377,11 +377,11 @@ | |
| 377 | blob_reset(&filename); |
| 378 | zip_close(pZip); |
| 379 | } |
| 380 | |
| 381 | /* |
| 382 | ** COMMAND: zip* |
| 383 | ** |
| 384 | ** Usage: %fossil zip VERSION OUTPUTFILE [--name DIRECTORYNAME] |
| 385 | ** |
| 386 | ** Generate a ZIP archive for a specified version. If the --name option is |
| 387 | ** used, it argument becomes the name of the top-level directory in the |
| 388 |