Added manpage template.

This commit is contained in:
tastytea 2019-03-23 10:44:15 +01:00
parent 64e8cf8c8b
commit 7e41fafd50
2 changed files with 47 additions and 2 deletions

42
auto-insert/manpage.adoc Normal file
View File

@ -0,0 +1,42 @@
= ${1:`(file-name-nondirectory (file-name-sans-extension (file-name-sans-extension (buffer-file-name))))`}(`(file-name-extension (file-name-sans-extension (buffer-file-name)))`)
:Author: `user-full-name`
:Email: `user-mail-address`
:Date: `(format-time-string "%Y-%m-%d")`
:Revision: 0.0.0
:man source: $1
:man version: {revision}
:man manual: General Commands Manual
== NAME
$1 - [DESCRIPTION]
== SYNOPSIS
*$1* [_file_|_--version_] [_arguments_]
== DESCRIPTION
== OPTIONS
[frame="none",grid="none"]
|===
|*--version* | Print version, copyright and license.
|===
== EXAMPLES
== FILES
[frame="none",grid="none",cols=">,<"]
|======
| Configuration file: | \`\${XDG_CONFIG_HOME}/$1.cfg\`
|======
\`\${XDG_CONFIG_HOME}\` is usually \`~/.config\`.
== REPORTING BUGS
Bugtracker: https://schlomp.space/tastytea/$1/issues
E-mail: `user-mail-address`

View File

@ -1,5 +1,5 @@
;;; init.el --- tastytea's Emacs init file.
;;; Time-stamp: <2019-03-23 08:44:55 CET>
;;; Time-stamp: <2019-03-23 10:16:47 CET>
;;; Commentary:
;;; I am using this file with Emacs 26, but most of it will probably work with
@ -596,7 +596,10 @@
["cpp" my/autoinsert-yas-expand]))
(add-to-list 'auto-insert-alist
'(("\\.\\(hpp\\|hh\\|hxx\\|h\\+\\+\\)\\'" . "C++ header") .
["hpp" my/autoinsert-yas-expand]))
["hpp" my/autoinsert-yas-expand]))
(add-to-list 'auto-insert-alist
'(("\\.[1-9]\\.adoc\\'" . "AsciiDoc manpage") .
["manpage.adoc" my/autoinsert-yas-expand]))
:custom
(auto-insert-directory (concat user-emacs-directory "auto-insert"))
(auto-insert-query nil) ; Don't ask before inserting.