1[+: -*- Mode: nroff -*- 2 3 AutoGen5 template man 4 5## agman-cmd.tpl -- Template for command line man pages 6## 7## This file is part of AutoOpts, a companion to AutoGen. 8## AutoOpts is free software. 9## Copyright (C) 1992-2013 Bruce Korb - all rights reserved 10## 11## AutoOpts is available under any one of two licenses. The license 12## in use must be one of these two and the choice is under the control 13## of the user of the license. 14## 15## The GNU Lesser General Public License, version 3 or later 16## See the files "COPYING.lgplv3" and "COPYING.gplv3" 17## 18## The Modified Berkeley Software Distribution License 19## See the file "COPYING.mbsd" 20## 21## These files have the following sha256 sums: 22## 23## 8584710e9b04216a394078dc156b781d0b47e1729104d666658aecef8ee32e95 COPYING.gplv3 24## 4379e7444a0e2ce2b12dd6f5a52a27a4d02d39d247901d3285c88cf0d37f477b COPYING.lgplv3 25## 13aa749a5b0a454917a944ed8fffc530b784f5ead522b1aacaf4ec8aa55a6239 COPYING.mbsd 26 27# Produce a man page for section 1, 5 or 8 commands. 28# Which is selected via: -DMAN_SECTION=n 29# passed to the autogen invocation. "n" may have a suffix, if desired. 30# 31:+][+: 32 33(define head-line (lambda() 34 (sprintf ".TH %s %s \"%s\" \"%s\" \"%s\"\n.\\\"\n" 35 (get "prog-name") man-sect 36 (shell "date '+%d %b %Y'") package-text section-name) )) 37 38(define man-page #t) 39(out-push-new) :+][+: 40 41INCLUDE "mdoc-synopsis.tlib" :+][+: 42INCLUDE "cmd-doc.tlib" :+][+: 43 44INVOKE build-doc :+][+: 45 46 (shell (string-append 47 "fn='" (find-file "mdoc2man") "'\n" 48 "test -f ${fn} || die mdoc2man not found from $PWD\n" 49 "${fn} <<\\_EndOfMdoc_ || die ${fn} failed in $PWD\n" 50 (out-pop #t) 51 "\n_EndOfMdoc_" )) 52 53:+][+: 54 55(out-move (string-append (get "prog-name") "." 56 man-sect)) :+][+: 57 58agman-cmd.tpl ends here :+] 59