-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmakehelp
executable file
·46 lines (36 loc) · 1.34 KB
/
makehelp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#!/bin/sh
# Extract documentation from pgplot source code: output VMS help file
cat << \EOD
1 PGPLOT
PGPLOT GRAPHICS SUBROUTINE LIBRARY Version 5.2
PGPLOT is a Fortran subroutine package for drawing graphs on a variety
of display devices. For more details, see the manual ``PGPLOT Graphics
Subroutine Library'' available from T. J. Pearson
Arguments
The subroutine descriptions indicate the data type of each argument.
When arguments are described as ``input'', they may be replaced with
constants or expressions in the CALL statement, but make sure that the
constant or expression has the correct data type.
INTEGER arguments:
these should be declared INTEGER or INTEGER*4 in the calling
program, not INTEGER*2.
REAL arguments:
these should be declared REAL or REAL*4 in the calling program,
not REAL*8 or DOUBLE PRECISION.
LOGICAL arguments:
these should be declared LOGICAL or LOGICAL*4 in the calling
program.
CHARACTER arguments:
any valid Fortran CHARACTER variable may be used (declared
CHARACTER*n for some integer n).
EOD
awk '
/^C\*/ { print "";
print "2 " substr($0, 3, 500);
}
/^C\+/ { echo = 1; getline }
/^C--/ { echo = 0}
echo == 1 && /^C/ {print " " substr($0, 3, 500) }
echo == 1 && !/^C/ { print }
' $*