Commit Graph

280 Commits

Author SHA1 Message Date
Chris Sexton ef40d335eb Make testing great again! Add examples in counter
* Made bot.Bot an interface and added a mock with an in-memory database
for plugins to use.
* Remove logger nonsense
* Rename Counter New
2016-03-30 12:41:22 -04:00
Chris Sexton a34afa97ad Switch web query to a regex 2016-03-29 12:34:04 -04:00
Chris Sexton 9d9771c097 Enable web interface 2016-03-29 10:20:44 -04:00
Chris Sexton de3aba210a Stop trying to process Untappd after it fails 2016-03-28 15:34:40 -04:00
Chris Sexton 0e69e58ff5 Fix goatse in talker
Note: This makes the goatse very Slack specific with preformatting and
newlines.
2016-03-25 15:10:56 -04:00
Chris Sexton 3cdb40ab5c Fix leftpad query 2016-03-25 12:42:21 -04:00
Chris Sexton a14a2b2e61 Yup. Leftpad. 2016-03-25 12:25:00 -04:00
Chris Sexton a829c94349 Add config values for your 2016-03-24 13:49:44 -04:00
Chris Sexton 762ec13780 Fixes #20: move plugins to their own pkgs 2016-03-24 13:32:40 -04:00
Chris Sexton 0eaadee120 Remove the beers table 2016-03-19 15:05:15 -04:00
Chris Sexton 15602defbc Merge branch 'counterstuff'
* counterstuff:
  Fix #19: Merge beers and counters
  Migrate to sqlx; modularize counters
  Move counter to its own package
  Fix a few minor govet issues
