Add manpage (skeleton).
continuous-integration/drone/push Build is failing Details

This commit is contained in:
tastytea 2019-12-16 15:23:06 +01:00
parent 2321802575
commit 5495acbfa2
Signed by: tastytea
GPG Key ID: CFC39497F1B26E07
4 changed files with 80 additions and 1 deletions

View File

@ -104,7 +104,7 @@ plus:
|===========================================================
| Code | Explanation
| 1 | Could not send post for unknown reasons
| 1 | Could not send post for unknown reasons.
|===========================================================
include::{uri-base}/raw/branch/main/CONTRIBUTING.adoc[]

13
man/CMakeLists.txt Normal file
View File

@ -0,0 +1,13 @@
include(GNUInstallDirs)
add_custom_command(
OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}.1"
WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}"
DEPENDS "${PROJECT_NAME}.1.adoc"
COMMAND "${PROJECT_SOURCE_DIR}/man/build_manpage.sh"
ARGS "${PROJECT_VERSION}")
add_custom_target(man ALL DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}.1")
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}.1
DESTINATION ${CMAKE_INSTALL_MANDIR}/man1)

13
man/build_manpage.sh Executable file
View File

@ -0,0 +1,13 @@
#!/bin/sh
name="mastorss"
if [ -n "${1}" ]; then
dir=$(dirname "${0}")
version=${1}
cp -vf "${dir}/${name}.1.adoc" .
sed -Ei "s/(Revision: +)[0-9]+\.[0-9]\.[0-9]/\1${version}/" "${name}.1.adoc"
a2x --doctype manpage --format manpage --no-xmllint "${name}.1.adoc"
else
echo "usage: ${0} VERSION" >&2
fi

53
man/mastorss.1.adoc Normal file
View File

@ -0,0 +1,53 @@
= mastorss(1)
:doctype: manpage
:Author: tastytea
:Email: tastytea@tastytea.de
:Date: 2019-12-16
:Revision: 0.0.0
:man source: mastorss
:man manual: General Commands Manual
== NAME
mastorss - Another RSS to Mastodon bot.
== SYNOPSIS
*mastorss* profile
// == DESCRIPTION
// == OPTIONS
// == EXAMPLES
// == PROTOCOL SUPPORT
// Currently only HTTP and HTTPS are supported.
// == PROXY SUPPORT
== FILES
* *Configuration file directory*: `${XDG_CONFIG_HOME}/mastorss/`
`${XDG_CONFIG_HOME}` is usually `~/.config`.
== ERROR CODES
[cols=">,<"]
|===========================================================
| Code | Explanation
| 1 | Could not send post for unknown reasons.
|===========================================================
== SEE ALSO
*crontab*(1), *crontab*(5)
== REPORTING BUGS
Bugtracker: https://schlomp.space/tastytea/mastorss/issues
E-mail: tastytea@tastytea.de