Update documentation
authorMikael Berthe <mikael@lilotux.net>
Sun, 14 May 2017 12:04:43 +0200
changeset 141 abaf660dc3fc
parent 140 92842a4f5f8b
child 142 b0d55f7fddeb
Update documentation
README.md
templates/README.md
--- a/README.md	Sun May 14 11:44:14 2017 +0200
+++ b/README.md	Sun May 14 12:04:43 2017 +0200
@@ -26,9 +26,11 @@
 
 ### Download
 
-Check the [Release page](https://github.com/McKael/madonctl/releases) for some pre-built binaries.
+Check the [Release page](https://github.com/McKael/madonctl/releases) for some
+pre-built binaries.
 
-More pre-built binaries are available from the [Homepage](https://lilotux.net/~mikael/pub/madonctl/) (development version and builds for a few other platforms).
+More pre-built binaries might be available from the [Homepage](https://lilotux.net/~mikael/pub/madonctl/)
+(development version and builds for a few other platforms).
 
 ## Usage
 
@@ -55,12 +57,14 @@
 
 ### Usage
 
-The complete list of commands is available in the online help (`madonctl help`, `madonctl command --help`...)
-or in the [manpages](https://lilotux.net/~mikael/pub/madonctl/manual/html/).\
-The [Homepage](https://lilotux.net/~mikael/pub/madonctl/) also contains a plain list of commands.
+The complete list of commands is available in the online help (`madonctl help`,
+`madonctl command --help`...) or in the
+[manpages](https://lilotux.net/~mikael/pub/madonctl/manual/html/).
 
 ### Examples
 
+This is a non-exhaustive list of commands, showing how madonctl works.
+
 To post a simple "toot":
 ``` sh
 % madonctl toot "Hello, World"
@@ -258,6 +262,7 @@
 
 ## References
 
+- [madonctl manpages](https://lilotux.net/~mikael/pub/madonctl/manual/html/)
 - [madon](https://github.com/McKael/madon), the Go library for Mastodon API
 - [Mastodon API documentation](https://github.com/tootsuite/documentation/blob/master/Using-the-API/API.md)
 - [Mastodon repository](https://github.com/tootsuite/mastodon)
--- a/templates/README.md	Sun May 14 11:44:14 2017 +0200
+++ b/templates/README.md	Sun May 14 12:04:43 2017 +0200
@@ -40,13 +40,18 @@
 ### Template development
 
 Here's a list of available commands (please check the Go template documentation for the built-in functions):
-- fromunix UNIXTIMESTAMP *converts from UNIX timestampto date*
-- tolocal TEXTRFC3339DATE *converts a RFC3339 date string to a local time*
-- fromhtml HTMLTEXT *converts HTML to plain text*
-- wrap TEXT *rewrap text, with indent and max width*
-- trim TEXT *trims text whitespace*
-- color COLORSPEC *sends an ANSI color code sequence*\
-  COLORSPEC is a string with the following format: `[FGCOLOR][,BGCOLOR[,STYLE]]` or `reset`.
+
+Function | Description
+-------- | -----------
+fromunix UNIXTIMESTAMP  | converts from UNIX timestampto date
+tolocal TEXTRFC3339DATE | converts a RFC3339 date string to a local time
+fromhtml HTMLTEXT       | converts HTML to plain text
+wrap TEXT       | rewrap text, with indent and max width
+trim TEXT       | trims text whitespace
+color COLORSPEC | sends an ANSI color code sequence
+
+*COLORSPEC* is a string with the following format:
+`[FGCOLOR][,BGCOLOR[,STYLE]]` or `reset`.
 
 Examples:
 
@@ -57,7 +62,3 @@
 
   Message: {{color "blue"}}{{.content | fromhtml | wrap "    " 80 | trim}}{{color "reset"}}
 ```
-
-Note that the _wrap_ implementation might change in the future; currently it is
-paragraph-based, not line-based, and the result can be surprising after
-_fromhtml_ (carriage returns are ignored).