]> git.ipfire.org Git - thirdparty/ntp.git/commitdiff
More sntp.1 cleanups
authorHarlan Stenn <stenn@ntp.org>
Mon, 6 Jun 2011 07:59:08 +0000 (03:59 -0400)
committerHarlan Stenn <stenn@ntp.org>
Mon, 6 Jun 2011 07:59:08 +0000 (03:59 -0400)
bk: 4dec88cc5N6objAyeyOaflbNiWbJyg

ChangeLog
sntp/ag-tpl/aginfo.tpl [deleted file]
sntp/ag-tpl/agmdoc-cmd.tpl [deleted file]
sntp/ag-tpl/cmd-doc.tlib [deleted file]
sntp/ag-tpl/mdoc2man [deleted file]
sntp/sntp-opts.def

index 9db2efb2ca0f9fd3e3c1e72c821bbd7d7ea845eb..b5b764dbff760cadb1b628df582b2dfee9d33801 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,4 @@
+* More sntp.1 cleanups.
 * Produce ntpq.1 with the new autogen macros.
 * Remove the deprecated "detail" stanza from ntpdc-opts.def.
 (4.2.7p179) 2011/06/03 Released by Harlan Stenn <stenn@ntp.org>
diff --git a/sntp/ag-tpl/aginfo.tpl b/sntp/ag-tpl/aginfo.tpl
deleted file mode 100644 (file)
index b5231a7..0000000
+++ /dev/null
@@ -1,308 +0,0 @@
-[= AutoGen5 template
-
-texi
-
-##  Documentation template
-##
-## Time-stamp:        "2011-02-24 10:40:44 bkorb"
-## Author:            Bruce Korb <bkorb@gnu.org>
-##
-##  This file is part of AutoOpts, a companion to AutoGen.
-##  AutoOpts is free software.
-##  AutoOpts is Copyright (c) 1992-2011 by Bruce Korb - all rights reserved
-##
-##  AutoOpts is available under any one of two licenses.  The license
-##  in use must be one of these two and the choice is under the control
-##  of the user of the license.
-##
-##   The GNU Lesser General Public License, version 3 or later
-##      See the files "COPYING.lgplv3" and "COPYING.gplv3"
-##
-##   The Modified Berkeley Software Distribution License
-##      See the file "COPYING.mbsd"
-##
-##  These files have the following md5sums:
-##
-##  43b91e8ca915626ed3818ffb1b71248b COPYING.gplv3
-##  06a1a2e4760c90ea5e1dad8dfaac4d39 COPYING.lgplv3
-##  66a5cedaf62c4b2637025f049f9b826f COPYING.mbsd
-
-=]
-@node [= prog-name =] Invocation
-@[=
- (make-tmp-dir)
- (define down-prog-name (string-downcase! (get "prog-name")))
- (define doc-level (getenv "LEVEL"))
- (if (not (string? doc-level))
-     (set! doc-level "section"))
-
- doc-level =] Invoking [= prog_name =]
-@pindex [= prog-name  =]
-@cindex [= prog-title =][=
-
-FOR concept =]
-@cindex [= concept =][=
-ENDFOR
-
-=]
-@ignore
-[=
- (out-push-new (string-substitute (out-name) ".texi" ".menu"))
-
- (sprintf "* %-32s Invoking %s\n"
-  (string-append (get "prog-name") " Invocation::")
-  (get "prog-name") )
-
-=][=
-
-  (out-pop)
-  (dne "# " "# ")=]
-@end ignore
-[= ?% explain %s "This program has no explanation.\n" =]
-[=
-IF (exist? "prog-info-descrip")  =][=
-  FOR prog-info-descrip  "\n\n"  =][=
-    prog-info-descrip            =][=
-  ENDFOR                         =][=
-ELIF (exist? "detail")           =][=
-  detail                         =][=
-ENDIF
-=]
-
-This [=(string-downcase doc-level)=] was generated by @strong{AutoGen},
-the aginfo template and the option descriptions for the @command{[=
-prog-name =]} program.  It documents the @command{[=
-prog-name =]} usage text and option meanings.[=
-
-IF (exist? "copyright") =]
-
-This software is released under [=
-  CASE copyright.type =][=
-   =  gpl =]the GNU General Public License[=
-   = lgpl =]the GNU General Public License with Library Extensions[=
-   =  bsd =]the Free BSD License[=
-   *      =]a specialized copyright license[=
-  ESAC =].[=
-ENDIF =]
-
-@menu
-* [=(sprintf "%s %-24s %s" down-prog-name "usage::" (get "prog-name"))
-  =] usage help[=
-     (if (exist? "flag.value") " (-?)") =]
-[=(out-push-new)=][=
-
-FOR flag        =][=
-
-  IF (not (exist? "documentation"))
-
-=]* [=(sprintf
-         "%s %-24s"
-         (. down-prog-name)
-         (string-append
-            (string-tr! (get "name") "A-Z^_" "a-z--" )
-            " ::" ) )
-     =] [=% name (string-tr! "%s" "A-Z^_" "a-z--")=] option[=
-          % value " (-%s)" =]
-[=ENDIF         =][=
-
-ENDFOR flag     =][=
-
-(shell (string-append "sort <<\\_EOF_ | sed 's/ ::/::/'\n" (out-pop #t) "_EOF_"))
-
-=]
-@end menu
-
-@node [=(. down-prog-name)=] usage
-@[=CASE (. doc-level)=][=
-   = chapter    =][=
-   = section    =]sub[=
-   = subsection =]subsub[=
-   ESAC =]section [=prog-name=] usage help[=
-     (if (exist? "flag.value") " (-?)") =]
-@cindex [=(. down-prog-name)=] usage
-
-This is the automatically generated usage text for [=prog-name=]:
-
-@exampleindent 0
-@example
-[=
-(define help-opt
-   (if (exist? "long-opts")      "--help"
-   (if (exist? "help-value")     (string-append "-" (get "help-value"))
-   (if (exist? "flag.value")     "'-?'"
-                                 "help" ))) )
-
-(shellf "PROG=./%1$s
-
-    if [ ! -f ${PROG} ]
-    then PROG=./`echo $PROG | tr '[A-Z]' '[a-z]'` ; fi
-
-    if [ ! -f ${PROG} ]
-    then PROG=./`echo $PROG | tr x_ x-` ; fi
-
-    if [ ! -f ${PROG} ]
-    then if %1$s %2$s > /dev/null 2>&1
-         then PROG=%1$s
-         else PROG='echo %1$s is unavailable - no'
-    fi ; fi
-
-    ${PROG} %2$s 2>&1 | \
-        sed -e 's/USAGE:  lt-/USAGE:  /' \
-            -e 's/@/@@/g;s/{/@{/g;s/}/@}/g' \
-            -e 's/\t/        /g' "
-
-    (get "prog-name") help-opt
-)  =]
-@end example
-@exampleindent 4[=
-
-#  FOR all options, except the `documentation' options, ...  =][=
-
-(define opt-name       "")
-(define extra-ct       0)
-(define extra-text     "")
-(define optname-from   "A-Z_^")
-(define optname-to     "a-z--")
-(make-tmp-dir)
-
-(if (exist? "preserve-case") (begin
-  (define optname-from "_^")
-  (define optname-to   "--") )) =][=
-
-FOR flag                        =][=
-
-  IF (not (exist? "documentation")) =][=
-
-    (set! opt-name (string-tr! (get "name") optname-from optname-to))
-    (out-push-new (shellf "echo ${tmp_dir}/opt-text-%s" opt-name)) =][=
-    INVOKE emit-opt-text        =][=
-    (out-pop)                   =][=
-
-  ENDIF documentation exists    =][=
-
-ENDFOR flag                     =][=
-
-`cat ${tmp_dir}/opt-text-*`      =][=
-
-# = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =][=
-
-DEFINE emit-opt-text            =]
-
-@node [= (string-append down-prog-name " " opt-name) =]
-@[=CASE (. doc-level) =][=
-   = chapter    =][=
-   = section    =]sub[=
-   = subsection =]subsub[=
-   ESAC =]section [=(. opt-name)=] option[=
-          % value " (-%s)" =]
-@cindex [=(. down-prog-name)=]-[=(. opt-name)=]
-
-This is the ``[=(string-downcase! (get "descrip"))=]'' option.[=
-    (set! extra-ct 0)
-    (out-push-new)  =][=
-
-    IF (exist? "min") =]@item
-is required to appear on the command line.
-[=    (set! extra-ct (+ extra-ct 1)) =][=
-    ENDIF=][=
-
-    IF (exist? "max") =]@item
-may appear [=
-      IF % max (= "%s" "NOLIMIT")
-         =]an unlimited number of times[=
-      ELSE
-         =]up to [=max=] times[=
-      ENDIF=].
-[=    (set! extra-ct (+ extra-ct 1)) =][=
-    ENDIF=][=
-
-    IF (exist? "enabled") =]@item
-is enabled by default.
-[=    (set! extra-ct (+ extra-ct 1)) =][=
-    ENDIF=][=
-
-    IF (exist? "ifdef") =]@item
-must be compiled in by defining @code{[=(get "ifdef")
-      =]} during the compilation.
-[=    (set! extra-ct (+ extra-ct 1)) =][=
-    ENDIF =][=
-
-    IF (exist? "ifndef") =]@item
-must be compiled in by @strong{un}-defining @code{[=(get "ifndef")
-      =]} during the compilation.
-[=    (set! extra-ct (+ extra-ct 1)) =][=
-    ENDIF=][=
-
-    IF (exist? "no_preset") =]@item
-may not be preset with environment variables
-or in initialization (rc) files.
-[=    (set! extra-ct (+ extra-ct 1)) =][=
-    ENDIF=][=
-
-    IF (exist? "equivalence") =]@item
-is a member of the [=equivalence=] class of options.
-[=    (set! extra-ct (+ extra-ct 1)) =][=
-    ENDIF=][=
-
-    IF (exist? "flags_must") =]@item
-must appear in combination with the following options:
-[=    FOR flags_must ", " =][=flags_must=][=
-      ENDFOR=].
-[=    (set! extra-ct (+ extra-ct 1)) =][=
-    ENDIF=][=
-
-    IF (exist? "flags_cant") =]@item
-must not appear in combination with any of the following options:
-[=    FOR flags_cant ", " =][=flags_cant=][=
-      ENDFOR=].
-[=    (set! extra-ct (+ extra-ct 1)) =][=
-    ENDIF=][=
-
-    IF  (~* (get "arg-type") "key|set") =]@item
-This option takes a keyword as its argument[=
-
-      CASE arg-type   =][=
-      =* key          =][= (set! extra-ct (+ extra-ct 1)) =].
-The argument sets an enumeration value that can be tested by comparing[=
-
-      =* set          =][= (set! extra-ct (+ extra-ct 1)) =] list.
-Each entry turns on or off membership bits.  These bits can be tested
-with bit tests against[=
-      ESAC arg-type   =] the option value macro ([=
-(string-upcase (string-append
-(if (exist? "prefix") (string-append (get "prefix") "_") "")
-"OPT_VALUE_" (get "name")  )) =]).
-The available keywords are:
-@example
-[= (shellf "${CLexe:-columns} --spread=1 -W50 <<_EOF_\n%s\n_EOF_"
-            (join "\n" (stack "keyword"))  ) =]
-@end example
-[=
-
-      IF (=* (get "arg-type") "key") =]
-or their numeric equivalent.[=
-      ENDIF =][=
-
-    ENDIF key/set arg =][=
-
-    IF (> extra-ct 0) =][=
-      (set! extra-text (out-pop #t)) =]
-
-This option has some usage constraints.  It:
-@itemize @bullet
-[=(. extra-text)
-=]@end itemize
-[=  ELSE  =][=
-      (out-pop) =][=
-    ENDIF =][=
-
-?% doc "\n%s" "\nThis option has no @samp{doc} documentation." =][=
-  IF (exist? "deprecated") =]
-
-@strong{NOTE: THIS OPTION IS DEPRECATED}[=
-
-  ENDIF     =][=
-
-ENDDEF emit-opt-text
-
-aginfo.tpl ends here =]
diff --git a/sntp/ag-tpl/agmdoc-cmd.tpl b/sntp/ag-tpl/agmdoc-cmd.tpl
deleted file mode 100644 (file)
index 5c12e92..0000000
+++ /dev/null
@@ -1,116 +0,0 @@
-[+: -*- Mode: nroff -*-
-
-  AutoGen5 template mdoc
-
-## agman-cmd.tpl -- Template for command line mdoc pages
-##
-## Time-stamp:      "2011-05-24 17:59:40 bkorb"
-##
-##  This file is part of AutoOpts, a companion to AutoGen.
-##  AutoOpts is free software.
-##  AutoOpts is Copyright (c) 1992-2011 by Bruce Korb - all rights reserved
-##
-##  AutoOpts is available under any one of two licenses.  The license
-##  in use must be one of these two and the choice is under the control
-##  of the user of the license.
-##
-##   The GNU Lesser General Public License, version 3 or later
-##      See the files "COPYING.lgplv3" and "COPYING.gplv3"
-##
-##   The Modified Berkeley Software Distribution License
-##      See the file "COPYING.mbsd"
-##
-##  These files have the following md5sums:
-##
-##  43b91e8ca915626ed3818ffb1b71248b COPYING.gplv3
-##  06a1a2e4760c90ea5e1dad8dfaac4d39 COPYING.lgplv3
-##  66a5cedaf62c4b2637025f049f9b826f COPYING.mbsd
-
-# Produce a man page for section 1, 5 or 8 commands.
-# Which is selected via:  -DMAN_SECTION=n
-# passed to the autogen invocation.  "n" may have a suffix, if desired.
-#
-:+][+:
-
-(define head-line (lambda() (string-append
-   ".Dd "   (shell "date '+%B %e %Y' | sed 's/  */ /g'")
-   "\n.Dt " UP-PROG-NAME " " man-sect " " section-name
-   "\n.Os " (shell "uname -sr") "\n") ))
-
-:+][+:
-
-INCLUDE "cmd-doc.tlib"
-
-:+]
-.Sh NAME
-.Nm [+: prog-name         :+]
-.Nd [+: prog-title        :+]
-[+: INVOKE build-doc      :+][+:
-
-(out-move (string-append (get "prog-name") "."
-          man-sect))      :+][+:#
-
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
-.\"  S Y N O P S I S
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+:
-
-DEFINE synopsis
-
-:+]
-.Sh SYNOPSIS
-.Nm
-[+:
-
-  IF (define use-flags  (exist? "flag.value"))
-     (define named-mode (not (or use-flags (exist? "long-opts") )))
-     use-flags
-                                            :+][+:
-    IF (exist? "long-opts")                \:+]
-.\" Mixture of short (flag) options and long options
-.Op Fl flags
-.Op Fl flag Ar value
-.Op Fl \-option-name Ar value
-[+: ELSE no long options:                  \:+]
-.Op Fl flags
-.Op Fl flag Ar value
-[+: ENDIF                                               
-                                            :+][+:
-  ELIF (exist? "long-opts")                             
-                                           \:+]
-.Op Fl \-option-name
-.Op Fl \-option-name Ar value
-[+:
-
-  ELIF  (not (exist? "argument"))          \:+]
-.Op Ar option\-name Ar value
-.Pp
-All arguments are named options.
-[+:
-  ENDIF                                     :+][+:
-
-  IF (exist? "argument")                    :+][+:
-    argument                                :+][+:
-
-    IF (exist? "reorder-args")              :+]
-.Pp
-Operands and options may be intermixed.  They will be reordered.
-[+: ENDIF                                   :+][+:
-
-  ELIF (or (exist? "long-opts") use-flags) 
-
-\:+]
-.Pp
-All arguments must be options.
-[+:
-
-  ENDIF                                    \:+]
-.Pp
-[+:
-
-FOR explain   "\n.Pp\n"                     :+][+:
-  explain                                   :+][+:
-ENDFOR                                      :+][+:
-
-ENDDEF synopsis
-
-agmdoc-cmd.tpl ends here  :+]
diff --git a/sntp/ag-tpl/cmd-doc.tlib b/sntp/ag-tpl/cmd-doc.tlib
deleted file mode 100644 (file)
index 0efda25..0000000
+++ /dev/null
@@ -1,850 +0,0 @@
-[+: -*- Mode: nroff -*-
-
-  AutoGen5 template man
-
-## cmd-doc.tlib -- Template for command line man/mdoc pages
-##
-## Time-stamp:      "2011-05-30 14:24:12 bkorb"
-##
-##  This file is part of AutoOpts, a companion to AutoGen.
-##  AutoOpts is free software.
-##  AutoOpts is Copyright (c) 1992-2011 by Bruce Korb - all rights reserved
-##
-##  AutoOpts is available under any one of two licenses.  The license
-##  in use must be one of these two and the choice is under the control
-##  of the user of the license.
-##
-##   The GNU Lesser General Public License, version 3 or later
-##      See the files "COPYING.lgplv3" and "COPYING.gplv3"
-##
-##   The Modified Berkeley Software Distribution License
-##      See the file "COPYING.mbsd"
-##
-##  These files have the following md5sums:
-##
-##  43b91e8ca915626ed3818ffb1b71248b COPYING.gplv3
-##  06a1a2e4760c90ea5e1dad8dfaac4d39 COPYING.lgplv3
-##  66a5cedaf62c4b2637025f049f9b826f COPYING.mbsd
-
-# Produce a man page for section 1, 6 or 8 commands.  Which is
-# selected via: -DMAN_SECTION=n.  "n" may have a suffix, if desired.
-# These sections have default section names that may be overridden
-# with -DSECTIN_NAME=XX, also passed to the autogen invocation.
-#
-:+][+:
-
-(define down-prog-name (string-downcase! (get "prog-name")))
-(define UP-PROG-NAME   (get-up-name "prog-name"))
-
-(define tmp-val        (getenv "MAN_SECTION"))
-(define man-sect       (if (exist? "cmd-section") (get "cmd-section") "1"))
-(define file-name      "")
-(define tmp-str        "")
-
-(if (defined? 'tmp-val)
-    (if (string? tmp-val)
-        (set! man-sect tmp-val)))
-
-(define section-name
-   (if (=* man-sect "1") "User Commands"
-   (if (=* man-sect "6") "Games"
-   (if (=* man-sect "8") "System Management"
-   (error
-    "the agman-cmd template only produces section 1, 6 and 8 man pages")
-))))
-(set! tmp-val (getenv "SECTION_NAME"))
-(if (defined? 'tmp-val) (if (string? tmp-val)
-    (set! section-name tmp-val) ))
-
-(define package-text "")
-(define package+version (and (exist? "package") (exist? "version")))
-
-(if (or (exist? "package") (exist? "version")) (begin
-  (set! package-text (string-append
-        (get "package")
-        (if package+version " (" "")
-        (get "version")
-        (if package+version ")" "") ))
-) )
-
-(define name-to-fname (lambda (nm)
-    (string-tr (string-downcase sec-type) " " "-") ))
-
-(make-tmp-dir)
-
-(define home-rc-files (exist? "homerc"))
-(define home-rc-text
-  "\nSee \\fBOPTION PRESETS\\fP for configuration files.")
-
-(define environ-init  (exist? "environrc"))
-(define environ-text
-  "\nSee \\fBOPTION PRESETS\\fP for configuration environment variables.")
-
-(emit (head-line))
-(dne ".\\\"  ")                       :+][+:#
-
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
-.\"  B U I L D   D O C
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+:
-
-DEFINE build-doc                      :+][+:
-
-INVOKE doc-sections                   :+][+:
-INVOKE ao-sections                    :+][+:
-
-(out-push-new (string-append tmp-dir "/.assemble")) \:+]
-
-cat_n_rm() {
-  test -f ${tmp_dir}/$1 || return 0
-  grep -E -v '^[       ]*$' ${tmp_dir}/$1
-  rm -f ${tmp_dir}/$1
-}
-for f in synopsis description options option-presets
-do cat_n_rm $f ; done
-test -f ${tmp_dir}/name && rm -f ${tmp_dir}/name
-
-for f in implementation-notes environment files examples exit-status errors \
-       compatibility notes see-also conforming-to history authors bugs
-do cat_n_rm $f ; done > ${tmp_dir}/.fini
-
-set  -- ${tmp_dir}/*
-test -f "$1" && grep -E -v '^[         ]*$' $*
-cat  ${tmp_dir}/.fini
-[+: (out-pop)
-    (shell ". ${tmp_dir}/.assemble")  :+][+:
-
-ENDDEF build-doc
-
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
-.\"  D O C   S E C T I O N S
-.\"
-.\" Emit the files for each section that was provided.
-.\"
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+:
-
-DEFINE doc-sections                   :+][+:
-
-FOR doc-section                       :+][+:
-
-  CASE
-    (define sec-type (string-upcase (get "ds-type")))
-    (define sec-name (name-to-fname sec-type))
-    (out-push-new (string-append tmp-dir "/" sec-name))
-    (define cvt-fn (find-file (string-append
-         (get "ds-format" "man") "2mdoc")))
-    (if (not (defined? 'cvt-fn))
-        (error (sprintf "Cannot locate converter for %s"
-               (get "ds-format" "man"))))
-    sec-type :+][+:
-    == ""    :+][+: (error "unnamed doc-section") :+][+:
-    *==* " " :+].Sh "[+: (. sec-type) :+]"[+:
-    *        :+].Sh [+: (. sec-type)  :+][+:
-    ESAC                              :+]
-[+:
-    (shell (string-append
-      "fn='" cvt-fn "'\n"
-      "test -f ${fn} || die ${fn} not found from $PWD\n"
-      "${fn} <<\\_EndOfDocSection_ || die ${fn} failed in $PWD\n"
-      (get "ds-text")
-      "\n_EndOfDocSection_"
-    ))                                :+][+:
-
-    CASE (. sec-type)                 :+][+:
-    == FILES                          :+][+:
-        (if home-rc-files (emit home-rc-text))
-        (set! home-rc-files #f)       :+][+:
-
-    == ENVIRONMENT                    :+][+:
-        (if environ-init (emit environ-text))
-        (set! environ-init #f)        :+][+:
-    ESAC                              :+][+:
-
-    (out-pop)
-    :+][+:
-
-ENDFOR doc-section                    :+][+:
-
-ENDDEF doc-sections
-
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
-.\"  A O   S E C T I O N S
-.\"
-.\" Emit the files for the sections that these templates augment,
-.\" replace or conditionally replace
-.\"
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+:
-
-DEFINE ao-sections                      :+][+:
-
-IF (set! tmp-val (string-append tmp-dir "/synopsis"))
-   (not (access? tmp-val R_OK))         :+][+:
-      (out-push-new tmp-val)            :+][+:
-      INVOKE synopsis                   :+][+:
-      (out-pop)                         :+][+:
-ENDIF                                   :+][+:
-
-
-
-IF (set! tmp-val (string-append tmp-dir "/description"))
-   (access? tmp-val R_OK)               :+][+:
-      (out-push-add tmp-val)            :+][+:
-ELSE                                    :+][+:
-      (out-push-new tmp-val)            :+][+:
-      INVOKE description                :+][+:
-ENDIF                                   :+][+:
-
-IF (= (get "main.main-type") "for-each"):+][+:
-
-  CASE main.handler-type                :+][+:
-  ~* ^(name|file)|.*text                :+]
-.Pp
-This program will perform its function for every file named on the command
-line or every file named in a list read from stdin.  The arguments or input
-names must be pre\-existing files.  The input list may contain comments,
-which[+:
-
-  !E                                    :+]
-.Pp
-This program will perform its function for every command line argument
-or every non\-comment line in a list read from stdin.
-The input list comments[+:
-
-  *                                     :+][+:
-  (error "the 'for-each' main has in invalid handler-type.") :+][+:
-  ESAC                                 \:+]
- are blank lines or lines beginning with a '[+:
-  ?% comment-char "%s" "#" :+]' character.
-[+:
-
-ENDIF - "main" exists                   :+][+:
-(out-pop)                               :+][+:
-
-
-INVOKE options                          :+][+:
-INVOKE exit-status                      :+][+:
-INVOKE authors                          :+][+:
-INVOKE bugs                             :+][+:
-
-IF (or home-rc-files environ-init)      :+][+:
-
-   INVOKE option-presets                :+][+:
-
-ENDIF                                   :+][+:
-
-(define sec-fmt "\n.Sh %s%s")
-
-(if environ-init
-  (begin
-    (set! tmp-val (string-append tmp-dir "/environment"))
-    (if (access? tmp-val R_OK)
-      (begin
-        (out-push-add tmp-val)
-        (emit environ-text)
-      )
-      (begin
-        (out-push-new tmp-val)
-        (ag-fprintf 0 sec-fmt "ENVIRONMENT" environ-text)
-    ) )
-    (out-pop)
-) )
-
-(if home-rc-files
-  (begin
-    (set! tmp-val (string-append tmp-dir "/files"))
-    (if (access? tmp-val R_OK)
-      (begin
-        (out-push-add tmp-val)
-        (emit home-rc-text)
-      )
-      (begin
-        (out-push-new tmp-val)
-        (ag-fprintf 0 sec-fmt "FILES" home-rc-text)
-    ) )
-    (out-pop)
-) )                                   :+][+:
-
-ENDDEF ao-sections
-
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
-.\"  D E S C R I P T I O N
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+:
-
-DEFINE description                    :+]
-.Sh DESCRIPTION
-[+:
-
-  (if (exist? "prog-man-descrip")
-      (join "\n.Pp\n" (stack "prog-man-descrip"))
-      (if (exist? "detail")
-          (join "\n.Pp\n" (stack "detail"))
-          "There is no description for this command."
-  )   )                               :+]
-[+:
-ENDDEF description
-
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
-.\"  O P T I O N S
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+:
-
-DEFINE options
-
-:+][+:
-
-(set! tmp-val (string-append tmp-dir "/options"))
-(out-push-new tmp-val)
-
-(define opt-arg       "")
-(define dis-name      "")
-(define opt-name      "")
-(define optname-from  "A-Z_^")
-(define optname-to    "a-z--")
-(define cvt-cmd       "")
-(define formatted-doc (exist? "option-doc-format"))
-
-(if formatted-doc (begin
-    (out-push-new)
-    (set! cvt-cmd (string-append (get "option-doc-format") "2mdoc"))
-)   )
-
-(if (exist? "preserve-case")
-   (begin
-      (set! optname-from "_^")
-      (set! optname-to   "--")
-)  )
-
-(define fix-optname (lambda (o_nm) (begin
-   (set! o_nm (string-tr o_nm optname-from optname-to))
-   (set! o_nm (string-substitute o_nm "-" "\\-" ))
-   o_nm )))
-
-:+]
-.Sh OPTIONS[+:
-(if (exist? "option-info")
-    (string-append "\n.Pp\n" (get "option-info") "\n") )
-:+]
-.Bl -tag[+:
-
-FOR flag                              :+][+:
-
-  IF (exist? "documentation")         :+]
-.Ss "[+: (string-substitute (get "descrip") "-" "\\-") :+]"[+:
-  ELSE                                :+][+:
-    INVOKE emit-flag-text             :+][+:
-  ENDIF                               :+][+:
-ENDFOR flag
-
-.\" = = = = = = = = = = = = = = = = =
-.\"  help option
-.\" = = = = = = = = = = = = = = = = =
-
-:+]
-.It [+:
-
-  IF (. use-flags)  :+]\-[+: (get "help-value" "?") :+][+:
-     (if (exist? "long-opts") " , \" \\-\\-help\"") :+][+:
-  ELSE   :+][+:
-     (if (exist? "long-opts") "\\-\\-") :+]help[+:
-  ENDIF  :+]
-Display usage information and exit.[+:#
-
-.\" = = = = = = = = = = = = = = = = =
-.\"  more-help option
-.\" = = = = = = = = = = = = = = = = = :+][+:
-
-  IF (not (exist? "no-libopts")) :+]
-.It [+:
-
-  IF (. use-flags)  :+]\-[+: ?% more-help-value "%s" "!" :+][+:
-     IF (exist? "long-opts") :+] , " \-\-more-help"[+: ENDIF :+][+:
-  ELSE   :+][+:
-     IF (exist? "long-opts") :+]\-\-[+: ENDIF :+]more-help[+:
-  ENDIF  :+]
-Pass the extended usage information through a pager.[+:
-
-ENDIF no no-libopts
-
-.\" = = = = = = = = = = = = = = = = =
-.\"  save and load configuration
-.\" = = = = = = = = = = = = = = = = = :+][+:
-
-IF (exist? "homerc") :+]
-.It [+:
-
-  IF (. use-flags)  :+]\-[+: ?% save-opts-value "%s" ">"
-     :+] " [\fIrcfile\fP][+:
-     IF (exist? "long-opts") :+]," " \-\-save-opts" "[=\fIrcfile\fP][+:
-     ENDIF :+]"[+:
-  ELSE     :+][+:
-     IF (exist? "long-opts") :+]\-\-[+:
-     ENDIF :+]save-opts "[=\fIrcfile\fP]"[+:
-  ENDIF    :+]
-Save the option state to \fIrcfile\fP.  The default is the \fIlast\fP
-configuration file listed in the \fBOPTION PRESETS\fP section, below.
-.It [+:
-
-  IF (. use-flags)  :+]\-[+: ?% load-opts-value "%s" "<"
-     :+] " \fIrcfile\fP[+:
-     IF (exist? "long-opts")
-           :+]," " \-\-load-opts" "=\fIrcfile\fP," " \-\-no-load-opts[+:
-     ENDIF :+]"[+:
-  ELSE     :+][+:
-     IF (exist? "long-opts") :+]\-\-[+:
-     ENDIF :+]load-opts "=\fIrcfile\fP," " \-\-no-load-opts"[+:
-  ENDIF    :+]
-Load options from \fIrcfile\fP.
-The \fIno-load-opts\fP form will disable the loading
-of earlier RC/INI files.  \fI\-\-no-load-opts\fP is handled early,
-out of order.[+:
-ENDIF (exist? "homerc")
-
-.\" = = = = = = = = = = = = = = = = =
-.\"  version
-.\" = = = = = = = = = = = = = = = = = :+][+:
-
-IF (exist? "version") :+]
-.It [+:
-
-  IF (. use-flags)  :+]\-[+: ?% version-value "%s" "v"
-     :+] " [{\fIv|c|n\fP}][+:
-     IF (exist? "long-opts") :+]," " \-\-version" "[=\fI{v|c|n}\fP][+:
-     ENDIF :+]"[+:
-  ELSE     :+][+:
-     IF (exist? "long-opts") :+]\-\-[+:
-     ENDIF :+]version "[=\fI{v|c|n}\fP]"[+:
-  ENDIF    :+]
-Output version of program and exit.  The default mode is `v', a simple
-version.  The `c' mode will print copyright information and `n' will
-print the full copyright notice.[+:
-ENDIF                                 :+]
-.El
-[+:
-
-(if formatted-doc
-    (shell (string-append
-    "fn='" (find-file cvt-cmd)
-    "'\ntest -f ${fn} || die '" cvt-cmd " not found'\n"
-    "${fn} <<\\_EndOfMdoc_ || die ${fn} failed in $PWD\n"
-    (out-pop #t)
-    "\n_EndOfMdoc_" )) )           :+][+:
-
- (out-pop)                         :+][+:
-
-ENDDEF options
-
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
-.\"  O P T I O N   P R E S E T S
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+:
-
-DEFINE option-presets                 :+][+:
-
-(set! tmp-val (string-append tmp-dir "/option-presets"))
-(out-push-new tmp-val)
-
-:+]
-.Sh "OPTION PRESETS"
-Any option that is not marked as \fInot presettable\fP may be preset
-by loading values from [+:
-  IF (. home-rc-files)
-    :+]configuration ("RC" or ".INI") file(s)[+:
-    IF (. environ-init) :+] and values from
-[+:
-    ENDIF                             :+][+:
-  ENDIF                               :+][+:
-  IF (. environ-init) :+]environment variables named:
-.nf
-  \fB[+: (. UP-PROG-NAME) :+]_<option-name>\fP or \fB[+: (. UP-PROG-NAME) :+]\fP
-.fi
-.ad[+:
-    IF (. home-rc-files)              :+]
-The environmental presets take precedence (are processed later than)
-the configuration files.[+:
-    ENDIF                             :+][+:
-  ELSE                                :+].[+:
-  ENDIF                               :+][+:
-
-  CASE
-    (define rc-file
-       (get "rcfile" (string-append "." (get "prog-name") "rc")) )
-    (count "homerc")                  :+][+:
-
-  == "0"                              :+][+:
-  == "1"                              :+][+:
-
-    CASE homerc                       :+][+:
-    ~~ '\.|\$HOME'                    :+]
-The file "\fI[+: (string-append (get "homerc") "/" rc-file)
-:+]\fP" will be used, if present.[+:
-    *                                 :+]
-The \fIhomerc\fP file is "\fI[+:homerc:+]\fP", unless that is a directory.
-In that case, the file "\fI[+: (. rc-file) :+]\fP"
-is searched for within that directory.[+:
-    ESAC                              :+][+:
-
-  *                                   :+]
-The \fIhomerc\fP files are [+:
-    FOR homerc ", "                   :+][+:
-      IF (last-for?)                  :+]and [+:
-      ENDIF :+]"\fI[+: homerc :+]\fP"[+: ENDFOR :+].
-If any of these are directories, then the file \fI[+: (. rc-file) :+]\fP
-is searched for within those directories.[+:
-  ESAC                                :+][+:
-
-(out-pop)                             :+][+:
-
-ENDDEF option-presets
-
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
-.\"  E X I T   S T A T U S
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+:
-
-DEFINE exit-status                    :+][+:
-
-(set! tmp-val (string-append tmp-dir "/exit-status"))
-(set! tmp-str (shellf "sed 's/\\.Sh.*/.Pp/' %s 2>/dev/null" tmp-val))
-
-(out-push-new tmp-val)
-
-:+]
-.Sh "EXIT STATUS"
-One of the following exit values will be returned:
-.Bl -tag
-[+:
-(ag-fprintf 0 ".It 0\n%s\n"
-    (get "exit-desc[0]" "Successful program execution.") )
-
-(ag-fprintf 0 ".It 1\n%s\n"
-    (get "exit-desc[1]"
-    "The operation failed or the command syntax was not valid.")) :+][+:
-
-FOR exit-desc (for-from 2)            :+][+:
-  (sprintf ".It %d\n%s\n"
-    (for-index) (get "exit-desc"))    :+][+:
-ENDFOR exit-desc                      :+][+:
-(if (> (string-length tmp-str) 1)
-    (emit tmp-str)) :+]
-.El
-[+: (out-pop)                         :+][+:
-
-ENDDEF exit-status
-
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
-.\"  A U T H O R S
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+:
-
-DEFINE authors                        :+][+:
-
-IF (set! file-name (string-append tmp-dir "/authors"))
-   (not (access? file-name R_OK))     :+][+:
-
-   (out-push-new file-name)
-   (define remove-authors #t)
-
-   (set! tmp-val
-         (get "copyright.author" (get "copyright.owner")) )
-
-  (if (> (string-length tmp-val) 1)
-      (ag-fprintf 0 ".Sh AUTHORS\n%s\n" tmp-val))
-
-  (out-pop)                           :+][+:
-ENDIF copyright author/owner          :+][+:
-
-ENDDEF authors
-
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
-.\"  B U G S
-.\"
-.\"  This section is guaranteed to be the last section in the man page
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+:
-
-DEFINE bugs                           :+][+:
-
-IF  (set! file-name (string-append tmp-dir "/bugs"))
-    (access? file-name R_OK)          :+][+:
-    (out-push-add file-name)          :+][+:
-ELSE                                  :+][+:
-    (out-push-new file-name)
-    (set! tmp-val (get "copyright.eaddr" (get "eaddr")))
-    (if (> (string-length tmp-val) 1)
-        (ag-fprintf 0 ".Sh BUGS\nPlease send bug reports to: %s\n" tmp-val))
-:+][+:
-ENDIF                                 :+][+:
-
-  CASE copyright.type :+][+:
-   =  gpl  :+]
-.Pp
-This program is released under the GNU General Public License.[+:
-   = lgpl  :+]
-.Pp
-This program is released under the GNU General Public License
-with Library Extensions.[+:
-   =  bsd  :+]
-.Pp
-This program is released under the Free BSD License.[+:
-   *       :+][+:
-    IF (exist? "copyright.text")
-           :+]
-.Pp
-.nf
-.na
-[+: copyright.text :+]
-.fi
-.ad[+:
-    ELIF (exist? "copyright.date")    :+]
-.Pp
-Released under an unspecified copyright license.[+:
-    ENDIF                             :+][+:
-  ESAC                                :+]
-.Pp
-This manual page was \fIAutoGen\fP-erated from the \fB[+: prog-name :+]\fP
-option definitions.[+:
-
-(out-pop) :+][+:
-
-ENDDEF bugs
-
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
-.\"  E M I T   F L A G   T E X T
-.\" = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = :+][+:
-
-DEFINE emit-flag-text                 :+][+:
-
-  (if (exist? "enable")
-      (set! opt-name (string-append (get "enable") "-" (get "name")))
-      (set! opt-name (get "name")) )
-  (if (exist? "disable")
-      (set! dis-name (string-append (get "disable") "-" (get "name")))
-      (set! dis-name "") )
-
-  (set! opt-name (fix-optname opt-name))
-  (if (> (string-length dis-name) 0)
-      (set! dis-name (fix-optname dis-name)) )
-
-  (if (not (exist? "arg-type"))
-      (set! opt-arg "")
-      (set! opt-arg (string-append "\\fI"
-            (fix-optname (if (exist? "arg-name")
-                (get "arg-name")
-                (string-downcase! (get "arg-type"))  ))
-            "\\fP" ))
-  )
-
-:+]
-.It [+:
-  IF (exist? "value")                 :+][+:
-    IF (exist? "long-opts")           :+][+:
-
-          # * * * * * * * * * * * * * * * * * * * *
-          *
-          *  The option has a flag value (character) AND
-          *  the program uses long options
-          *
-          \:+]
- \-[+:value:+][+:
-      IF (not (exist? "arg-type"))    :+] ", " -\-[+:
-      ELSE  :+] " [+:(. opt-arg):+], " \-\-[+:
-      ENDIF :+][+: (. opt-name)       :+][+:
-      IF (exist? "arg-type")          :+][+:
-              ? arg-optional " [ =" ' "=" '
-              :+][+:  (. opt-arg)     :+][+:
-              arg-optional " ]"       :+][+:
-      ENDIF :+][+:
-      IF (exist? "disable") :+], " \fB\-\-[+:(. dis-name):+]\fP"[+:
-      ENDIF :+][+:
-
-    ELSE   :+][+:
-
-          # * * * * * * * * * * * * * * * * * * * *
-          *
-          *  The option has a flag value (character) BUT
-          *  the program does _NOT_ use long options
-          *
-          \:+]
- \-[+:value:+][+:
-      IF (exist? "arg-type") :+][+:
-            arg-optional "["     :+] "[+:(. opt-arg):+][+:
-            arg-optional '"]"'   :+][+:
-      ENDIF " :+][+:
-    ENDIF     :+][+:
-
-
-  ELSE  value does not exist -- named option only  :+][+:
-
-    IF (not (exist? "long-opts"))     :+][+:
-
-          # * * * * * * * * * * * * * * * * * * * *
-          *
-          *  The option does not have a flag value (character).
-          *  The program does _NOT_ use long options either.
-          *  Special magic:  All arguments are named options.
-          *
-          \:+]
- [+: (. opt-name) :+][+:
-      IF (exist? "arg-type")          :+] [+:
-         ? arg-optional " [ =" ' "=" '
-         :+][+:(. opt-arg):+][+:
-         arg-optional "]" :+][+:
-      ENDIF:+][+:
-      IF (exist? "disable") :+], " \fB[+:(. dis-name):+]\fP"[+:
-      ENDIF                           :+][+:
-
-
-    ELSE                              :+][+:
-          # * * * * * * * * * * * * * * * * * * * *
-          *
-          *  The option does not have a flag value (character).
-          *  The program, instead, only accepts long options.
-          *
-          \:+]
- \-\-[+: (. opt-name) :+][+:
-
-      IF (exist? "arg-type") :+] "[+: #" :+][+:
-            arg-optional "[" :+]=[+:(. opt-arg):+][+:
-            arg-optional "]" :+]"[+: #" :+][+:
-      ENDIF                           :+][+:
-
-      IF (exist? "disable")
-        :+], " \fB\-\-[+:(. dis-name):+]\fP"[+:
-      ENDIF                           :+][+:
-    ENDIF                             :+][+:
-  ENDIF                               :+]
-[+: (string-substitute (get "descrip") "\\" "\\\\") :+].[+:
-
-  IF (exist? "min")                   :+]
-This option is required to appear.[+:
-  ENDIF                               :+][+:
-
-  IF (exist? "max") :+]
-This option may appear [+:
-    IF % max (= "%s" "NOLIMIT")
-      :+]an unlimited number of times[+:ELSE
-      :+]up to [+: max :+] times[+:
-    ENDIF:+].[+:
-  ENDIF:+][+:
-
-  IF (exist? "disable")               :+]
-The \fI[+:(. dis-name):+]\fP form will [+:
-    IF (exist? "stack-arg")
-          :+]clear the list of option arguments[+:
-    ELSE  :+]disable the option[+:
-    ENDIF :+].[+:
-  ENDIF:+][+:
-
-  IF (exist? "enabled")               :+]
-This option is enabled by default.[+:
-  ENDIF                               :+][+:
-
-  IF (exist? "no-preset")             :+]
-This option may not be preset with environment variables
-or in initialization (rc) files.[+:
-  ENDIF                               :+][+:
-
-  IF (and (exist? "default") named-mode) :+]
-This option is the default option.[+:
-  ENDIF                               :+][+:
-
-  IF (exist? "equivalence")           :+]
-This option is a member of the [+:equivalence:+] class of options.[+:
-  ENDIF                               :+][+:
-
-  IF (exist? "flags-must")            :+]
-This option must appear in combination with the following options:
-[+: FOR flags-must ", " :+][+:flags-must:+][+:ENDFOR:+].[+:
-  ENDIF                               :+][+:
-
-  IF (exist? "flags-cant")            :+]
-This option must not appear in combination with any of the following options:
-[+: FOR flags-cant ", " :+][+:flags-cant:+][+:ENDFOR:+].[+:
-  ENDIF                               :+][+:
-
-
-  IF (~* (get "arg-type") "key|set") :+]
-This option takes a keyword as its argument[+:
-
-    IF (=* (get "arg-type") "set")
-
-:+] list.  Each entry turns on or off
-membership bits.  The bits are set by name or numeric value and cleared
-by preceding the name or number with an exclamation character ('!').
-They can all be cleared with the magic name \fInone\fR and they can all be set
-with
-.IR all .
-A single option will process a list of these values.[+:
-
-    ELSE
-
-:+].  The argument sets an enumeration value that can
-be tested by comparing them against the option value macro.[+:
-
-    ENDIF
-
-:+]
-The available keywords are:
-.in +4
-.nf
-.na
-[+: (shellf "${CLexe:-columns} --indent='' --spread=1 -W50 <<_EOF_\n%s\n_EOF_"
-            (join "\n" (stack "keyword"))  )   :+]
-.fi
-or their numeric equivalent.
-.in -4[+: (if (exist? "arg-default") "\n.sp" ) :+][+:
-
-  ELIF (=* (get "arg-type") "num")    :+]
-This option takes an integer number as its argument.[+:
-
-    IF  (exist? "arg-range")          :+]
-The value of [+:(. opt-arg):+] is constrained to being:
-.in +4
-.nf
-.na[+:FOR arg_range ", or"            :+]
-[+: (shellf "
-range='%s'
-
-case \"X${range}\" in
-X'->'?*  )
-  echo \"less than or equal to\" `
-    echo $range | sed 's/->//' ` ;;
-
-X?*'->'  )
-  echo \"greater than or equal to\" `
-    echo $range | sed 's/->.*//' ` ;;
-
-X?*'->'?* )
-  echo \"in the range \" `
-    echo $range | sed 's/->/ through /' ` ;;
-
-X?* )
-  echo exactly $range ;;
-
-X* ) echo $range is indeterminate
-esac"
-
-(get "arg-range") )
-:+][+:
-      ENDFOR arg-range :+]
-.fi
-.in -4[+:
-
-    ENDIF  arg-range exists           :+][+:
-
-  ENDIF  arg-type key/set/num         :+][+:
-
-  IF (exist? "arg-default")           :+]
-The default [+: (. opt-arg) :+] for this option is:
-.ti +4
- [+: (join " + " (stack "arg-default" )) :+][+:
-  ENDIF                               :+]
-.sp
-[+:
- (if (exist? "doc")
-        (string-substitute (get "doc") "\\" "\\\\")
-        "This option has not been fully documented." ) :+][+:
-  IF (exist? "deprecated")            :+]
-.sp
-.B
-NOTE: THIS OPTION IS DEPRECATED
-.R[+:
-  ENDIF                               :+][+:
-
-ENDDEF emit-flag-text
-
-.\" cmd-doc.tlib ends here \:+]
diff --git a/sntp/ag-tpl/mdoc2man b/sntp/ag-tpl/mdoc2man
deleted file mode 100755 (executable)
index 978b70d..0000000
+++ /dev/null
@@ -1,287 +0,0 @@
-#! /bin/sh
-
-## mdoc2mdoc.sh -- script to convert mdoc-isms to mdoc-isms
-##
-## Time-stamp:      "2011-05-30 14:17:42 bkorb"
-##
-##  This file is part of AutoOpts, a companion to AutoGen.
-##  AutoOpts is free software.
-##  AutoOpts is Copyright (c) 1992-2011 Bruce Korb - all rights reserved
-##
-##  AutoOpts is available under any one of two licenses.  The license
-##  in use must be one of these two and the choice is under the control
-##  of the user of the license.
-##
-##   The GNU Lesser General Public License, version 3 or later
-##      See the files "COPYING.lgplv3" and "COPYING.gplv3"
-##
-##   The Modified Berkeley Software Distribution License
-##      See the file "COPYING.mbsd"
-##
-##  These files have the following md5sums:
-##
-##  43b91e8ca915626ed3818ffb1b71248b COPYING.gplv3
-##  06a1a2e4760c90ea5e1dad8dfaac4d39 COPYING.lgplv3
-##  66a5cedaf62c4b2637025f049f9b826f COPYING.mbsd
-
-## This "library" converts mdoc-isms into man-isms.  It gets included
-## by the man page template at the point where mdoc-isms might start appearing
-## and then "emit-man-text" is invoked when all the text has been assembled.
-##
-## Display the command line prototype,
-## based only on the argument processing type.
-##
-## And run the entire output through "sed" to convert mdoc-isms
-
-# /bin/sh on Solaris is too horrible for words
-#
-case "$0" in
-/bin/sh ) test -x /usr/xpg4/bin/sh && exec /usr/xpg4/bin/sh ${1+"$@"} ;;
-esac
-
-parent_pid=$$
-prog=`basename $0 .sh`
-NmName=
-
-die() {
-    echo "$prog error:  $*" >&2
-    ps -p ${AG_pid:-999999999} >/dev/null 2>&1 && \
-        kill -TERM ${AG_pid}
-    kill -TERM $parent_pid
-    sleep 1
-    kill -9 $parent_pid
-    sleep 1
-    exit 1
-}
-
-
-# One function for each mdoc structure.
-#
-do_nest_enum() {
-    do_enum
-}
-
-do_enum() {
-    echo '.in +4'
-    local ix=1
-
-    while IFS='' read -r line
-    do
-        case "${line}" in
-        .It* ) printf '.ti -4\n%d\n\t' $ix
-               ix=`expr $ix + 1`
-               ;;
-
-        .Bl' '*enum* )   do_nest_enum      ;;
-        .Bl' '*tag* )    do_nest_tag       ;;
-        .Bl' '*bullet* ) do_nest_bullet    ;;
-        .Bd' '* )        do_nest_block     ;;
-        .Op' '* )        do_nest_optional  ;;
-        .Fl' '* )        do_nest_flag      ;;
-        .Ar' '* )        do_nest_arg       ;;
-
-        .El* )           echo '.in -4'
-                         return 0          ;;
-
-        * )              echo "$line"      ;;
-        esac
-    done
-    die "EOF reached processing '.Bl -enum'"
-}
-
-do_nest_tag() {
-    echo '.in +4'
-    while IFS='' read -r line
-    do
-        case "${line}" in
-        .It* ) printf '.ti -4\n.IR '
-               echo ${line#.It} ;;
-
-        .Bl' '*enum* )   do_nest_enum      ;;
-        .Bl' '*tag* )    do_nest_tag       ;;
-        .Bl' '*bullet* ) do_nest_bullet    ;;
-        .Bd' '* )        do_nest_block     ;;
-        .Op' '* )        do_nest_optional  ;;
-        .Fl' '* )        do_nest_flag      ;;
-        .Ar' '* )        do_nest_arg       ;;
-
-        .El* )           echo '.in -4'
-                         return 0          ;;
-
-        * )              echo "$line"      ;;
-        esac
-    done
-    die "EOF reached processing '.Bl -tag'"
-}
-
-do_tag() {
-    while IFS='' read -r line
-    do
-        case "${line}" in
-        .It* ) printf '.TP\n.BR '
-               echo ${line#.It}            ;;
-
-        .Bl' '*enum* )   do_nest_enum      ;;
-        .Bl' '*tag* )    do_nest_tag       ;;
-        .Bl' '*bullet* ) do_nest_bullet    ;;
-        .Bd' '* )        do_nest_block     ;;
-        .Op' '* )        do_nest_optional  ;;
-        .Fl' '* )        do_nest_flag      ;;
-        .Ar' '* )        do_nest_arg       ;;
-        .El* )           return 0          ;;
-        * )              echo "$line"      ;;
-        esac
-    done
-    die "EOF reached processing '.Bl -tag'"
-}
-
-do_nest_bullet() {
-    do_bullet
-}
-
-do_bullet() {
-    echo '.in +4'
-    while IFS='' read -r line
-    do
-        case "${line}" in
-        .It* ) printf '.ti -4\n\\fB*\\fP\n'
-               echo ${line#.It}
-               ;;
-
-        .Bl' '*enum* )   do_nest_enum      ;;
-        .Bl' '*tag* )    do_nest_tag       ;;
-        .Bl' '*bullet* ) do_nest_bullet    ;;
-        .Bd' '* )        do_nest_block     ;;
-        .Op' '* )        do_nest_optional  ;;
-        .Fl' '* )        do_nest_flag      ;;
-        .Ar' '* )        do_nest_arg       ;;
-
-        .El* )           echo '.in -4'
-                         return 0          ;;
-
-        * )              echo "$line"      ;;
-        esac
-    done
-    die "EOF reached processing '.Bl -bullet'"
-}
-
-do_nest_block() {
-    do_block
-}
-
-do_block() {
-    printf '.br\n.in +4\n.nf\n'
-    while IFS='' read -r line
-    do
-        case "${line}" in
-        .B*  ) die ".Bx command nested within .Bd" ;;
-
-        .Ed* ) echo .in -4
-               echo .fi
-               return 0          ;;
-
-        * )    echo "$line"      ;;
-        esac
-    done
-    die "EOF reached processing '.Bd'"
-}
-
-do_nest_optional() {
-    do_optional
-}
-
-do_optional() {
-    set -- $line
-    shift
-    local text='['
-    while test $# -gt 0
-    do
-        case "X$1" in
-        XFl )
-            text="${text} \\fB-$2\\fR"
-            shift 2 || die "Fl command had no argument"
-            ;;
-        XAr )
-            text="${text} \"\\fI$2\\fR\""
-            shift 2 || die "Fl command had no argument"
-            ;;
-        * ) text="${text} \"$2\""
-            ;;
-        esac
-    done
-    echo "${text} ]"
-}
-
-do_nest_flag() {
-    do_flag
-}
-
-do_flag() {
-    echo ${line#.Fl}
-}
-
-do_nest_arg() {
-    do_arg
-}
-
-do_arg() {
-    line=`echo ${line} | sed 's/^.Ar *//'`
-    echo "\\fI${line}\\fR"
-}
-
-do_NmName() {
-    # do we want to downcase the line first?  Yes...
-    set -- `echo ${line#.Nm} | \
-        sed -e 's/-/\\-/g' \
-            -e 'y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/'`
-    NmNameSfx=
-
-    if test $# -gt 0
-    then case "$1" in
-       [A-Za-z]* )
-           NmName=$1
-           shift
-           ;;
-       esac
-
-        test $# -gt 0 && NmNameSfx=" $*"
-    fi
-    echo ".B $NmName$NmNameSfx"
-}
-
-do_line() {
-    case "${line}" in
-    .Bl' '*enum* )   do_enum      ;;
-    .Bl' '*tag* )    do_tag       ;;
-    .Bl' '*bullet* ) do_bullet    ;;
-    .Bd' '*        ) do_block     ;;
-    .Op' '* )        do_optional  ;;
-    .Fl' '* )        do_flag      ;;
-    .Ar' '* )        do_arg       ;;
-    .Nm' '* )       do_NmName    ;;
-    .Nm     )       do_NmName    ;;
-    * )              echo "$line" ;;
-    esac
-    return 0
-}
-
-
-
-easy_fixes='
-s/^\.Sh/.SH/
-s/^\.Em/.I/
-s/^\.Pp/.PP/
-s/^.in *\\-/.in -/
-'
-
-readonly easy_fixes
-set -f
-
-{
-    while IFS='' read -r line
-    do
-        do_line
-    done
-} | sed "${easy_fixes}"
-
-exit 0
index dea3a7a03d0baa1e65662c67fc560251c38e6118..b58c5b1d2ce961e9fa8d780083466152edab49f9 100644 (file)
@@ -349,16 +349,6 @@ commands.
        _END_MDOC_USAGE;
 };
 
-doc-section    = {
-  ds-type      = 'EXIT STATUS';
-  ds-format    = 'mdoc';
-  ds-text      = <<- _END_MDOC_EXITSTATUS
-.Nm
-returns a zero exit status for success,
-and a non-zero value otherwise.
-       _END_MDOC_EXITSTATUS;
-};
-
 doc-section    = {
   ds-type      = 'AUTHORS';
   ds-format    = 'mdoc';