tinyzimmer / karmacheck

KarmaDecay checker for Reddit

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

karmacheck

Build Status

Unofficial KarmaDecay checker for watching subreddits

Currently watches a subreddit (or list of subreddits) for new posts, and runs new submissions against KarmaDecay. The program fetches the markdown comment from the KarmaDecay page and prints it to the terminal, and now will also reply to the post.

Pre-compiled binaries for Windows, Linux, and macOS can be found in the releases section.

Building

  • Tested on Go 1.10.2 windows/linux/macOS

Build

Using go:

$> go get github.com/tinyzimmer/karmacheck

From git:

$> git clone https://github.com/tinyzimmer/karmacheck
$> cd karmacheck
$> go build .

Usage

$> ./karmacheck
Usage of karmacheck:
-c string
      Path to Bot Configuration. (default "./bot.agent")
-d    Dry Run. Do not reply to posts.
-s string
      Comma separated list of subs to watch

I switched to the graw library. So you'll have to create a bot and get creds if you want to use it.

$> cp bot.agent.sample bot.agent # edit fields as required

Example

PS C:\Users\tinyzimmer\Desktop\Development\karmacheck> .\karmacheck.exe -s funny
2018/07/03 08:22:27 Checking KarmaDecay for: r/funny/comments/8vt1il/praise_the_ol_mighty/
2018/07/03 08:22:28 KarmaDecay could not find any similar posts
PS C:\Users\tinyzimmer\Desktop\Development\karmacheck> .\karmacheck.exe -s peoplefuckingdying
2018/07/03 08:23:13 Checking KarmaDecay for: r/PeopleFuckingDying/comments/8vsv4a/woman_is_consumed_alive_by_vicious_animals/
2018/07/03 08:23:17 Found matches. Below is the reddit comment text.
Anyone seeking more info might also check here:

title | points | age | /r/ | comnts
:--|:--|:--|:--|:--
[They have accepted me as their own](http://www.reddit.com/r/trashpandas/comments/5ko9v3/they_have_accepted_me_as_their_own/) ^**B** | 722 | 1^yr | trashpandas | 47
[I have no idea what would compel somebody to do this](http://www.reddit.com/r/WTF/comments/q5yuo/i_have_no_idea_what_would_compel_somebody_to_do/) ^**B** | 819 | 6^yrs | WTF | 220
[I honestly don't know...](http://www.reddit.com/r/WTF/comments/nn07n/i_honestly_dont_know/) ^**B** | 1133 | 6^yrs | WTF | 369
[This could end badly.](http://www.reddit.com/r/WTF/comments/t5dsg/this_could_end_badly/) | 40 | 6^yrs | WTF | 8
[Hey! Let's feed some raccoons.](http://www.reddit.com/r/WTF/comments/sfron/hey_lets_feed_some_raccoons/) | 176 | 6^yrs | WTF | 22
[Raccoon Log - Day 17 - Acceptance is finally imminent.](http://www.reddit.com/r/funny/comments/28qgh2/raccoon_log_day_17_acceptance_is_finally_imminent/) | 437 | 4^yrs | funny | 36
[She's got a thing for raccoons.](http://www.reddit.com/r/WTF/comments/1debwq/shes_got_a_thing_for_raccoons/) | 426 | 5^yrs | WTF | 55
[me irl](http://www.reddit.com/r/me_irl/comments/48meel/me_irl/) | 413 | 2^yrs | me_irl | 13
[Maybe trying meth on thanksgiving wasn't the best idea...](http://www.reddit.com/r/WTF/comments/2wxhx0/maybe_trying_meth_on_thanksgiving_wasnt_the_best/) | 733 | 3^yrs | WTF | 77

*[Source: karmadecay](http://karmadecay.com/r/PeopleFuckingDying/comments/8vsv4a/woman_is_consumed_alive_by_vicious_animals/) (B = bigger)*

Example of replying to a repost

repost example

TODO

  • The examples are off with the most current version
  • Write deployment examples, probably ansible or terraform

About

KarmaDecay checker for Reddit

License:GNU General Public License v3.0


Languages

Language:Go 100.0%