Giter Club home page Giter Club logo

dcss_henzell's Introduction

Henzell
-------

Henzell is the announcement and stats IRC bot for ##crawl on Freenode IRC.


Dependencies
------------

Henzell wants a slew of Perl modules for IRC, YAML parsing, DB
connectivity, etc. In addition the SQL query commands require several
Ruby gems. To install Henzell's dependencies, use:

   # ./install-henzell-libs

You can also install the Perl and Ruby dependencies independently:

   # ./install-perl-modules
   # gem install bundler && bundle install


Configuring Henzell
-------------------

Henzell can do several things based on how it's configured:

1. Make Crawl game announcements based on events in any number of
   Crawl logfiles and milestones files (if announce=1 and
   announce_channel is not empty).

2. Store new game events from any number of logfiles and milestone
   files into a PostgreSQL database (if sql_store=1).

3. Answer queries for games and milestones (if sql_queries=1).

You configure Henzell by supplying an rc/henzell.rc in the *directory from
which you run Henzell*. You can alternatively specify the rc filename
as a command-line option with:

perl henzell.pl --rc=some/path/to/myweirdrc

Some sample henzell rc files are included in this repository
(henzell.rc.cao, henzell.rc.sequell, henzell.rc.ircnet).


Henzell for announcements
-------------------------

If you're running a Crawl server and want Henzell to make
announcements, edit def.logs and def.stones and add entries for your
Crawl logfiles and milestone files. Enable announcements (announce=1
and announce_channel=##crawl) in your henzell.rc.

Also choose a unique abbreviation for your server. For instance,
crawl.akrasiac.org is abbreviated as cao, and this must be set both in
henzell.rc and in def.logs/def.stones to identify local logs:

In def.logs:

[local:cao]
/home/crawl/chroot/var/games/crawl04/saves/logfile

In henzell.rc:

bot_nick = NotTheRealHenzell
host = cao
announce = 1
announce_channel = ##crawl

This unique abbreviation is quite important if you're using sql_store=1.


Henzell for SQL queries
-----------------------

This is more complicated than a simple announcement bot:

1. Install PostgreSQL, create a database 'henzell' and a user 'henzell', and
   give the user access to the database with password 'henzell'.

2. In the 'henzell' database, install the PostgreSQL citext and orafce
   extensions by running (as an admin user):
      CREATE EXTENSION citext;
      CREATE EXTENSION orafce;

   citext is available as part of Postgres contrib; orafce is available at:
      http://orafce.projects.postgresql.org/

   Henzell needs the CITEXT extension for case-insensitive comparison
   and grouping and the orafce extension for the median aggregate function.

2. Set up the database schema as:

   Generate the schema:
   perl schema-gen.pl

   Create the tables:
   psql -U henzell henzell < henzell-schema.sql

3. Make sure def.logs and def.stones are set up correctly.

4. Run Henzell with an rc that includes:

   sql_store = 1
   sql_queries = 1
   commands_file = commands/commands-sequell.txt

If you want the bot to do both announcements and SQL queries, you must
merge the commands files into one big list of commands.

dcss_henzell's People

Contributors

chrisoelmueller avatar elliptic avatar flodiebold avatar greensnark avatar neilmoore avatar rwbarton avatar samb avatar zannick avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.