• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

contrib/systemwide-patch/H07-Jun-2005-4640

debian/H07-May-2022-698518

lang/H07-Jun-2005-421320

lib/Onis/H07-Jun-2005-8,3975,779

reports/H07-Jun-2005-1,099905

themes/H07-Jun-2005-3321

var/H07-Jun-2005-

CHANGELOGH A D07-Jun-200510.2 KiB278210

COPYINGH A D07-Jun-200517.6 KiB341281

FAQH A D07-Jun-20051.3 KiB3527

MANIFESTH A D07-Jun-20051.6 KiB6564

READMEH A D07-Jun-20057.9 KiB189158

THANKSH A D07-Jun-2005678 3222

TODOH A D07-Jun-20051 KiB2821

onisH A D07-Jun-200512.8 KiB570264

onis.confH A D07-Jun-20056.4 KiB18032

onis.specH A D07-Jun-20052.3 KiB7864

users.confH A D07-Jun-2005353 160

README

1 onis 0.8.2 - README - 2005-06-07
2==================================
3http://verplant.org/onis/
4
5
6 Table of Contents
7-------------------
8 1. Brief description
9 2. Setting it up
10 3. Using it
11 4. Language Files
12 5. User configuration
13
14
15 1. Brief description
16======================
17``onis'' is a small perl-script that generates html-files out of your
18irc-logs that contain some statistic information about what's going on on
19that channel. For a sample look at the onis-homepage.
20
21
22 2. Setting it up
23==================
24Just follow the example in 'config'. Please make sure to edit it!
25
26
27 3. Using it
28=============
29Once set up right you can run onis with a command along these lines:
30
31octo@leeloo:~/onis-0.5.1 $ ./onis --output reports/channel.html my-logs/*
32
33 3.1 Timestamps
34----------------
35Timestamps in the logfiles are an absolute requirement. If your logfiles
36don't have timestamps you can't use onis with them. So enable them now ;)
37
38 3.2 Persistency
39-----------------
40Persistency is there for one reason: speed. It's simply faster to load
41already-parsed data into memory than to re-parse it again. However, since
42you start with nothing the first run will take as long as ever.
43
44Also, since this feature isn't easy for the program there are some issues
45which might be confusing for the user. First, the program has to `know' if
46the saved data is good and fresh and useable. It does so by comparing the
47current configuration and the configuration saved with the old data. So if
48you add or remove a plugin, change the ``min_word_length'' setting or edit
49the user configuration your old-data will not be re-used and overwritten.
50
51The second issue effects only the ``Eggdrop'' parser: For persistency to
52work the program has to determine the ABSOLUTE time of each line (i.e. the
53date and time to at least the accuracy of one minute). The eggdrop version
54I use (1.6.15) saves such a date/time entry at the end of each logfile.
55That means that as long as the end of the file isn't written (i.e. the
56whole day it covers) onis is unable to determine the date of that file. So
57running onis every 15 minutes changes the random quotes picked but that's
58it. It will not add the latest file unless the date is written which
59happends at midnight.
60
61 3.3 Purge Logs
62----------------
63Please be very carefull with this option. This is a new, unstable and
64hardly tested feature! There may be bugs and they may delete your logfiles
65(if you use this feature, that is). Don't yell at me if you accidentially
66get rid of two years worth of logs.. It is possible to use ``purge_logs''
67without activating ``use_persistency''. That's your own damn fault.
68You have been warned.
69
70There are two modes of operation:
71- ``truncate'' deletes the content of a parsed logfile. The logfile itself
72               survives, so that clients that don't create new logs
73	       automatically don't fall on their face.
74- ``delete''   deletes the file itself. That might come in handy when a
75               client creates a new logfile every day.
76
77For both modes it is essential that onis can open the logfiles in
78write-mode. It _could_ delete files without the write-bit set, but it
79won't for obvious reasons.
80
81 3.4 Data aging
82----------------
83This is a experimental feature introduced in 0.7.0: Since there is a lot
84of absolutely useless data in the persistency files, the data gathered now
85ages over the time. This may result in weird effects and I am not quite
86sure it works as expected, so I'll have an eye on it and hopefully improve
87it as needed ;) Anyways, here's what I do:
88  Idents have a line-counter. This counter is decremented one tenth per
89run and afterwards rounded down. This means, that you have to write at
90very least one line every day. If an ident writes 120 lines, it will be
91deleted after 30 runs (one month, when run dayly) unless he/she writes
92some lines in the meantime.. Obviously this might be a problem for persons
93who run onis hourly..
94  The nicks and words age a little differently: For everyitem there is an
95``age'' and a ``ttl'' (time to life) setting. With every occurence the age
96is reset to zero and ttl increased. At the end of each session ``ttl'' is
97decreased by ``age'' and afterwards ``age'' is increased by one. If
98``ttl'' becomes smaller than one the record is deleted.
99  In the future I will propably switch to keeping a timestamp and
100calculating days, rather than counting runs, but I wanted to try this
101approach first..
102
103
104 4. Language Files
105===================
106onis 0.4.3 has a first experimental support for translations. I don't
107speak any languages other than english and german so I'm hoping for
108volunteers to send in more translations. The language-files are very very
109simple, so my mom _could_ create them ;) I'll use a simple example:
110
111-- BEGIN: fooish.lang --
112# Language file for Fooish
113"foobar": "translation"; # Should be fixed!
114"Something": "Translation one", "Translation two";
115-- END:   fooish.lang --
116
117One can observe the following rules:
118- Everything outside of double-quotes is ignored. Colons and semi-colons
119  should be added anyways.
120- Everything after an ``hash'' (`#') (up to the end of the line) is a
121  comment and will be ignored. (Except when inside quotes, of course)
122- The first string in a line is the original, all strings after that are
123  translations. (If there is more than one translation for a given phrase
124  a random one will be choosen at runtime)
125- If no translation can bve found the original string will be used.
126- The string provided here will be fed to a printf-call. DO NOT CHANGE any
127  of those `%s', `%u', `%.1f' etc. thingies, since they will be replaced
128  by whatever makes sense.
129
130If you have any problems with this, please let me know.
131
132
133 5. User configuration
134=======================
135Starting with version 0.4.7 onis offers the ability to configure (or
136hardcode) a user configuration. The user configuration is able to:
137- map one or more hostmasks to a user,
138- specify a realname for a user,
139- add a link to the user's homepage and
140- add an image to the user.
141- ignore users
142
143The configuration file (default: ``users.conf'') has the following syntax:
144
145-- BEGIN: users.conf --
146# User configuration for #channel
147nickname
148{
149	name:	Realname;
150	host:	*!real*@*.provider.com;
151	link:	http://homepage.url/;
152	image:	http://homepage.url/my_pic.png;
153}
154-- END:   users.conf --
155
156As you can see each record starts with a username followed by curly
157brackets which contain the settings for this username. The settings are in
158the form ``key: value;'' and valid keys (as of now) are ``name'',
159``host'', ``link'' and ``image''. Each setting can come in any order and
160as often as needed. If more than one `name', `link' or `image' is set one
161will be chosen randomly at runtime.
162- ``name'' Sets the realname for this nick. This name is set as ``title''
163  for the call containing the username, which some browsers display as
164  tooltip.
165- ``host'' sets the hostmask for this username. You can use `*' and `?'
166  which are interpreted as bash-like wildcards, i.e. `*' is a string of
167  any length (including empty) and `?' is any character (which must be
168  present). Oh, and the user-flags (like `~', `+', etc) are removed before
169  matching against this string, so you should not specify them here.
170- ``link'' sets the users homepage. A link to this homepage will be
171  included in the statistics page.
172- ``image'' specifies the URL of an image which will be displayed in later
173  versions. The URL is inserted as-is without ANY checking. This means
174  that it you enter a relative-URL it must be relative to the
175  output-file's location.
176
177There is one special user, ``ignore''. Every nick that matches the
178enclosed ``host'' settings will be ignored.
179
180Everything after a hash-sign `#' up to the end of the line is considered a
181comment and is removed before processing the config. But I think you've
182guessed that ;)
183
184Keep in mind that changing the user configuration renders your persistency
185file useless and it (the persistency file) will be deleted the next time
186you run onis! (Read section 3.2!)
187--
188octo (at verplant.org)
189