- various enhancements in tecs and six
This commit is contained in:
20
tecs/six.c
20
tecs/six.c
@@ -605,6 +605,10 @@ int main (int argc, char *argv[]) {
|
||||
clcname="seacmd";
|
||||
servername="sea";
|
||||
clclen=strlen(clcname);
|
||||
} else if (0==strcmp(argv[i], "-graph") || 0==strcmp(argv[i], "graph")) {
|
||||
clcname="graphcmd";
|
||||
servername="graph";
|
||||
clclen=strlen(clcname);
|
||||
} else if (0==strcmp(argv[i], "-a") || 0==strcmp(argv[i], "a")) {
|
||||
remember=0;
|
||||
} else if (0==strcmp(argv[i], "-c") || 0==strcmp(argv[i], "c")) {
|
||||
@@ -634,14 +638,14 @@ int main (int argc, char *argv[]) {
|
||||
} else if (0==strcmp(argv[i], "-h")) {
|
||||
i++;
|
||||
if (i>=argc) {
|
||||
PutC("missing host");
|
||||
PutC("missing host");
|
||||
UsageNote(); return 0;
|
||||
}
|
||||
hostArg = argv[i];
|
||||
} else if (0==strcmp(argv[i], "-p")) {
|
||||
i++;
|
||||
if (i>=argc) {
|
||||
PutC("missing port");
|
||||
PutC("missing port");
|
||||
UsageNote(); return 0;
|
||||
}
|
||||
port=atoi(argv[i]);
|
||||
@@ -653,7 +657,7 @@ int main (int argc, char *argv[]) {
|
||||
sicslogin=0;
|
||||
} else {
|
||||
if (strlen(argv[i])>=32) {
|
||||
PutC("argument too long");
|
||||
PutC("argument too long");
|
||||
UsageNote(); return 0;
|
||||
} else if (argv[i][0] == '-') {
|
||||
PutC("unknown option: ");
|
||||
@@ -705,7 +709,7 @@ int main (int argc, char *argv[]) {
|
||||
}
|
||||
home = 1;
|
||||
}
|
||||
} else {
|
||||
} else if (strcmp(clcname, "seacmd") == 0) {
|
||||
PutC("seacmd, a sea commandline client (doc: seacmd help)\n");
|
||||
if (port == -1) {
|
||||
port = 8641;
|
||||
@@ -713,6 +717,14 @@ int main (int argc, char *argv[]) {
|
||||
port += 8640;
|
||||
}
|
||||
home = 1;
|
||||
} else {
|
||||
PutC("graphcmd, a graph commandline client (doc: graphcmd help)\n");
|
||||
if (port == -1) {
|
||||
port = 8741;
|
||||
} else if (port > 0 && port < 9) {
|
||||
port += 8740;
|
||||
}
|
||||
home = 1;
|
||||
}
|
||||
PutC( "---------------------------------------------------\n");
|
||||
PutC(".");
|
||||
|
||||
Reference in New Issue
Block a user