eleksir
e38726a1f2
Move admin commands to dedicated module, allow use admin stuff only to admins of chat
2021-02-23 14:02:56 +03:00
eleksir
041ab3efeb
Fix fortune src filename check and another pack of style and natural language fixes
2021-02-09 00:57:08 +03:00
eleksir
626feed7db
Use markdown + quote for fortune, use irand() instead of int (rand())
2021-02-07 18:37:30 +03:00
eleksir
35148838f9
Add commands !fish !fishing !рыба !рыбалка !рыбка, tweak archeologist.pm
...
* Rearrange .gitignore
+ Add fisher.pm with fishing commands
* Max probability in archeologist.pm should not exceed 100%
2021-02-07 13:51:55 +03:00
eleksir
a1d238949f
Refactor code
...
* move plugins out of botlib.pm
* use make_path instead of mkpath
* squash some bugs
* update .gitignore
* use more correct randomizer, rather than perl own rand()
* coding style fixes
2021-02-06 19:06:59 +03:00
eleksir
3787bb3073
Implement !cat and !кис commands
2020-12-20 15:30:19 +03:00
eleksir
0cfecd72b3
Implement fuzzy matching in bred answer checking to avoid repeating input phrase.
2020-12-20 14:43:32 +03:00
eleksir
8bbe3b5d18
Make use of replyMd() in newcommer greet, add botsleep() utility sub
2020-12-19 17:34:20 +03:00
eleksir
10fc353924
Move !help to botlib.pm
2020-12-19 17:25:20 +03:00
eleksir
4a312e23d1
Add replyMd() to message object, implement canTalk() check in Teapot lib, re-arrange code
2020-12-19 17:15:01 +03:00
eleksir
cc43141d20
Implement !dig and !копать commands, fix typo in help message
2020-12-19 01:22:51 +03:00
eleksir
e861f5420b
Implement logging via Log::Any, cleanup, remove logger()
2020-12-13 16:23:16 +03:00
eleksir
0256f6b45b
Trim() phrase before putting it to karma
2020-12-01 19:47:13 +03:00
eleksir
63304d6bb9
First run fixes for fortune commands, also fixes for karma
2020-11-22 17:43:05 +03:00
eleksir
ad37a349c1
Implement fortune commands set
...
+ !f, !ф, !fortune, !фортунка - show random phrase from fortune_mod db
+ !f 1, !ф 1, !fortune 1, !фортунка 1 - show fortune in chat at ~8 am
+ !f 0, !ф 0, !fortune 0, !фортунка 0 - do not show fortune in the morning
+ !f ?, !ф ?, !fortune ?, !фортунка ? - query morning fortune status
2020-11-22 15:17:34 +03:00
eleksir
e448225a7b
Implement !friday and !пятница commands
2020-11-21 15:47:53 +03:00
eleksir
ac8c0f17de
Fix karma, fix private commands, actually add !помощь command
...
* Fix zero length !karma parsing
* In private chat commands not working except !help
* Miss to add !помощь to parser, so it was noop
2020-11-17 01:51:20 +03:00
eleksir
4bf814c473
Move chat commands to botlib.pm, implement !version, !ver, !версия command
2020-11-15 21:43:41 +03:00
eleksir
9c629a8dbc
Use perlcritic to lint the code, make it happy
2020-10-19 18:01:47 +03:00
eleksir
0d0b8bb4c2
Add one more common phrase
2020-10-03 19:12:05 +03:00
eleksir
1567fbe0db
New logging, handle bot quote in groups, newcommer greets reworked
...
+ More sane and verbose logging
* Newcommer greet now should now mention newcommer
+ If someone in group quote bot's phrase, bot should answer
* Move some subs related to framework to telegramlib.pm
* Handle (log only for now) sent media - documents, stickers, photos in public chats (voice, audio, video still unhandled)
2020-09-26 21:36:37 +03:00
eleksir
f0d8e90441
Add date to logger() messages like in bsd syslog
2020-09-21 02:11:47 +03:00
eleksir
9461042ec4
Use botlib own trim()
2020-09-19 14:43:48 +03:00
eleksir
7218c7d510
Require perl-5.18.0 to properly lc() and uc() unicode strings
2020-09-11 11:20:21 +03:00
eleksir
c8819676e7
Add more random phrases
2020-09-11 11:20:21 +03:00
eleksir
c3d2d76ad4
Add trim() and random pre-generated phrase answer
...
+ Add php-inspired trim() function
+ Add randomCommonPhrase() in order not to repeat given sentense if unable to produce relevant phrase from vocabulary generator
2020-09-11 11:20:21 +03:00
eleksir
20bbfab333
Add help, debug log, fix pid file creation
...
+ Add help in group chat
+ Add debug log ability
* A bit of cleanup
* Check against start uid rather than effective uid when creating pid-file
2020-09-11 11:20:21 +03:00
eleksir
2bf710aeb7
Initial commit. Split bot from myapi as separate application.
2020-09-05 22:50:10 +03:00