Giter Site home page Giter Site logo

frogging101 / irclog2html Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mgedmin/irclog2html

0.0 2.0 0.0 358 KB

Convert IRC logs to HTML

Home Page: http://mg.pov.lt/irclog2html/

License: GNU General Public License v2.0

Makefile 2.00% Python 90.34% Perl 6.09% CSS 1.57%

irclog2html's Introduction

irclog2html

Converts IRC log files to HTML with pretty colours.

Quick start

Installation:

pip install irclog2html

Quick usage for a single log file:

irclog2html --help
irclog2html filename.log                  (produces filename.log.html)

Mass-conversion of logs (one file per day, with YYYY-MM-DD in the filename) with next/prev links, with mtime checks, usable from cron:

logs2html directory/     (looks for *.log and *.log.gz, produces *.log.html)

Configuration files

Since you probably don't want to keep specifying the same options on the command line every time you run logs2html, you can create a config file. For example:

-t 'IRC logs for #mychannel'
-p 'IRC logs for #mychannel for '
# the following needs some extra Apache setup to enable the CGI script
--searchbox
# where we keep the logs
/full/path/to/directory/

Use it like this:

logs2html -c /path/to/mychannel.conf

Lines starting with a # are ignored. Other lines are interpreted as command-line options.

The order matters: options on the command line before the -c FILE will be overriden by option in the config file. Options specified after -c FILE will override the options in the config file.

You can include more than one config file by repeating -c FILE. You can include config files from other config files. You can even create loops of config files and then watch and laugh manically as logs2html sits there burning your CPU.

CGI script for log searching

Warning

The script can be easily abused to cause a denial of service attack; it parses all log files every time you perform a search.

You can generate search boxes on IRC log pages by passing the --searchbox option to logs2html. Here's an example Apache config snippet that makes it work:

RewriteRule ^/my-irclog/search/$ /my-irclog/search [R,L]
ScriptAlias /my-irclog/search /usr/local/bin/irclogsearch
<Location /my-irclog/search>
  SetEnv IRCLOG_LOCATION "/var/www/my-irclog/"
  # Uncomment the following if your log files use a different format
  #SetEnv IRCLOG_GLOB "*.log.????-??-??"
  # (this will also automatically handle *.log.????-??-??.gz)
</Location>

Misc

Website: http://mg.pov.lt/irclog2html/

Bug tracker: https://github.com/mgedmin/irclog2html/issues or https://bugs.launchpad.net/irclog2html

Licence: GPL v2 or later (http://www.gnu.org/copyleft/gpl.html)

buildstatus appveyor coverage

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.