Compare commits

...

No commits in common. "292747216bb8973fa19c889758263906f44bdd4d" and "326968d8c8a1c5934a54c746eadca52b1700917e" have entirely different histories.

5 changed files with 22 additions and 2 deletions

View File

@ -0,0 +1,20 @@
# javapool
## Install
- Install [Nim], then build the executable: `nim c -d:release -d:ssl bot.nim`
- Copy the `.config-sample/` directory and rename it to `.config`.
- Edit .config/config.json` to insert the server connection details, and
`.config/codes.json` to add or remove the service codes to which the bot will
respond.
- Run the bot: `./bot`
- To run the bot in the background, you can use a service unit manager like
systemd (see examples of service files in `init-scripts/`).
[Nim]: https://nim-lang.org/install.html

View File

@ -191,7 +191,7 @@ proc parseMessage*(prefix: string, str: string): Message =
var var
msg: Message msg: Message
strLen: int strLen: int
if find(str, "PRIVMSG") != -1 and find(str, "!") != -1: if find(str, "PRIVMSG") != -1 and find(str, ":" & prefix) != -1:
# code # code
strLen = split(str)[3].len() - 1 strLen = split(str)[3].len() - 1
var cPLen = prefix.len() var cPLen = prefix.len()

View File

@ -1,6 +1,6 @@
# Readme # Readme
Cirrus is a IRC bot script. Cirrus is a mini IRC bot script.
## License ## License