1: #include "parms.h"
2: #include "structs.h"
3:
4: #ifdef RCSIDENT
5: static char rcsid[] = "$Header: help.c,v 1.7.0.1 86/01/25 22:55:47 notes Rel $";
6: #endif RCSIDENT
7:
8: /*
9: * help(file) char *file;
10: * prints the specified help file using more and then
11: * does a pause with 'hit any key to continue.
12: *
13: * Original idea: Rob Kolstad January 1982
14: */
15:
16: help (file)
17: char *file;
18: {
19: char cmdline[CMDLEN]; /* line buffer */
20: char *command;
21:
22: if ((command = getenv ("PAGER")) == NULL) /* see if overridden */
23: command = PAGER; /* assign default */
24: #ifndef FASTFORK
25: sprintf (cmdline, "%s < %s/%s/%s", command, Mstdir, UTILITY, file);
26: dounix (cmdline, 1, 1);
27: #else
28: {
29: if (index (command, ' ') != (char *) NULL) /* need shell */
30: {
31: sprintf (cmdline, "%s %s/%s/%s",
32: command, Mstdir, UTILITY, file);
33: dounix (1, 1, DFLTSH, "-c", cmdline, 0, 0);
34: }
35: else
36: {
37: sprintf (cmdline, "%s/%s/%s", Mstdir, UTILITY, file);
38: dounix (1, 1, command, cmdline, 0, 0, 0);
39: }
40: }
41: #endif
42: printf (" --Hit any key to continue--");
43: gchar ();
44: }
Defined functions
help
defined in line
16; used 5 times
Defined variables
rcsid
defined in line
5;
never used