diff man/irccd-test.1 @ 845:00a4720c4874

doc: rewrite documentation in manual pages, closes #1674 Get rid of markdown documentation and the custom generator tools, instead use raw manual pages.
author David Demelier <markand@malikania.fr>
date Mon, 08 Jul 2019 16:15:57 +0200
parents
children 5e25439fe98d
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/man/irccd-test.1	Mon Jul 08 16:15:57 2019 +0200
@@ -0,0 +1,118 @@
+.\"
+.\" Copyright (c) 2013-2019 David Demelier <markand@malikania.fr>
+.\"
+.\" Permission to use, copy, modify, and/or distribute this software for any
+.\" purpose with or without fee is hereby granted, provided that the above
+.\" copyright notice and this permission notice appear in all copies.
+.\"
+.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+.\"
+.Dd @IRCCD_MAN_DATE@
+.Dt IRCCD-TEST 1
+.Os
+.\" NAME
+.Sh NAME
+.Nm irccd-test
+.Nd irccd plugin tester
+.\" SYNOPSIS
+.Sh SYNOPSIS
+.Nm irccd-test
+.Op Fl c Ar config
+.Ar id|path
+.\" DESCRIPTION
+.Sh DESCRIPTION
+The
+.Nm irccd-test
+program is a simple utility to test plugins on the command line.
+.Pp
+You can test a global plugin by just specifying plugin's
+.Ar id
+or using a full filesystem
+.Ar path .
+.Pp
+It opens a prompt that waits for user input, each line consist of a specific
+plugin event. These are mostly the same as the Javascript API offers.
+.Pp
+If compiled with libedit library, the prompt offers basic completion for the
+plugin events.
+.Pp
+When a event requires a server, a fake debugging server is created if it does
+not exists already. That fake server simply prints every command on the command
+line instead of sending them through IRC.
+.\" COMMANDS
+.Sh COMMANDS
+The following commands are allowed as input:
+.Bl -bullet -compact
+.It
+.Cm onCommand
+.Ar server origin channel message
+.It
+.Cm onConnect
+.Ar server
+.It
+.Cm onInvite
+.Ar server origin channel target
+.It
+.Cm onJoin
+.Ar server origin channel
+.It
+.Cm onKick
+.Ar server origin channel reason
+.It
+.Cm onLoad
+.It
+.Cm onMe
+.Ar server origin channel message
+.It
+.Cm onMessage
+.Ar server origin channel message
+.It
+.Cm onMode
+.Ar server origin channel mode limit user mask
+.It
+.Cm onNames
+.Ar server channel nick1 nick2 nickN
+.It
+.Cm onNick
+.Ar server origin nickname
+.It
+.Cm onNotice
+.Ar server origin channel nickname
+.It
+.Cm onPart
+.Ar server origin channel reason
+.It
+.Cm onReload
+.It
+.Cm onTopic
+.Ar server origin channel topic
+.It
+.Cm onUnload
+.It
+.Cm onWhois
+.Ar server nick user host realname chan1 chan2 chanN
+.El
+.\" EXAMPLES
+.Sh EXAMPLES
+Example with a local plugin:
+.Bd -literal
+$ irccd-test test.js
+> onLoad
+> onMessage localhost francis #general Bonjour
+.Ed
+.Pp
+Example with a global plugin:
+.Bd -literal
+$ irccd-test hangman
+> onLoad
+> onCommand localhost francis #general
+.Ed
+.\" SEE ALSO
+.Sh SEE ALSO
+.Xr irccd 1