https://github.com/twm/carrotbot
IRC bot which espouses root-vegetable related "facts".
https://github.com/twm/carrotbot
Last synced: 3 months ago
JSON representation
IRC bot which espouses root-vegetable related "facts".
- Host: GitHub
- URL: https://github.com/twm/carrotbot
- Owner: twm
- License: gpl-3.0
- Created: 2013-07-05T05:56:45.000Z (almost 12 years ago)
- Default Branch: master
- Last Pushed: 2016-12-13T01:34:41.000Z (over 8 years ago)
- Last Synced: 2025-01-19T16:49:27.641Z (5 months ago)
- Language: Go
- Size: 1.15 MB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.rst
- License: COPYING
Awesome Lists containing this project
README
=========
carrotbot
=========An IRC bot which espouses root-vegetable related "facts". This version
supports the ".carrot" and ".turnip" commands.Building
--------Carrotbot is written in Go using the `GoIRC library `.
Dependencies are managed with `Glide ` and the ``vendor`` directory is checked in.
To build you will need a functioning Go install (I use 1.7, but older versions will likely work) and ``GOPATH`` set.
Then::go build .
Quote Databases
---------------Two formats are supported for quote databases: a newline-delimited UTF-8 text
file, or JSON. The filetype of the database is indicated by the filename
extension, either ".txt" or ".json".The JSON format is compatible with the output of `twistorpy
`_. It is an array of object literals
with at least "id" (integer) and "text" (string) properties. For example, to
generate one for `@RealCarrotFacts `::$ python2.7 twistorpy.py RealCarrotFacts carrots.json
Updates can be done thereafter with the same command.
Configuration
-------------Configuration is done via a file in the TOML format, by default
``config.toml``, but configurable via the ``-config`` flag. An example::[irc]
server = "irc.freenode.net:7000"
ssl = true
user = "fontofwisdom"
password = "supersekrit"
nick = "fontofwisdom"
name = "Font of Wisdom"
channel = "#your-channel"[facts]
carrots = "carrots.json"
turnips = "turnips.txt"[logging]
# log to stderr rather than the systemd journal
journal = false
# debug logs include everything said in the channel
debug = truecarrotbot has only been tested against Freenode's servers.