view plugins/logger/logger.7 @ 1196:fa99335587ad release-4.0

misc: added tag 4.0.4 for changeset 43e3f7a4045b
author David Demelier <markand@malikania.fr>
date Thu, 03 Aug 2023 21:24:40 +0200
parents f06e9761cc90
children 1845a0509a93
line wrap: on
line source

.\"
.\" Copyright (c) 2013-2022 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-PLUGIN-LOGGER 7
.Os
.\" NAME
.Sh NAME
.Nm logger
.Nd irccd logger plugin
.\" DESCRIPTION
.Sh DESCRIPTION
The
.Nm
plugin may be used to log everything you want. It supports the following events:
.Bl -bullet -compact
.It
onJoin.
.It
onKick.
.It
onMe.
.It
onMessage.
.It
onMode.
.It
onNotice.
.It
onPart.
.It
onTopic.
.El
.\" INSTALLATION
.Sh INSTALLATION
The plugin
.Nm
is distributed with irccd. To enable it add it into your
.Xr irccd.conf 5
configuration file.
.Pp
.Bd -literal -offset indent
plugin "logger"
.Ed
.\" USAGE
.Sh USAGE
The
.Nm
plugin has no direct commands.
.\" CONFIGURATION
.Sh CONFIGURATION
The plugin
.Nm
supports the following configuration properties:
.Bl -tag -width "file (string)"
.It Va file No (string)
The path to the file where to store logs. Keywords:
.Em channel , server , (date) .
.El
.\" TEMPLATES
.Sh TEMPLATES
The plugin
.Nm
supports the following template properties:
.Bl -tag -width message
.It Va join
Format when someone joins a channel.
.It Va kick
Format when someone has been kicked. Keywords:
.Em reason , target .
.It Va me
Format for emote actions. Keywords:
.Em message .
.It Va message
Format for channel messages. Keywords:
.Em message .
.It Va mode
Format for user mode change. Keywords:
.Em mode , limit , user , mask .
.It Va notice
Format on private notices. Keywords:
.Em message .
.It Va part
Format when someone leaves a channel. Keywords:
.Em reason .
.It Va topic
Format when a topic is changed. Keywords:
.Em topic .
.El
.Pp
All templates support the following standard keywords:
.Em channel , nickname , origin , server .
.\" EXAMPLES
.Sh EXAMPLES
Example of configuration file:
.Bd -literal
plugin "logger" {
  config {
    "file" "/var/log/irccd/#{server}/%y/%m/%d/#{channel}.txt";
  }

  templates {
    "join" "user #{nickname} joined #{channel}";
  }
}
.Ed
.\" SEE ALSO
.Sh SEE ALSO
.Xr irccd 1 ,
.Xr irccd-templates 7