2016-03-19 14:30:22 -04:00
Chris Sexton 6938efc430 Fix #19: Merge beers and counters 2016-03-19 14:27:02 -04:00
Chris Sexton ae5d7dec2e Migrate to sqlx; modularize counters 2016-03-19 14:02:46 -04:00
Chris Sexton 28ccc4f0c2 Move counter to its own package 2016-03-19 11:44:27 -04:00
Chris Sexton b6d63f6432 Fix a few minor govet issues 2016-03-19 11:38:18 -04:00
Chris Sexton 92aa5a1214 Merge pull request #17 from chrissexton/fix-what-was-format
Change ID from nullable field to its value
2016-03-13 10:14:43 -04:00
Chris Sexton d7056e3ec7 Fix number of fields for counter inventory
Fixes #11
2016-03-13 10:13:41 -04:00
Chris Sexton e53e305653 Change ID from nullable field to its value 2016-03-13 09:55:48 -04:00
Chris Sexton df0fee0237 Fix untappd integration 2016-03-11 12:52:28 -05:00
Chris Sexton dc1239783e Initial slack worky worky 2016-03-10 21:11:52 -05:00
Chris Sexton d261fcc406 AlePale -> Catbase => velour 2016-01-17 13:00:44 -05:00
Chris Sexton 1d62e6173f Migrate remember to SQL 2016-01-17 12:45:21 -05:00
Chris Sexton 5b7fef27bb Fix talker crash, factoid printing, add TODO item 2016-01-17 12:45:21 -05:00
Chris Sexton 56c6d84813 Add TODO, small fix to factoid web interface 2016-01-17 12:45:07 -05:00
Chris Sexton c91f4a8535 Migrate factoids to SQL 2016-01-17 10:29:30 -05:00
Chris Sexton 88c2736f5a Fix bug with empty commands 2016-01-17 10:29:14 -05:00
Chris Sexton 72b71de10e Convert downtime to SQL 2016-01-15 13:37:54 -05:00
Chris Sexton 92e1ea5d42 Update first plugin for SQL 2016-01-15 11:54:09 -05:00
Chris Sexton 1e96546d62 Remove feed plugin 2016-01-15 10:33:02 -05:00
Chris Sexton 40ed53b120 Remove lisp plugin. There's no chance it works 2016-01-15 10:13:40 -05:00
Chris Sexton b345506e7f Fix beer plugin bugs 2016-01-15 09:44:22 -05:00
Chris Sexton 25f32918b1 Improve talker to disable nick length constraints 2016-01-15 09:43:31 -05:00
Chris Sexton 782d074bdf Get the bot online; make counters work
Mostly just silly stuff to get everything working.
2016-01-15 08:59:51 -05:00
Chris Sexton 1efa7ebcd4 Initial mongo->sqlite move
Tons of bugs, I'm sure. This commit  mostly gets the bot moving towards
SQLite. It builds, but many plugins have a log.Fatal to prevent their
use and it has not been tested.
2016-01-15 08:17:26 -05:00
Chris Sexton d298dac814 Fixes #30: Lowercasing the search 2014-04-20 21:12:08 -04:00
Chris Sexton 49939d62c0 Fixes #35: Remove dependency on count function
Using aggregation to check the largest count instead of basically doing
the same amount of work using a server side function. The bot should
install without incident for other users now.
2014-04-20 21:08:16 -04:00
Chris Sexton 04839d5d2e Hopefully fixs #54. Use HTTPS 2014-04-20 15:24:45 -04:00
Chris Sexton b9d4ce273f Added license to feed 2014-03-06 10:50:41 -05:00
Chris Sexton 00df26d004 Update admin.go
Remove space trimming.
2014-01-17 11:49:41 -05:00
Chris Sexton 00d0d8e069 Adding WIP feed plugin 2013-12-10 20:40:47 -05:00
Chris Sexton 7f093b003e Added AUTHORS file and info in all files.
Thanks to https://github.com/eaburns/license
2013-12-10 18:37:07 -05:00
Chris Sexton 95c8c36447 Make first filter a regexp 2013-12-10 18:24:05 -05:00
Chris Sexton 592adfb482 Adding the fucking switcher 2013-09-13 23:27:11 -04:00
Chris Sexton e56f2d7270 Reallowing is/are for fact entry 2013-09-04 21:56:03 -04:00
Chris Sexton 374ea3fc7f Removing some noisy debug output 2013-09-02 22:29:00 -04:00
Chris Sexton cfbe0dc4bc Small log fix 2013-08-31 23:41:15 -04:00
Chris Sexton 90b86aaf7d Removing an extra log entry 2013-08-31 23:34:23 -04:00
Chris Sexton 2acf375997 Fixing small remember bug (trim snips) 2013-08-31 23:33:15 -04:00
Chris Sexton 54899c74ca Fixes #1: Make quotes multiline 2013-08-31 23:05:00 -04:00
Chris Sexton 74a5647d2d Upping startup chime fact wait 2013-08-31 22:29:13 -04:00
Chris Sexton 1a41358d64 Activate beers only for certain channels (exclude control channel) 2013-08-31 22:24:46 -04:00
Chris Sexton 776d363595 Fixes #32: Make quote/remember case insensitive keywords 2013-08-31 22:24:10 -04:00
Chris Sexton b97886fdde Finishing a few things, still need to clean it up 2013-08-31 15:58:15 -04:00
Chris Sexton a9fcee9a34 Fixing empty BSON id issue 2013-08-31 15:57:30 -04:00
Chris Sexton 3a45156b9d Small fix to stop flooding 2013-08-31 00:24:55 -04:00
Chris Sexton 549ebc5f4e Moving untappd to check stream instead of user checkins 2013-08-31 00:11:54 -04:00
Chris Sexton 43a8bec86b Spit out a start up message to the chan 2013-08-27 21:52:27 -04:00
Chris Sexton f715ab93e1 Fixing unneeded panic issue! 2013-08-26 12:18:57 -04:00
Chris Sexton ff661b1d27 Fixing minor go vet issue 2013-08-25 23:44:30 -04:00
Chris Sexton f655366930 Fixes #39: Added lisp plugin 2013-07-04 18:39:18 -04:00
Chris Sexton 0acd004e59 Fixing self remembering problems stemming from lib change. 2013-06-17 00:04:10 -04:00
Chris Sexton a91ebde376 Fixing quoting split function... again 2013-06-16 23:44:24 -04:00
Chris Sexton bddd4038bb Added datatables to web interface 2013-06-16 23:23:58 -04:00
Chris Sexton eff200ee15 Fixing multi-channel factoid squirts. 2013-06-16 21:03:43 -04:00
Chris Sexton 276cc3e2fe Fixes #8
This may have some bugs. It's a bit impossible to test as my only Untappd info
is used up on the live bot. #YOLO!
2013-06-16 11:53:32 -04:00
Chris Sexton 8cf2b997a2 Fixes #13: UTC vs not UTC, I don't know which one is right, but let's pick one! 2013-06-01 21:58:20 -04:00
Chris Sexton be1739d316 Linkifying images in web site 2013-06-01 17:24:05 -04:00
Chris Sexton 79bec9fc21 Changing factoid random a bit to improve efficiency, added 'factoid' command for random fact 2013-06-01 16:46:16 -04:00
Chris Sexton 11feafbee0 Changing URLs to GET for sharing 2013-06-01 16:20:45 -04:00
Chris Sexton a87835b54a Fixes #21 2013-06-01 15:14:54 -04:00
Chris Sexton a086f2bc6e Fixing remember plugin 2013-06-01 15:00:57 -04:00
Chris Sexton 42e17ae755 Removing secondary URL 2013-06-01 14:40:06 -04:00
Chris Sexton b5003e82b5 Adding a regex to web find 2013-06-01 14:34:07 -04:00
Chris Sexton 38bfc59871 Fixes #15: Factoid interface is bangin 2013-06-01 14:17:13 -04:00
Chris Sexton 242be51029 Making the web interface a bit better 2013-06-01 13:29:12 -04:00
Chris Sexton edd941fe46 Initial (ugly) web interface 2013-06-01 13:10:33 -04:00
Chris Sexton 377de90c31 Fixes #19: Removing logging statements. 2013-05-09 18:31:48 -04:00
Chris Sexton 42c934f091 Fixes #10: Bot can quote and count himself 2013-05-07 20:08:18 -04:00
Chris Sexton 46fa81cd68 Making the counters aware of the bot itself. 2013-05-07 19:32:03 -04:00
Chris Sexton e8ff495c2f Actual width 2013-05-07 19:31:54 -04:00
Chris Sexton 8eb5a563fb Fixing column width in code formatting 2013-05-07 19:28:34 -04:00
Chris Sexton 5433f51508 Removing requirement that you not try to quote yourself.
Multiline quotes cannot reasonably enforce this policy.
2013-05-07 18:41:51 -04:00
Chris Sexton 14b0e02235 Fixing twitter import 2013-05-06 22:04:45 -04:00
Chris Sexton d87f7779ab Renaming project to reflect bot's actual name. 2013-05-06 01:11:54 -04:00
Chris Sexton ea60a899c7 Converting imports to github, added license & full readme 2013-05-06 01:11:54 -04:00
Chris Sexton cc58de580a Enabling new stuff 2013-05-06 01:11:53 -04:00
Chris Sexton 543526478e Embiggening the exclusions list 2013-05-06 01:11:53 -04:00
Chris Sexton 9b51ce79ba Taking care of obnoxious users calling first. 2013-05-06 01:11:53 -04:00
Chris Sexton ee1962b71c Adding ~= and =~ equality for factoids 2013-05-06 01:11:53 -04:00
Chris Sexton 340b7ee1ae Cleanup 2013-05-06 01:11:53 -04:00
Chris Sexton 80295590af Adding your plugin 2013-05-06 01:11:53 -04:00
Chris Sexton ebb76e5d9c Removed channel specific setting in talker 2013-05-06 01:11:53 -04:00
Chris Sexton 84e7001165 Added a say command to talker 2013-05-06 01:11:53 -04:00
Chris Sexton 7f4c9cf311 Simple twitter stuff, nothing working yet 2013-05-06 01:11:53 -04:00
Chris Sexton 0bc60518ee Adding twitter plugin (non-functional) 2013-05-06 01:11:52 -04:00
Chris Sexton aec9b8e743 Making first still reply 2013-05-06 01:11:52 -04:00
Chris Sexton ecdc1a7bb7 Adding support for QUIT 2013-05-06 01:11:52 -04:00
Chris Sexton a779dc4720 Added ball tattoo 2013-05-06 01:11:52 -04:00
Chris Sexton 535f1152eb Added goatse response 2013-05-06 01:11:52 -04:00
Chris Sexton ee15217634 Made first an announcing event 2013-05-06 01:11:52 -04:00
Chris Sexton 1e32fbf5ea Making downtime also remove reference to self 2013-05-06 01:11:52 -04:00
Chris Sexton 18dcb5884d Fixing a counter crash; trying to get more info on zombie downtime users 2013-05-06 01:11:52 -04:00
Chris Sexton 66a149f2e8 Making idle return true 2013-05-06 01:11:52 -04:00
Chris Sexton 0fc2f81f17 Reversing idle list and fixing insert/upsert 2013-05-06 01:11:52 -04:00
Chris Sexton 290d687be4 Added an idle command to list all idles 2013-05-06 01:11:52 -04:00
Chris Sexton de5c2f808c whoops, crashed when no first previously existed 2013-05-06 01:11:51 -04:00
Chris Sexton 6434b27626 Added first plugin to track who said first in the channel 2013-05-06 01:11:51 -04:00
Chris Sexton 64d0d73734 Oops, unused import 2013-05-06 01:11:51 -04:00
Chris Sexton 1a0747c3fa Removing idle code because it crashes 2013-05-06 01:11:51 -04:00
Chris Sexton 0144e7ee6a Changing parting function to split because | counts as a field 2013-05-06 01:11:51 -04:00
Chris Sexton b692f54346 Added properties for other users 2013-05-06 01:11:51 -04:00
Chris Sexton 544ed0e092 Fixing things to be 80-chars wide 2013-05-06 01:11:51 -04:00
Chris Sexton 130e471c8e Fixing insertion of counters for negative counts 2013-05-06 01:11:51 -04:00
Chris Sexton dbb2e97ba3 Small improvement to the situation with no counters 2013-05-06 01:11:51 -04:00
Chris Sexton 5fc0d31db5 Added an inspect and clear operation for counters 2013-05-06 01:11:51 -04:00
Chris Sexton 32b62cf18e Initial version of counters 2013-05-06 01:11:51 -04:00
Chris Sexton f31e43e3bc Accidentally killed ACTION at some point, adding back in 2013-05-06 01:11:50 -04:00
Chris Sexton 2cb0eba9b8 Added new mode support for downtime. Some of the additions in main are not needed, and it may be breaking other plugins. 2013-05-06 01:11:50 -04:00
Chris Sexton a27368af7e Removing extraneous println 2013-05-06 01:11:50 -04:00
Chris Sexton bcbd41a9b6 Fine tuning the dicks 2013-05-06 01:11:50 -04:00
Chris Sexton 66e2c8265d Added functionality for downtime tracking 2013-05-06 01:11:50 -04:00
Chris Sexton ce94b0b258 more dick checking 2013-05-06 01:11:50 -04:00
Chris Sexton a887d0bba9 fixing more things because of assholes 2013-05-06 01:11:50 -04:00
Chris Sexton 4af719fe5b fixing things because of assholes 2013-05-06 01:11:50 -04:00
Chris Sexton 5d90f7a920 Check errors 2013-05-06 01:11:50 -04:00
Chris Sexton ae42e62872 Fixed the name of the bot to always be current (could remove from config.json) 2013-05-06 01:11:50 -04:00
Chris Sexton 8ffac9291b Whoops, we want nicks not users 2013-05-06 01:11:50 -04:00
Chris Sexton 015a4018fe Added a beers-- action 2013-05-06 01:11:49 -04:00
Chris Sexton fbb4250ab7 Fixing some output issues with the dice 2013-05-06 01:11:49 -04:00
Chris Sexton 4280440028 Added die roller, fixed bot command addressing. 2013-05-06 01:11:49 -04:00
Chris Sexton 1099b66492 Fuck Untappd and their representation of empty items in JSON. Just don't include
the fucking field if you don't have data for it!
2013-05-06 01:11:49 -04:00
Chris Sexton 0552c5048d Moved welcome messages to config file for easier updating 2013-05-06 01:11:49 -04:00
Chris Sexton 172567004a Fixed the replacer to ignore "!" on secondary factoid searches. 2013-05-06 01:11:49 -04:00
Chris Sexton c0e41f6940 Fixed the punctuation remover 2013-05-06 01:11:49 -04:00
Chris Sexton 57138b507c Introduced a bug in merge, nick vs user: nick 2013-05-06 01:11:49 -04:00
Chris Sexton acdd5d7403 added 'bourbon counter', heh 2013-05-06 01:11:49 -04:00
Chris Sexton c8f999ac9d Added commetn to untappd checkin 2013-05-06 01:11:48 -04:00
Chris Sexton a05252a2b0 Moved sleep back to the beginning of the for so that he wouldn't spit beers out too quickly on start 2013-05-06 01:11:48 -04:00
Chris Sexton 62bef551a6 Fixed offset checking (broken on Untappd's end 2013-05-06 01:11:48 -04:00
Chris Sexton 396992f838 mistyped the ' key 2013-05-06 01:11:48 -04:00
Chris Sexton 522a1f1c35 testing new remember with fallback 2013-05-06 01:11:48 -04:00
Chris Sexton 7cba01dd20 Removed the is/are function, all triggers must have a <> verb 2013-05-06 01:11:48 -04:00
Chris Sexton 1f88ffdea3 Added untappd support 2013-05-06 01:11:48 -04:00
Chris Sexton 83b28412a7 Changed random quote functionality to only spit out a quote minutes after somebody (other than the quote timer) has said something. The channels may be a bit buggy, but they don't seem to get stuck or spam, so it should be okayish. 2013-05-06 01:11:48 -04:00
Chris Sexton cebe9272e4 Added idea for downtime plugin 2013-05-06 01:11:48 -04:00
Chris Sexton 22fef34db5 Quick formatting fix for searching for factoids 2013-05-06 01:11:48 -04:00
Chris Sexton 63785e7102 Enforced admin right on editing non-personal facts 2013-05-06 01:11:48 -04:00
Chris Sexton fa83472c50 Made changeFact and forgetFact actually do stuff 2013-05-06 01:11:48 -04:00
Chris Sexton 34e6f65b1b Adde some framework for editing and deleting facts 2013-05-06 01:11:47 -04:00
Chris Sexton 24a879285e move id to idx 2013-05-06 01:11:47 -04:00