/
meta6-to-man
executable file
·45 lines (31 loc) · 1.38 KB
/
meta6-to-man
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
#!/usr/bin/env perl6
use META6::To::Man;
if !@*ARGS {
say qq:to/HERE/;
Usage: $*PROGRAM --meta6=M [options...]
Produces a UNIX 'man' page from data in the Perl 6 META6 file 'M'.
The output is written to file 'F.1' where 'F' is the name from the META6
file (which can be changed with the '--man' option below).
Mandatory argument:
--meta6=M Defines the desired META6.json file to be used. 'M' must be a
valid META6 file.
Options:
--install Installs the output file to one of the standard man
directories. The directory actually chosen is the first
one found with write privileges for the user. The
directories are searched in this order:
/usr/share/man/manN
/usr/local/share/man/manN
/usr/local/man/manN
--install-to=D Installs the output file to directory D.
--date=YYYY-MM-DD
The default is the current date.
--man=F Defines the man roff file 'F'. It is an error if
the file name does not end in '.N' where 'N' is a digit in
the range '1..8'.
--quiet Silences all messages. Normally for developer use.
--debug Normally for developer use.
HERE
exit
}
meta6-to-man @*ARGS;