796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
|
** Usage: %fossil help COMMAND
** or: %fossil COMMAND -help
**
** Display information on how to use COMMAND. To display a list of
** available commands one of:
**
** %fossil help Show common commands
** %fossil help --all Show both common and auxiliary commands
** %fossil help --test Show test commands only
** %fossil help --aux Show auxiliary commands only
** %fossil help --www Show list of WWW pages
*/
void help_cmd(void){
int rc, idx, isPage = 0;
const char *z;
char const * zCmdOrPage;
char const * zCmdOrPagePlural;
if( g.argc<3 ){
z = g.argv[0];
fossil_print(
"Usage: %s help COMMAND\n"
"Common COMMANDs: (use \"%s help --all\" for a complete list)\n",
z, z);
command_list(0, CMDFLAG_1ST_TIER);
version_cmd();
return;
}
if( find_option("all",0,0) ){
command_list(0, CMDFLAG_1ST_TIER | CMDFLAG_2ND_TIER);
return;
}
else if( find_option("www",0,0) ){
command_list(0, CMDFLAG_WEBPAGE);
return;
}
else if( find_option("aux",0,0) ){
command_list(0, CMDFLAG_2ND_TIER);
return;
}
else if( find_option("test",0,0) ){
command_list(0, CMDFLAG_TEST);
return;
}
isPage = ('/' == *g.argv[2]) ? 1 : 0;
if(isPage){
zCmdOrPage = "page";
zCmdOrPagePlural = "pages";
|
|
|
|
|
|
|
|
|
|
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
|
** Usage: %fossil help COMMAND
** or: %fossil COMMAND -help
**
** Display information on how to use COMMAND. To display a list of
** available commands one of:
**
** %fossil help Show common commands
** %fossil help --a|-all Show both common and auxiliary commands
** %fossil help --t|-test Show test commands only
** %fossil help --x|-aux Show auxiliary commands only
** %fossil help --w|-www Show list of WWW pages
*/
void help_cmd(void){
int rc, idx, isPage = 0;
const char *z;
char const * zCmdOrPage;
char const * zCmdOrPagePlural;
if( g.argc<3 ){
z = g.argv[0];
fossil_print(
"Usage: %s help COMMAND\n"
"Common COMMANDs: (use \"%s help --all\" for a complete list)\n",
z, z);
command_list(0, CMDFLAG_1ST_TIER);
version_cmd();
return;
}
if( find_option("all","a",0) ){
command_list(0, CMDFLAG_1ST_TIER | CMDFLAG_2ND_TIER);
return;
}
else if( find_option("www","w",0) ){
command_list(0, CMDFLAG_WEBPAGE);
return;
}
else if( find_option("aux","x",0) ){
command_list(0, CMDFLAG_2ND_TIER);
return;
}
else if( find_option("test","t",0) ){
command_list(0, CMDFLAG_TEST);
return;
}
isPage = ('/' == *g.argv[2]) ? 1 : 0;
if(isPage){
zCmdOrPage = "page";
zCmdOrPagePlural = "pages";
|