From 45f57b6cc071b09030b84dfd065d7b610eebfb38 Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 13:19:43 -0400 Subject: [PATCH 01/20] update spacing --- sopel_modules/SpiceBot_Configs/sherlock/500px | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/About.me | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/AngelList | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Behance | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/BitBucket | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/Blogger | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/BuzzFeed | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Canva | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/CashMe | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/Codecademy | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/DailyMotion | 6 ++++++ sopel_modules/SpiceBot_Configs/sherlock/DeviantART | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Disqus | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/Dribbble | 6 ++++++ sopel_modules/SpiceBot_Configs/sherlock/Etsy | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/Facebook | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/Flipboard | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Fotolog | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/Foursquare | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/GitHub | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/GoodReads | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/GooglePlus | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/Gravatar | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/Gumroad | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Imgur | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/Instagram | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Instructables | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Keybase | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/Kongregate | 6 ++++++ sopel_modules/SpiceBot_Configs/sherlock/LiveJournal | 6 ++++++ sopel_modules/SpiceBot_Configs/sherlock/Medium | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/MixCloud | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Newgrounds | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Pastebin | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Patreon | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/Pinterest | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Reddit | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Roblox | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Scribd | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/SlideShare | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/SoundCloud | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/Spotify | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/Steam | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Trakt | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/TripAdvisor | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Twitter | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/VK | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/VSCO | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/Vimeo | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Wattpad | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/YouTube | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/iMGSRC.RU | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/last.fm | 5 +++++ 53 files changed, 249 insertions(+) create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/500px create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/About.me create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/AngelList create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Behance create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/BitBucket create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Blogger create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/BuzzFeed create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Canva create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/CashMe create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Codecademy create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/DailyMotion create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/DeviantART create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Disqus create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Dribbble create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Etsy create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Facebook create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Flipboard create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Fotolog create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Foursquare create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/GitHub create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/GoodReads create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/GooglePlus create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Gravatar create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Gumroad create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Imgur create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Instagram create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Instructables create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Keybase create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Kongregate create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/LiveJournal create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Medium create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/MixCloud create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Newgrounds create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Pastebin create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Patreon create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Pinterest create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Reddit create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Roblox create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Scribd create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/SlideShare create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/SoundCloud create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Spotify create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Steam create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Trakt create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/TripAdvisor create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Twitter create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/VK create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/VSCO create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Vimeo create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Wattpad create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/YouTube create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/iMGSRC.RU create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/last.fm diff --git a/sopel_modules/SpiceBot_Configs/sherlock/500px b/sopel_modules/SpiceBot_Configs/sherlock/500px new file mode 100644 index 0000000..8a9d0bc --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/500px @@ -0,0 +1,5 @@ +{ +"url": "https://500px.com/{}", +"errorType": "message", +"errorMsg": "Sorry, no such page." +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/About.me b/sopel_modules/SpiceBot_Configs/sherlock/About.me new file mode 100644 index 0000000..2fc37a2 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/About.me @@ -0,0 +1,4 @@ +{ +"url": "https://about.me/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/AngelList b/sopel_modules/SpiceBot_Configs/sherlock/AngelList new file mode 100644 index 0000000..4e32b6e --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/AngelList @@ -0,0 +1,5 @@ +{ +"url": "https://angel.co/{}", +"errorType": "message", +"errorMsg": "We couldn't find what you were looking for." +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Behance b/sopel_modules/SpiceBot_Configs/sherlock/Behance new file mode 100644 index 0000000..3f556e0 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Behance @@ -0,0 +1,5 @@ +{ +"url": "https://www.behance.net/{}", +"errorType": "message", +"errorMsg": "Oops! We can’t find that page." +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/BitBucket b/sopel_modules/SpiceBot_Configs/sherlock/BitBucket new file mode 100644 index 0000000..425bcbd --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/BitBucket @@ -0,0 +1,4 @@ +{ +"url": "https://bitbucket.org/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Blogger b/sopel_modules/SpiceBot_Configs/sherlock/Blogger new file mode 100644 index 0000000..6c2e688 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Blogger @@ -0,0 +1,5 @@ +{ +"url": "https://{}.blogspot.com", +"errorType": "status_code", +"noPeriod": "True" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/BuzzFeed b/sopel_modules/SpiceBot_Configs/sherlock/BuzzFeed new file mode 100644 index 0000000..2e847bc --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/BuzzFeed @@ -0,0 +1,5 @@ +{ +"url": "https://buzzfeed.com/{}", +"errorType": "message", +"errorMsg": "We can't find the page you're looking for." +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Canva b/sopel_modules/SpiceBot_Configs/sherlock/Canva new file mode 100644 index 0000000..330ec53 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Canva @@ -0,0 +1,5 @@ +{ +"url": "https://www.canva.com/{}", +"errorType": "message", +"errorMsg": "Not found (404)" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/CashMe b/sopel_modules/SpiceBot_Configs/sherlock/CashMe new file mode 100644 index 0000000..af79737 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/CashMe @@ -0,0 +1,4 @@ +{ +"url": "https://cash.me/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Codecademy b/sopel_modules/SpiceBot_Configs/sherlock/Codecademy new file mode 100644 index 0000000..dc5a9a0 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Codecademy @@ -0,0 +1,5 @@ +{ +"url": "https://www.codecademy.com/{}", +"errorType": "message", +"errorMsg": "404 error" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/DailyMotion b/sopel_modules/SpiceBot_Configs/sherlock/DailyMotion new file mode 100644 index 0000000..2e1251a --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/DailyMotion @@ -0,0 +1,6 @@ + +{ +"url": "https://www.dailymotion.com/{}", +"errorType": "message", +"errorMsg": "Page not found" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/DeviantART b/sopel_modules/SpiceBot_Configs/sherlock/DeviantART new file mode 100644 index 0000000..13a39b2 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/DeviantART @@ -0,0 +1,5 @@ +{ +"url": "https://{}.deviantart.com", +"errorType": "status_code", +"noPeriod": "True" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Disqus b/sopel_modules/SpiceBot_Configs/sherlock/Disqus new file mode 100644 index 0000000..5ab29ee --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Disqus @@ -0,0 +1,4 @@ +{ +"url": "https://disqus.com/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Dribbble b/sopel_modules/SpiceBot_Configs/sherlock/Dribbble new file mode 100644 index 0000000..08b7375 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Dribbble @@ -0,0 +1,6 @@ +{ +"url": "https://dribbble.com/{}", +"errorType": "message", +"errorMsg": "Whoops, that page is gone.", +"noPeriod": "True" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Etsy b/sopel_modules/SpiceBot_Configs/sherlock/Etsy new file mode 100644 index 0000000..ab9f2b4 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Etsy @@ -0,0 +1,4 @@ +{ +"url": "https://www.etsy.com/shop/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Facebook b/sopel_modules/SpiceBot_Configs/sherlock/Facebook new file mode 100644 index 0000000..b2283aa --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Facebook @@ -0,0 +1,4 @@ +{ +"url": "https://www.facebook.com/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Flipboard b/sopel_modules/SpiceBot_Configs/sherlock/Flipboard new file mode 100644 index 0000000..5f94c33 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Flipboard @@ -0,0 +1,5 @@ +{ +"url": "https://flipboard.com/@{}", +"errorType": "message", +"errorMsg": "loading" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Fotolog b/sopel_modules/SpiceBot_Configs/sherlock/Fotolog new file mode 100644 index 0000000..ce33261 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Fotolog @@ -0,0 +1,4 @@ +{ +"url": "https://fotolog.com/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Foursquare b/sopel_modules/SpiceBot_Configs/sherlock/Foursquare new file mode 100644 index 0000000..7f5e1ac --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Foursquare @@ -0,0 +1,4 @@ +{ +"url": "https://foursquare.com/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/GitHub b/sopel_modules/SpiceBot_Configs/sherlock/GitHub new file mode 100644 index 0000000..5a887ee --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/GitHub @@ -0,0 +1,5 @@ +{ +"url": "https://www.github.com/{}", +"errorType": "status_code", +"noPeriod": "True" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/GoodReads b/sopel_modules/SpiceBot_Configs/sherlock/GoodReads new file mode 100644 index 0000000..0edf8c0 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/GoodReads @@ -0,0 +1,4 @@ +{ +"url": "https://www.goodreads.com/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/GooglePlus b/sopel_modules/SpiceBot_Configs/sherlock/GooglePlus new file mode 100644 index 0000000..8e7f674 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/GooglePlus @@ -0,0 +1,4 @@ +{ +"url": "https://plus.google.com/+{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Gravatar b/sopel_modules/SpiceBot_Configs/sherlock/Gravatar new file mode 100644 index 0000000..33343c6 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Gravatar @@ -0,0 +1,4 @@ +{ +"url": "http://en.gravatar.com/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Gumroad b/sopel_modules/SpiceBot_Configs/sherlock/Gumroad new file mode 100644 index 0000000..8c4cafd --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Gumroad @@ -0,0 +1,5 @@ +{ +"url": "https://www.gumroad.com/{}", +"errorType": "message", +"errorMsg": "Page not found." +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Imgur b/sopel_modules/SpiceBot_Configs/sherlock/Imgur new file mode 100644 index 0000000..aaf419c --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Imgur @@ -0,0 +1,4 @@ +{ +"url": "https://imgur.com/user/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Instagram b/sopel_modules/SpiceBot_Configs/sherlock/Instagram new file mode 100644 index 0000000..cf6c902 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Instagram @@ -0,0 +1,5 @@ +{ +"url": "https://www.instagram.com/{}", +"errorType": "message", +"errorMsg": "The link you followed may be broken" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Instructables b/sopel_modules/SpiceBot_Configs/sherlock/Instructables new file mode 100644 index 0000000..398f5c0 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Instructables @@ -0,0 +1,5 @@ +{ +"url": "https://www.instructables.com/member/{}", +"errorType": "message", +"errorMsg": "404: We're sorry, things break sometimes" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Keybase b/sopel_modules/SpiceBot_Configs/sherlock/Keybase new file mode 100644 index 0000000..756cbe6 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Keybase @@ -0,0 +1,4 @@ +{ +"url": "https://keybase.io/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Kongregate b/sopel_modules/SpiceBot_Configs/sherlock/Kongregate new file mode 100644 index 0000000..b663194 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Kongregate @@ -0,0 +1,6 @@ +{ +"url": "https://www.kongregate.com/accounts/{}", +"errorType": "message", +"errorMsg": "Sorry, no account with that name was found.", +"noPeriod": "True" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/LiveJournal b/sopel_modules/SpiceBot_Configs/sherlock/LiveJournal new file mode 100644 index 0000000..80645f9 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/LiveJournal @@ -0,0 +1,6 @@ +{ +"url": "https://{}.livejournal.com", +"errorType": "message", +"errorMsg": "Unknown Journal", +"noPeriod": "True" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Medium b/sopel_modules/SpiceBot_Configs/sherlock/Medium new file mode 100644 index 0000000..f82f540 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Medium @@ -0,0 +1,4 @@ +{ +"url": "https://medium.com/@{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/MixCloud b/sopel_modules/SpiceBot_Configs/sherlock/MixCloud new file mode 100644 index 0000000..e989578 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/MixCloud @@ -0,0 +1,5 @@ +{ +"url": "https://www.mixcloud.com/{}", +"errorType": "message", +"errorMsg": "Page Not Found" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Newgrounds b/sopel_modules/SpiceBot_Configs/sherlock/Newgrounds new file mode 100644 index 0000000..d220631 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Newgrounds @@ -0,0 +1,5 @@ +{ +"url": "https://{}.newgrounds.com", +"errorType": "status_code", +"noPeriod": "True" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Pastebin b/sopel_modules/SpiceBot_Configs/sherlock/Pastebin new file mode 100644 index 0000000..2d013a5 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Pastebin @@ -0,0 +1,5 @@ +{ +"url": "https://pastebin.com/u/{}", +"errorType": "response_url", +"errorUrl": "https://pastebin.com/index" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Patreon b/sopel_modules/SpiceBot_Configs/sherlock/Patreon new file mode 100644 index 0000000..1359348 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Patreon @@ -0,0 +1,4 @@ +{ +"url": "https://www.patreon.com/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Pinterest b/sopel_modules/SpiceBot_Configs/sherlock/Pinterest new file mode 100644 index 0000000..a48649c --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Pinterest @@ -0,0 +1,5 @@ +{ +"url": "https://www.pinterest.com/{}", +"errorType": "response_url", +"errorUrl": "https://www.pinterest.com/?show_error=true" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Reddit b/sopel_modules/SpiceBot_Configs/sherlock/Reddit new file mode 100644 index 0000000..473fd05 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Reddit @@ -0,0 +1,5 @@ +{ +"url": "https://www.reddit.com/user/{}", +"errorType": "message", +"errorMsg": "page not found" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Roblox b/sopel_modules/SpiceBot_Configs/sherlock/Roblox new file mode 100644 index 0000000..0b8803d --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Roblox @@ -0,0 +1,5 @@ +{ +"url": "https://www.roblox.com/user.aspx?username={}", +"errorType": "message", +"errorMsg": "Page cannot be found or no longer exists" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Scribd b/sopel_modules/SpiceBot_Configs/sherlock/Scribd new file mode 100644 index 0000000..093e9ec --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Scribd @@ -0,0 +1,5 @@ +{ +"url": "https://www.scribd.com/{}", +"errorType": "message", +"errorMsg": "Page not found" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/SlideShare b/sopel_modules/SpiceBot_Configs/sherlock/SlideShare new file mode 100644 index 0000000..dfd7890 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/SlideShare @@ -0,0 +1,4 @@ +{ +"url": "https://slideshare.net/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/SoundCloud b/sopel_modules/SpiceBot_Configs/sherlock/SoundCloud new file mode 100644 index 0000000..fe9245f --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/SoundCloud @@ -0,0 +1,4 @@ +{ +"url": "https://soundcloud.com/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Spotify b/sopel_modules/SpiceBot_Configs/sherlock/Spotify new file mode 100644 index 0000000..49113c3 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Spotify @@ -0,0 +1,4 @@ +{ +"url": "https://open.spotify.com/user/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Steam b/sopel_modules/SpiceBot_Configs/sherlock/Steam new file mode 100644 index 0000000..912ae40 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Steam @@ -0,0 +1,5 @@ +{ +"url": "https://steamcommunity.com/id/{}", +"errorType": "message", +"errorMsg": "The specified profile could not be found" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Trakt b/sopel_modules/SpiceBot_Configs/sherlock/Trakt new file mode 100644 index 0000000..9a031e5 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Trakt @@ -0,0 +1,5 @@ +{ +"url": "https://www.trakt.tv/users/{}", +"errorType": "message", +"errorMsg": "404" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/TripAdvisor b/sopel_modules/SpiceBot_Configs/sherlock/TripAdvisor new file mode 100644 index 0000000..f52727e --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/TripAdvisor @@ -0,0 +1,5 @@ +{ +"url": "https://tripadvisor.com/members/{}", +"errorType": "message", +"errorMsg": "This page is on vacation…" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Twitter b/sopel_modules/SpiceBot_Configs/sherlock/Twitter new file mode 100644 index 0000000..978e13c --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Twitter @@ -0,0 +1,5 @@ +{ +"url": "https://www.twitter.com/{}", +"errorType": "message", +"errorMsg": "page doesn’t exist" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/VK b/sopel_modules/SpiceBot_Configs/sherlock/VK new file mode 100644 index 0000000..85b53c9 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/VK @@ -0,0 +1,4 @@ +{ +"url": "https://vk.com/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/VSCO b/sopel_modules/SpiceBot_Configs/sherlock/VSCO new file mode 100644 index 0000000..2cff67e --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/VSCO @@ -0,0 +1,4 @@ +{ +"url": "https://vsco.co/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Vimeo b/sopel_modules/SpiceBot_Configs/sherlock/Vimeo new file mode 100644 index 0000000..104ee8b --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Vimeo @@ -0,0 +1,5 @@ +{ +"url": "https://vimeo.com/{}", +"errorType": "message", +"errorMsg": "404 Not Found" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Wattpad b/sopel_modules/SpiceBot_Configs/sherlock/Wattpad new file mode 100644 index 0000000..42b1f2f --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Wattpad @@ -0,0 +1,5 @@ +{ +"url": "https://www.wattpad.com/user/{}", +"errorType": "message", +"errorMsg": "This page seems to be missing..." +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/YouTube b/sopel_modules/SpiceBot_Configs/sherlock/YouTube new file mode 100644 index 0000000..9932d9d --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/YouTube @@ -0,0 +1,5 @@ +{ +"url": "https://www.youtube.com/{}", +"errorType": "message", +"errorMsg": "Not Found" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/iMGSRC.RU b/sopel_modules/SpiceBot_Configs/sherlock/iMGSRC.RU new file mode 100644 index 0000000..5f114e6 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/iMGSRC.RU @@ -0,0 +1,5 @@ +{ +"url": "https://imgsrc.ru/main/user.php?user={}", +"errorType": "response_url", +"errorUrl": "https://imgsrc.ru/" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/last.fm b/sopel_modules/SpiceBot_Configs/sherlock/last.fm new file mode 100644 index 0000000..eb3209f --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/last.fm @@ -0,0 +1,5 @@ +{ +"url": "https://last.fm/user/{}", +"errorType": "message", +"errorMsg": "Whoops! Sorry, but this page doesn't exist." +} From af8894f1a1ec39bb7481e25f66ab851eefd0383c Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 13:22:14 -0400 Subject: [PATCH 02/20] json extension --- sopel_modules/SpiceBot_Configs/sherlock/{500px => 500px.json} | 0 .../SpiceBot_Configs/sherlock/{About.me => About.me.json} | 0 .../SpiceBot_Configs/sherlock/{AngelList => AngelList.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Behance => Behance.json} | 0 .../SpiceBot_Configs/sherlock/{BitBucket => BitBucket.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Blogger => Blogger.json} | 0 .../SpiceBot_Configs/sherlock/{BuzzFeed => BuzzFeed.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Canva => Canva.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{CashMe => CashMe.json} | 0 .../SpiceBot_Configs/sherlock/{Codecademy => Codecademy.json} | 0 .../SpiceBot_Configs/sherlock/{DailyMotion => DailyMotion.json} | 0 .../SpiceBot_Configs/sherlock/{DeviantART => DeviantART.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Disqus => Disqus.json} | 0 .../SpiceBot_Configs/sherlock/{Dribbble => Dribbble.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Etsy => Etsy.json} | 0 .../SpiceBot_Configs/sherlock/{Facebook => Facebook.json} | 0 .../SpiceBot_Configs/sherlock/{Flipboard => Flipboard.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Fotolog => Fotolog.json} | 0 .../SpiceBot_Configs/sherlock/{Foursquare => Foursquare.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{GitHub => GitHub.json} | 0 .../SpiceBot_Configs/sherlock/{GoodReads => GoodReads.json} | 0 .../SpiceBot_Configs/sherlock/{GooglePlus => GooglePlus.json} | 0 .../SpiceBot_Configs/sherlock/{Gravatar => Gravatar.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Gumroad => Gumroad.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Imgur => Imgur.json} | 0 .../SpiceBot_Configs/sherlock/{Instagram => Instagram.json} | 0 .../sherlock/{Instructables => Instructables.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Keybase => Keybase.json} | 0 .../SpiceBot_Configs/sherlock/{Kongregate => Kongregate.json} | 0 .../SpiceBot_Configs/sherlock/{LiveJournal => LiveJournal.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Medium => Medium.json} | 0 .../SpiceBot_Configs/sherlock/{MixCloud => MixCloud.json} | 0 .../SpiceBot_Configs/sherlock/{Newgrounds => Newgrounds.json} | 0 .../SpiceBot_Configs/sherlock/{Pastebin => Pastebin.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Patreon => Patreon.json} | 0 .../SpiceBot_Configs/sherlock/{Pinterest => Pinterest.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Reddit => Reddit.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Roblox => Roblox.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Scribd => Scribd.json} | 0 .../SpiceBot_Configs/sherlock/{SlideShare => SlideShare.json} | 0 .../SpiceBot_Configs/sherlock/{SoundCloud => SoundCloud.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Spotify => Spotify.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Steam => Steam.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Trakt => Trakt.json} | 0 .../SpiceBot_Configs/sherlock/{TripAdvisor => TripAdvisor.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Twitter => Twitter.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{VK => VK.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{VSCO => VSCO.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Vimeo => Vimeo.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{Wattpad => Wattpad.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{YouTube => YouTube.json} | 0 .../SpiceBot_Configs/sherlock/{iMGSRC.RU => iMGSRC.RU.json} | 0 sopel_modules/SpiceBot_Configs/sherlock/{last.fm => last.fm.json} | 0 53 files changed, 0 insertions(+), 0 deletions(-) rename sopel_modules/SpiceBot_Configs/sherlock/{500px => 500px.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{About.me => About.me.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{AngelList => AngelList.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Behance => Behance.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{BitBucket => BitBucket.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Blogger => Blogger.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{BuzzFeed => BuzzFeed.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Canva => Canva.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{CashMe => CashMe.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Codecademy => Codecademy.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{DailyMotion => DailyMotion.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{DeviantART => DeviantART.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Disqus => Disqus.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Dribbble => Dribbble.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Etsy => Etsy.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Facebook => Facebook.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Flipboard => Flipboard.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Fotolog => Fotolog.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Foursquare => Foursquare.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{GitHub => GitHub.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{GoodReads => GoodReads.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{GooglePlus => GooglePlus.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Gravatar => Gravatar.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Gumroad => Gumroad.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Imgur => Imgur.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Instagram => Instagram.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Instructables => Instructables.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Keybase => Keybase.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Kongregate => Kongregate.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{LiveJournal => LiveJournal.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Medium => Medium.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{MixCloud => MixCloud.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Newgrounds => Newgrounds.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Pastebin => Pastebin.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Patreon => Patreon.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Pinterest => Pinterest.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Reddit => Reddit.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Roblox => Roblox.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Scribd => Scribd.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{SlideShare => SlideShare.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{SoundCloud => SoundCloud.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Spotify => Spotify.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Steam => Steam.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Trakt => Trakt.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{TripAdvisor => TripAdvisor.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Twitter => Twitter.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{VK => VK.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{VSCO => VSCO.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Vimeo => Vimeo.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{Wattpad => Wattpad.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{YouTube => YouTube.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{iMGSRC.RU => iMGSRC.RU.json} (100%) rename sopel_modules/SpiceBot_Configs/sherlock/{last.fm => last.fm.json} (100%) diff --git a/sopel_modules/SpiceBot_Configs/sherlock/500px b/sopel_modules/SpiceBot_Configs/sherlock/500px.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/500px rename to sopel_modules/SpiceBot_Configs/sherlock/500px.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/About.me b/sopel_modules/SpiceBot_Configs/sherlock/About.me.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/About.me rename to sopel_modules/SpiceBot_Configs/sherlock/About.me.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/AngelList b/sopel_modules/SpiceBot_Configs/sherlock/AngelList.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/AngelList rename to sopel_modules/SpiceBot_Configs/sherlock/AngelList.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Behance b/sopel_modules/SpiceBot_Configs/sherlock/Behance.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Behance rename to sopel_modules/SpiceBot_Configs/sherlock/Behance.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/BitBucket b/sopel_modules/SpiceBot_Configs/sherlock/BitBucket.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/BitBucket rename to sopel_modules/SpiceBot_Configs/sherlock/BitBucket.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Blogger b/sopel_modules/SpiceBot_Configs/sherlock/Blogger.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Blogger rename to sopel_modules/SpiceBot_Configs/sherlock/Blogger.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/BuzzFeed b/sopel_modules/SpiceBot_Configs/sherlock/BuzzFeed.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/BuzzFeed rename to sopel_modules/SpiceBot_Configs/sherlock/BuzzFeed.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Canva b/sopel_modules/SpiceBot_Configs/sherlock/Canva.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Canva rename to sopel_modules/SpiceBot_Configs/sherlock/Canva.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/CashMe b/sopel_modules/SpiceBot_Configs/sherlock/CashMe.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/CashMe rename to sopel_modules/SpiceBot_Configs/sherlock/CashMe.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Codecademy b/sopel_modules/SpiceBot_Configs/sherlock/Codecademy.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Codecademy rename to sopel_modules/SpiceBot_Configs/sherlock/Codecademy.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/DailyMotion b/sopel_modules/SpiceBot_Configs/sherlock/DailyMotion.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/DailyMotion rename to sopel_modules/SpiceBot_Configs/sherlock/DailyMotion.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/DeviantART b/sopel_modules/SpiceBot_Configs/sherlock/DeviantART.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/DeviantART rename to sopel_modules/SpiceBot_Configs/sherlock/DeviantART.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Disqus b/sopel_modules/SpiceBot_Configs/sherlock/Disqus.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Disqus rename to sopel_modules/SpiceBot_Configs/sherlock/Disqus.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Dribbble b/sopel_modules/SpiceBot_Configs/sherlock/Dribbble.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Dribbble rename to sopel_modules/SpiceBot_Configs/sherlock/Dribbble.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Etsy b/sopel_modules/SpiceBot_Configs/sherlock/Etsy.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Etsy rename to sopel_modules/SpiceBot_Configs/sherlock/Etsy.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Facebook b/sopel_modules/SpiceBot_Configs/sherlock/Facebook.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Facebook rename to sopel_modules/SpiceBot_Configs/sherlock/Facebook.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Flipboard b/sopel_modules/SpiceBot_Configs/sherlock/Flipboard.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Flipboard rename to sopel_modules/SpiceBot_Configs/sherlock/Flipboard.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Fotolog b/sopel_modules/SpiceBot_Configs/sherlock/Fotolog.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Fotolog rename to sopel_modules/SpiceBot_Configs/sherlock/Fotolog.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Foursquare b/sopel_modules/SpiceBot_Configs/sherlock/Foursquare.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Foursquare rename to sopel_modules/SpiceBot_Configs/sherlock/Foursquare.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/GitHub b/sopel_modules/SpiceBot_Configs/sherlock/GitHub.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/GitHub rename to sopel_modules/SpiceBot_Configs/sherlock/GitHub.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/GoodReads b/sopel_modules/SpiceBot_Configs/sherlock/GoodReads.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/GoodReads rename to sopel_modules/SpiceBot_Configs/sherlock/GoodReads.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/GooglePlus b/sopel_modules/SpiceBot_Configs/sherlock/GooglePlus.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/GooglePlus rename to sopel_modules/SpiceBot_Configs/sherlock/GooglePlus.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Gravatar b/sopel_modules/SpiceBot_Configs/sherlock/Gravatar.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Gravatar rename to sopel_modules/SpiceBot_Configs/sherlock/Gravatar.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Gumroad b/sopel_modules/SpiceBot_Configs/sherlock/Gumroad.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Gumroad rename to sopel_modules/SpiceBot_Configs/sherlock/Gumroad.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Imgur b/sopel_modules/SpiceBot_Configs/sherlock/Imgur.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Imgur rename to sopel_modules/SpiceBot_Configs/sherlock/Imgur.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Instagram b/sopel_modules/SpiceBot_Configs/sherlock/Instagram.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Instagram rename to sopel_modules/SpiceBot_Configs/sherlock/Instagram.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Instructables b/sopel_modules/SpiceBot_Configs/sherlock/Instructables.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Instructables rename to sopel_modules/SpiceBot_Configs/sherlock/Instructables.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Keybase b/sopel_modules/SpiceBot_Configs/sherlock/Keybase.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Keybase rename to sopel_modules/SpiceBot_Configs/sherlock/Keybase.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Kongregate b/sopel_modules/SpiceBot_Configs/sherlock/Kongregate.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Kongregate rename to sopel_modules/SpiceBot_Configs/sherlock/Kongregate.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/LiveJournal b/sopel_modules/SpiceBot_Configs/sherlock/LiveJournal.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/LiveJournal rename to sopel_modules/SpiceBot_Configs/sherlock/LiveJournal.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Medium b/sopel_modules/SpiceBot_Configs/sherlock/Medium.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Medium rename to sopel_modules/SpiceBot_Configs/sherlock/Medium.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/MixCloud b/sopel_modules/SpiceBot_Configs/sherlock/MixCloud.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/MixCloud rename to sopel_modules/SpiceBot_Configs/sherlock/MixCloud.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Newgrounds b/sopel_modules/SpiceBot_Configs/sherlock/Newgrounds.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Newgrounds rename to sopel_modules/SpiceBot_Configs/sherlock/Newgrounds.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Pastebin b/sopel_modules/SpiceBot_Configs/sherlock/Pastebin.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Pastebin rename to sopel_modules/SpiceBot_Configs/sherlock/Pastebin.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Patreon b/sopel_modules/SpiceBot_Configs/sherlock/Patreon.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Patreon rename to sopel_modules/SpiceBot_Configs/sherlock/Patreon.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Pinterest b/sopel_modules/SpiceBot_Configs/sherlock/Pinterest.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Pinterest rename to sopel_modules/SpiceBot_Configs/sherlock/Pinterest.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Reddit b/sopel_modules/SpiceBot_Configs/sherlock/Reddit.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Reddit rename to sopel_modules/SpiceBot_Configs/sherlock/Reddit.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Roblox b/sopel_modules/SpiceBot_Configs/sherlock/Roblox.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Roblox rename to sopel_modules/SpiceBot_Configs/sherlock/Roblox.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Scribd b/sopel_modules/SpiceBot_Configs/sherlock/Scribd.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Scribd rename to sopel_modules/SpiceBot_Configs/sherlock/Scribd.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/SlideShare b/sopel_modules/SpiceBot_Configs/sherlock/SlideShare.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/SlideShare rename to sopel_modules/SpiceBot_Configs/sherlock/SlideShare.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/SoundCloud b/sopel_modules/SpiceBot_Configs/sherlock/SoundCloud.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/SoundCloud rename to sopel_modules/SpiceBot_Configs/sherlock/SoundCloud.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Spotify b/sopel_modules/SpiceBot_Configs/sherlock/Spotify.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Spotify rename to sopel_modules/SpiceBot_Configs/sherlock/Spotify.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Steam b/sopel_modules/SpiceBot_Configs/sherlock/Steam.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Steam rename to sopel_modules/SpiceBot_Configs/sherlock/Steam.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Trakt b/sopel_modules/SpiceBot_Configs/sherlock/Trakt.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Trakt rename to sopel_modules/SpiceBot_Configs/sherlock/Trakt.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/TripAdvisor b/sopel_modules/SpiceBot_Configs/sherlock/TripAdvisor.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/TripAdvisor rename to sopel_modules/SpiceBot_Configs/sherlock/TripAdvisor.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Twitter b/sopel_modules/SpiceBot_Configs/sherlock/Twitter.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Twitter rename to sopel_modules/SpiceBot_Configs/sherlock/Twitter.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/VK b/sopel_modules/SpiceBot_Configs/sherlock/VK.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/VK rename to sopel_modules/SpiceBot_Configs/sherlock/VK.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/VSCO b/sopel_modules/SpiceBot_Configs/sherlock/VSCO.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/VSCO rename to sopel_modules/SpiceBot_Configs/sherlock/VSCO.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Vimeo b/sopel_modules/SpiceBot_Configs/sherlock/Vimeo.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Vimeo rename to sopel_modules/SpiceBot_Configs/sherlock/Vimeo.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Wattpad b/sopel_modules/SpiceBot_Configs/sherlock/Wattpad.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/Wattpad rename to sopel_modules/SpiceBot_Configs/sherlock/Wattpad.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/YouTube b/sopel_modules/SpiceBot_Configs/sherlock/YouTube.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/YouTube rename to sopel_modules/SpiceBot_Configs/sherlock/YouTube.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/iMGSRC.RU b/sopel_modules/SpiceBot_Configs/sherlock/iMGSRC.RU.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/iMGSRC.RU rename to sopel_modules/SpiceBot_Configs/sherlock/iMGSRC.RU.json diff --git a/sopel_modules/SpiceBot_Configs/sherlock/last.fm b/sopel_modules/SpiceBot_Configs/sherlock/last.fm.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/sherlock/last.fm rename to sopel_modules/SpiceBot_Configs/sherlock/last.fm.json From 054a70d22fd6829923d7c4dde9c8df87bf07012f Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 13:25:02 -0400 Subject: [PATCH 03/20] jsonify --- sopel_modules/SpiceBot_Configs/gifapi/{gfycat => gfycat.json} | 0 sopel_modules/SpiceBot_Configs/gifapi/{gifme => gifme.json} | 0 sopel_modules/SpiceBot_Configs/gifapi/{giphy => giphy.json} | 0 sopel_modules/SpiceBot_Configs/gifapi/{tenor => tenor.json} | 0 4 files changed, 0 insertions(+), 0 deletions(-) rename sopel_modules/SpiceBot_Configs/gifapi/{gfycat => gfycat.json} (100%) rename sopel_modules/SpiceBot_Configs/gifapi/{gifme => gifme.json} (100%) rename sopel_modules/SpiceBot_Configs/gifapi/{giphy => giphy.json} (100%) rename sopel_modules/SpiceBot_Configs/gifapi/{tenor => tenor.json} (100%) diff --git a/sopel_modules/SpiceBot_Configs/gifapi/gfycat b/sopel_modules/SpiceBot_Configs/gifapi/gfycat.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/gifapi/gfycat rename to sopel_modules/SpiceBot_Configs/gifapi/gfycat.json diff --git a/sopel_modules/SpiceBot_Configs/gifapi/gifme b/sopel_modules/SpiceBot_Configs/gifapi/gifme.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/gifapi/gifme rename to sopel_modules/SpiceBot_Configs/gifapi/gifme.json diff --git a/sopel_modules/SpiceBot_Configs/gifapi/giphy b/sopel_modules/SpiceBot_Configs/gifapi/giphy.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/gifapi/giphy rename to sopel_modules/SpiceBot_Configs/gifapi/giphy.json diff --git a/sopel_modules/SpiceBot_Configs/gifapi/tenor b/sopel_modules/SpiceBot_Configs/gifapi/tenor.json similarity index 100% rename from sopel_modules/SpiceBot_Configs/gifapi/tenor rename to sopel_modules/SpiceBot_Configs/gifapi/tenor.json From 6c8f814451d32d649142482c09770355158f08f5 Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 13:35:21 -0400 Subject: [PATCH 04/20] sherlock configs are ready --- sopel_modules/SpiceBot/Tools.py | 2 +- sopel_modules/SpiceBot_Configs/sherlock/BLIP.fm.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Bandcamp.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Codementor.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/ColourLovers.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Contently.json | 6 ++++++ .../SpiceBot_Configs/sherlock/Designspiration.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Ebay.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Ello.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Flickr.json | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/HackerNews.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/HackerOne.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Houzz.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/IFTTT.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Pexels.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/ReverbNation.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Slack.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Tinder.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Trip.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/Unsplash.json | 4 ++++ sopel_modules/SpiceBot_Configs/sherlock/WeHeartIt.json | 5 +++++ sopel_modules/SpiceBot_Configs/sherlock/WordPress.json | 6 ++++++ sopel_modules/SpiceBot_Configs/sherlock/devRant.json | 5 +++++ 23 files changed, 111 insertions(+), 1 deletion(-) create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/BLIP.fm.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Bandcamp.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Codementor.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/ColourLovers.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Contently.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Designspiration.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Ebay.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Ello.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Flickr.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/HackerNews.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/HackerOne.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Houzz.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/IFTTT.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Pexels.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/ReverbNation.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Slack.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Tinder.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Trip.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/Unsplash.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/WeHeartIt.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/WordPress.json create mode 100644 sopel_modules/SpiceBot_Configs/sherlock/devRant.json diff --git a/sopel_modules/SpiceBot/Tools.py b/sopel_modules/SpiceBot/Tools.py index 637d16f..f83f579 100644 --- a/sopel_modules/SpiceBot/Tools.py +++ b/sopel_modules/SpiceBot/Tools.py @@ -333,7 +333,7 @@ def read_directory_json_to_dict(directories, configtypename="Config File", log_f if len(os.listdir(directory)) > 0: for file in os.listdir(directory): filepath = os.path.join(directory, file) - if os.path.isfile(filepath): + if os.path.isfile(filepath) and filepath.endswith('.json'): filesprocess.append(filepath) for filepath in filesprocess: diff --git a/sopel_modules/SpiceBot_Configs/sherlock/BLIP.fm.json b/sopel_modules/SpiceBot_Configs/sherlock/BLIP.fm.json new file mode 100644 index 0000000..22bb880 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/BLIP.fm.json @@ -0,0 +1,5 @@ +{ +"url": "https://blip.fm/{}", +"errorType": "message", +"errorMsg": "Page Not Found" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Bandcamp.json b/sopel_modules/SpiceBot_Configs/sherlock/Bandcamp.json new file mode 100644 index 0000000..51b61b0 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Bandcamp.json @@ -0,0 +1,5 @@ +{ +"url": "https://www.bandcamp.com/{}", +"errorType": "message", +"errorMsg": "Sorry, that something isn’t here" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Codementor.json b/sopel_modules/SpiceBot_Configs/sherlock/Codementor.json new file mode 100644 index 0000000..af0651d --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Codementor.json @@ -0,0 +1,5 @@ +{ +"url": "https://www.codementor.io/{}", +"errorType": "message", +"errorMsg": "404" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/ColourLovers.json b/sopel_modules/SpiceBot_Configs/sherlock/ColourLovers.json new file mode 100644 index 0000000..460868d --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/ColourLovers.json @@ -0,0 +1,5 @@ +{ +"url": "https://www.colourlovers.com/love/{}", +"errorType": "message", +"errorMsg": "Page Not Loved" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Contently.json b/sopel_modules/SpiceBot_Configs/sherlock/Contently.json new file mode 100644 index 0000000..d1858d7 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Contently.json @@ -0,0 +1,6 @@ +{ +"url": "https://{}.contently.com/", +"errorType": "message", +"errorMsg": "We can't find that page!", +"noPeriod": "True" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Designspiration.json b/sopel_modules/SpiceBot_Configs/sherlock/Designspiration.json new file mode 100644 index 0000000..938072b --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Designspiration.json @@ -0,0 +1,5 @@ +{ +"url": "https://www.designspiration.net/{}", +"errorType": "message", +"errorMsg": "Content Not Found" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Ebay.json b/sopel_modules/SpiceBot_Configs/sherlock/Ebay.json new file mode 100644 index 0000000..43b284f --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Ebay.json @@ -0,0 +1,5 @@ +{ +"url": "https://www.ebay.com/usr/{}", +"errorType": "message", +"errorMsg": "The User ID you entered was not found" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Ello.json b/sopel_modules/SpiceBot_Configs/sherlock/Ello.json new file mode 100644 index 0000000..9445173 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Ello.json @@ -0,0 +1,5 @@ +{ +"url": "https://ello.co/{}", +"errorType": "message", +"errorMsg": "We couldn't find the page you're looking for" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Flickr.json b/sopel_modules/SpiceBot_Configs/sherlock/Flickr.json new file mode 100644 index 0000000..50ba923 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Flickr.json @@ -0,0 +1,4 @@ +{ +"url": "https://www.flickr.com/people/{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/HackerNews.json b/sopel_modules/SpiceBot_Configs/sherlock/HackerNews.json new file mode 100644 index 0000000..5b34d7b --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/HackerNews.json @@ -0,0 +1,5 @@ +{ +"url": "https://news.ycombinator.com/user?id={}", +"errorType": "message", +"errorMsg": "No such user." +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/HackerOne.json b/sopel_modules/SpiceBot_Configs/sherlock/HackerOne.json new file mode 100644 index 0000000..8cedfc4 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/HackerOne.json @@ -0,0 +1,5 @@ +{ +"url": "https://hackerone.com/{}", +"errorType": "message", +"errorMsg": "Page not found" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Houzz.json b/sopel_modules/SpiceBot_Configs/sherlock/Houzz.json new file mode 100644 index 0000000..dd5c35c --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Houzz.json @@ -0,0 +1,5 @@ +{ +"url": "https://houzz.com/user/{}", +"errorType": "message", +"errorMsg": "The page you requested was not found." +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/IFTTT.json b/sopel_modules/SpiceBot_Configs/sherlock/IFTTT.json new file mode 100644 index 0000000..6389e03 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/IFTTT.json @@ -0,0 +1,5 @@ +{ +"url": "https://www.ifttt.com/p/{}", +"errorType": "message", +"errorMsg": "The requested page or file does not exist" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Pexels.json b/sopel_modules/SpiceBot_Configs/sherlock/Pexels.json new file mode 100644 index 0000000..d935f22 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Pexels.json @@ -0,0 +1,5 @@ +{ +"url": "https://www.pexels.com/@{}", +"errorType": "message", +"errorMsg": "Ouch, something went wrong!" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/ReverbNation.json b/sopel_modules/SpiceBot_Configs/sherlock/ReverbNation.json new file mode 100644 index 0000000..fe9f1f3 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/ReverbNation.json @@ -0,0 +1,5 @@ +{ +"url": "https://www.reverbnation.com/{}", +"errorType": "message", +"errorMsg": "Sorry, we couldn't find that page" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Slack.json b/sopel_modules/SpiceBot_Configs/sherlock/Slack.json new file mode 100644 index 0000000..665a35c --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Slack.json @@ -0,0 +1,5 @@ +{ +"url": "https://{}.slack.com", +"errorType": "status_code", +"noPeriod": "True" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Tinder.json b/sopel_modules/SpiceBot_Configs/sherlock/Tinder.json new file mode 100644 index 0000000..d243de3 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Tinder.json @@ -0,0 +1,5 @@ +{ +"url": "https://www.gotinder.com/@{}", +"errorType": "message", +"errorMsg": "Looking for Someone?" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Trip.json b/sopel_modules/SpiceBot_Configs/sherlock/Trip.json new file mode 100644 index 0000000..d7b2016 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Trip.json @@ -0,0 +1,5 @@ +{ +"url": "https://www.trip.skyscanner.com/user/{}", +"errorType": "message", +"errorMsg": "Page not found" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/Unsplash.json b/sopel_modules/SpiceBot_Configs/sherlock/Unsplash.json new file mode 100644 index 0000000..674dc26 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/Unsplash.json @@ -0,0 +1,4 @@ +{ +"url": "https://unsplash.com/@{}", +"errorType": "status_code" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/WeHeartIt.json b/sopel_modules/SpiceBot_Configs/sherlock/WeHeartIt.json new file mode 100644 index 0000000..4c36735 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/WeHeartIt.json @@ -0,0 +1,5 @@ +{ +"url": "https://weheartit.com/{}", +"errorType": "message", +"errorMsg": "Oops! You've landed on a moving target!" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/WordPress.json b/sopel_modules/SpiceBot_Configs/sherlock/WordPress.json new file mode 100644 index 0000000..f50bcb4 --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/WordPress.json @@ -0,0 +1,6 @@ +{ +"url": "https://{}.wordpress.com", +"errorType": "response_url", +"errorUrl": "wordpress.com/typo/?subdomain=", +"noPeriod": "True" +} diff --git a/sopel_modules/SpiceBot_Configs/sherlock/devRant.json b/sopel_modules/SpiceBot_Configs/sherlock/devRant.json new file mode 100644 index 0000000..3463f4c --- /dev/null +++ b/sopel_modules/SpiceBot_Configs/sherlock/devRant.json @@ -0,0 +1,5 @@ +{ +"url": "https://devrant.com/users/{}", +"errorType": "response_url", +"errorUrl": "https://devrant.com/" +} From 7bae4b86208f6e824f37805ee42d315ed1f2929d Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 14:43:31 -0400 Subject: [PATCH 05/20] sherlock --- sopel_modules/SpiceBot/Sherlock.py | 43 +++++++++++ sopel_modules/SpiceBot/__init__.py | 1 + .../SpiceBot_Core_Commands/Sherlock.py | 75 +++++++++++++++++++ .../SpiceBot_Core_Commands/__init__.py | 1 + 4 files changed, 120 insertions(+) create mode 100644 sopel_modules/SpiceBot/Sherlock.py create mode 100644 sopel_modules/SpiceBot_Core_Commands/Sherlock.py diff --git a/sopel_modules/SpiceBot/Sherlock.py b/sopel_modules/SpiceBot/Sherlock.py new file mode 100644 index 0000000..b2ec13f --- /dev/null +++ b/sopel_modules/SpiceBot/Sherlock.py @@ -0,0 +1,43 @@ +# coding=utf8 +from __future__ import unicode_literals, absolute_import, division, print_function +"""A way to search google""" + +import sopel_modules + +from .Tools import read_directory_json_to_dict + +import os +from fake_useragent import UserAgent +import requests + + +class Sherlock(): + + def __init__(self): + self.header = {'User-Agent': str(UserAgent().chrome)} + self.dict - dict() + + dir_to_scan = [] + for plugin_dir in set(sopel_modules.__path__): + configsdir = os.path.join(plugin_dir, "SpiceBot_Configs") + usercfgdir = os.path.join(configsdir, "sherlock") + dir_to_scan.append(usercfgdir) + + valid_usernames_dict = read_directory_json_to_dict(dir_to_scan, "Gif API", "SpiceBot_Gif") + + for sherlockdict in list(valid_usernames_dict.keys()): + self.dict[sherlockdict] = valid_usernames_dict[sherlockdict] + self.dict[sherlockdict]["cache"] = dict() + + def make_request(self, url, error_type, social_network): + try: + r = requests.get(url, headers=self.header) + if r.status_code: + return r, error_type + except Exception as e: + returnval = e + returnval = None + return returnval, "" + + +sherlock = Sherlock() diff --git a/sopel_modules/SpiceBot/__init__.py b/sopel_modules/SpiceBot/__init__.py index e5e8ccd..90787d3 100644 --- a/sopel_modules/SpiceBot/__init__.py +++ b/sopel_modules/SpiceBot/__init__.py @@ -24,6 +24,7 @@ from .Users import * from .AI import * from .Google import * from .Gif import * +from .Sherlock import * from .configure import * diff --git a/sopel_modules/SpiceBot_Core_Commands/Sherlock.py b/sopel_modules/SpiceBot_Core_Commands/Sherlock.py new file mode 100644 index 0000000..904f829 --- /dev/null +++ b/sopel_modules/SpiceBot_Core_Commands/Sherlock.py @@ -0,0 +1,75 @@ +# coding=utf8 +from __future__ import unicode_literals, absolute_import, division, print_function + +# sopel imports +import sopel.module + +import spicemanip + +import sopel_modules.SpiceBot as SpiceBot + + +@SpiceBot.prerun.prerun('module') +@sopel.module.commands('sherlock', 'username') +def bot_command_sherlock(bot, trigger): + + data = SpiceBot.sherlock.dict + netlist = list(SpiceBot.sherlock.dict.keys()) + + username = spicemanip.main(trigger.sb["args"], 1) or trigger.nick + trigger.sb["args"] = spicemanip.main(trigger.sb["args"], "2+", 'list') + + checklist = netlist + checklistname = 'all' + if SpiceBot.bot_check_inlist(bot, username, netlist): + checklistname = SpiceBot.inlist_match(bot, username, netlist) + checklist = [checklistname] + username = spicemanip.main(trigger.sb["args"], 1) or trigger.nick + + bot.osd("Checking username " + username + " in " + checklistname + " network.") + + inlist = [] + notinlist = [] + + for social_network in checklist: + + url = data.get(social_network).get("url").format(username) + error_type = data.get(social_network).get("errorType") + cant_have_period = data.get(social_network).get("noPeriod") + + if ("." in username) and (cant_have_period == "True"): + while ("." in username): + username = username.replace(".", '') + + r, error_type = SpiceBot.sherlock.make_request(url=url, error_type=error_type, social_network=social_network) + + if error_type == "message": + error = data.get(social_network).get("errorMsg") + # Checks if the error message is in the HTML + if error not in r.text: + inlist.append(social_network) + else: + notinlist.append(social_network) + + elif error_type == "status_code": + # Checks if the status code of the repsonse is 404 + if not r.status_code == 404: + inlist.append(social_network) + else: + notinlist.append(social_network) + + elif error_type == "response_url": + error = data.get(social_network).get("errorUrl") + # Checks if the redirect url is the same as the one defined in data.json + if error not in r.url: + inlist.append(social_network) + else: + notinlist.append(social_network) + + if inlist != []: + if checklistname != 'all': + bot.osd(["The username " + username + " is in " + checklist[0]]) + else: + bot.osd(["The username " + username + " is in the following:", spicemanip.main(inlist, "andlist")]) + if notinlist != []: + bot.osd(["The username " + username + " is NOT in the following:", spicemanip.main(notinlist, "andlist")]) diff --git a/sopel_modules/SpiceBot_Core_Commands/__init__.py b/sopel_modules/SpiceBot_Core_Commands/__init__.py index a451704..cf853c4 100644 --- a/sopel_modules/SpiceBot_Core_Commands/__init__.py +++ b/sopel_modules/SpiceBot_Core_Commands/__init__.py @@ -19,6 +19,7 @@ from .BotPrivs import * from .Search import * from .AI import * from .Gif import * +from .Sherlock import * __author__ = 'Sam Zick' __email__ = 'sam@deathbybandaid.net' From a441e2e928bdb5c715b991c7b92c6e5149a613b7 Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 14:48:31 -0400 Subject: [PATCH 06/20] fix --- sopel_modules/SpiceBot/Gif.py | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/sopel_modules/SpiceBot/Gif.py b/sopel_modules/SpiceBot/Gif.py index f39ac9c..24b47ab 100644 --- a/sopel_modules/SpiceBot/Gif.py +++ b/sopel_modules/SpiceBot/Gif.py @@ -49,15 +49,16 @@ class BotGif(): valid_gif_api_dict = read_directory_json_to_dict(dir_to_scan, "Gif API", "SpiceBot_Gif") for gif_api in list(valid_gif_api_dict.keys()): - botconfig.define_section(gif_api, GifAPISection, validate=False) + gif_api_base = os.path.basename(gif_api).rsplit('.', 1)[0] + botconfig.define_section(gif_api_base, GifAPISection, validate=False) - self.valid_api[gif_api] = valid_gif_api_dict[gif_api] - self.valid_api[gif_api]["apikey"] = None - self.valid_api[gif_api]["cache"] = dict() + self.valid_api[gif_api_base] = valid_gif_api_dict[gif_api] + self.valid_api[gif_api_base]["apikey"] = None + self.valid_api[gif_api_base]["cache"] = dict() - apikey = eval("botconfig." + gif_api + ".apikey") + apikey = eval("botconfig." + gif_api_base + ".apikey") if apikey: - self.valid_api[gif_api]["apikey"] = apikey + self.valid_api[gif_api_base]["apikey"] = apikey for validgifapi in list(self.valid_api.keys()): command_dict = { From cc29d6d4c47cc016ad921450d601d44364243c83 Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 14:50:24 -0400 Subject: [PATCH 07/20] basename --- sopel_modules/SpiceBot/Tools.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sopel_modules/SpiceBot/Tools.py b/sopel_modules/SpiceBot/Tools.py index f83f579..ef61bee 100644 --- a/sopel_modules/SpiceBot/Tools.py +++ b/sopel_modules/SpiceBot/Tools.py @@ -356,7 +356,8 @@ def read_directory_json_to_dict(directories, configtypename="Config File", log_f filecount += 1 slashsplit = str(filepath).split("/") filename = slashsplit[-1] - configs_dict[filename] = dict_from_file + filename_base = os.path.basename(filename).rsplit('.', 1)[0] + configs_dict[filename_base] = dict_from_file else: fileopenfail += 1 From 8a40fa8c5ea0ddf314f2c0d6976e7194f057058c Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 15:00:41 -0400 Subject: [PATCH 08/20] fix --- sopel_modules/SpiceBot/Sherlock.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sopel_modules/SpiceBot/Sherlock.py b/sopel_modules/SpiceBot/Sherlock.py index b2ec13f..05df6b4 100644 --- a/sopel_modules/SpiceBot/Sherlock.py +++ b/sopel_modules/SpiceBot/Sherlock.py @@ -15,7 +15,7 @@ class Sherlock(): def __init__(self): self.header = {'User-Agent': str(UserAgent().chrome)} - self.dict - dict() + self.dict = {} dir_to_scan = [] for plugin_dir in set(sopel_modules.__path__): From 6b75686cf9d4d6094a04245fc5c4c394afe2fa06 Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 15:01:38 -0400 Subject: [PATCH 09/20] remove uneeded --- sopel_modules/SpiceBot/Gif.py | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/sopel_modules/SpiceBot/Gif.py b/sopel_modules/SpiceBot/Gif.py index 24b47ab..f39ac9c 100644 --- a/sopel_modules/SpiceBot/Gif.py +++ b/sopel_modules/SpiceBot/Gif.py @@ -49,16 +49,15 @@ class BotGif(): valid_gif_api_dict = read_directory_json_to_dict(dir_to_scan, "Gif API", "SpiceBot_Gif") for gif_api in list(valid_gif_api_dict.keys()): - gif_api_base = os.path.basename(gif_api).rsplit('.', 1)[0] - botconfig.define_section(gif_api_base, GifAPISection, validate=False) + botconfig.define_section(gif_api, GifAPISection, validate=False) - self.valid_api[gif_api_base] = valid_gif_api_dict[gif_api] - self.valid_api[gif_api_base]["apikey"] = None - self.valid_api[gif_api_base]["cache"] = dict() + self.valid_api[gif_api] = valid_gif_api_dict[gif_api] + self.valid_api[gif_api]["apikey"] = None + self.valid_api[gif_api]["cache"] = dict() - apikey = eval("botconfig." + gif_api_base + ".apikey") + apikey = eval("botconfig." + gif_api + ".apikey") if apikey: - self.valid_api[gif_api_base]["apikey"] = apikey + self.valid_api[gif_api]["apikey"] = apikey for validgifapi in list(self.valid_api.keys()): command_dict = { From 418f88a61dc629254f44423275e2637825d4e858 Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 15:02:54 -0400 Subject: [PATCH 10/20] fix --- sopel_modules/SpiceBot_Core_Commands/Sherlock.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sopel_modules/SpiceBot_Core_Commands/Sherlock.py b/sopel_modules/SpiceBot_Core_Commands/Sherlock.py index 904f829..6c58d55 100644 --- a/sopel_modules/SpiceBot_Core_Commands/Sherlock.py +++ b/sopel_modules/SpiceBot_Core_Commands/Sherlock.py @@ -21,8 +21,8 @@ def bot_command_sherlock(bot, trigger): checklist = netlist checklistname = 'all' - if SpiceBot.bot_check_inlist(bot, username, netlist): - checklistname = SpiceBot.inlist_match(bot, username, netlist) + if SpiceBot.inlist(username, netlist): + checklistname = SpiceBot.inlist_match(username, netlist) checklist = [checklistname] username = spicemanip.main(trigger.sb["args"], 1) or trigger.nick From b90f6c7b6ddf7ede7586c1996ee8cbbfc96bfced Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 15:16:10 -0400 Subject: [PATCH 11/20] update retrievalmethod --- sopel_modules/SpiceBot/Sherlock.py | 34 +++++++++++++++ .../SpiceBot_Core_Commands/Sherlock.py | 41 +++---------------- 2 files changed, 40 insertions(+), 35 deletions(-) diff --git a/sopel_modules/SpiceBot/Sherlock.py b/sopel_modules/SpiceBot/Sherlock.py index 05df6b4..9ff385a 100644 --- a/sopel_modules/SpiceBot/Sherlock.py +++ b/sopel_modules/SpiceBot/Sherlock.py @@ -29,6 +29,40 @@ class Sherlock(): self.dict[sherlockdict] = valid_usernames_dict[sherlockdict] self.dict[sherlockdict]["cache"] = dict() + def check_network(self, username, social_network): + url = self.dict.get(social_network).get("url").format(username) + error_type = self.dict.get(social_network).get("errorType") + cant_have_period = self.dict.get(social_network).get("noPeriod") + + if ("." in username) and (cant_have_period == "True"): + while ("." in username): + username = username.replace(".", '') + + r, error_type = self.make_request(url=url, error_type=error_type, social_network=social_network) + + if error_type == "message": + error = self.dict.get(social_network).get("errorMsg") + # Checks if the error message is in the HTML + if error not in r.text: + return True + else: + return False + + elif error_type == "status_code": + # Checks if the status code of the repsonse is 404 + if not r.status_code == 404: + return True + else: + return False + + elif error_type == "response_url": + error = self.dict.get(social_network).get("errorUrl") + # Checks if the redirect url is the same as the one defined in data.json + if error not in r.url: + return True + else: + return False + def make_request(self, url, error_type, social_network): try: r = requests.get(url, headers=self.header) diff --git a/sopel_modules/SpiceBot_Core_Commands/Sherlock.py b/sopel_modules/SpiceBot_Core_Commands/Sherlock.py index 6c58d55..452c6c4 100644 --- a/sopel_modules/SpiceBot_Core_Commands/Sherlock.py +++ b/sopel_modules/SpiceBot_Core_Commands/Sherlock.py @@ -13,7 +13,6 @@ import sopel_modules.SpiceBot as SpiceBot @sopel.module.commands('sherlock', 'username') def bot_command_sherlock(bot, trigger): - data = SpiceBot.sherlock.dict netlist = list(SpiceBot.sherlock.dict.keys()) username = spicemanip.main(trigger.sb["args"], 1) or trigger.nick @@ -28,43 +27,15 @@ def bot_command_sherlock(bot, trigger): bot.osd("Checking username " + username + " in " + checklistname + " network.") - inlist = [] - notinlist = [] + inlist, notinlist = [], [] for social_network in checklist: - url = data.get(social_network).get("url").format(username) - error_type = data.get(social_network).get("errorType") - cant_have_period = data.get(social_network).get("noPeriod") - - if ("." in username) and (cant_have_period == "True"): - while ("." in username): - username = username.replace(".", '') - - r, error_type = SpiceBot.sherlock.make_request(url=url, error_type=error_type, social_network=social_network) - - if error_type == "message": - error = data.get(social_network).get("errorMsg") - # Checks if the error message is in the HTML - if error not in r.text: - inlist.append(social_network) - else: - notinlist.append(social_network) - - elif error_type == "status_code": - # Checks if the status code of the repsonse is 404 - if not r.status_code == 404: - inlist.append(social_network) - else: - notinlist.append(social_network) - - elif error_type == "response_url": - error = data.get(social_network).get("errorUrl") - # Checks if the redirect url is the same as the one defined in data.json - if error not in r.url: - inlist.append(social_network) - else: - notinlist.append(social_network) + in_social = SpiceBot.sherlock.check_network(username, social_network) + if in_social: + inlist.append(social_network) + else: + notinlist.append(social_network) if inlist != []: if checklistname != 'all': From cd664607b190e7616adadebce7f463493c21dba4 Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 15:21:34 -0400 Subject: [PATCH 12/20] cache system --- sopel_modules/SpiceBot/Sherlock.py | 30 ++++++++++++++++++------------ 1 file changed, 18 insertions(+), 12 deletions(-) diff --git a/sopel_modules/SpiceBot/Sherlock.py b/sopel_modules/SpiceBot/Sherlock.py index 9ff385a..fbf54bf 100644 --- a/sopel_modules/SpiceBot/Sherlock.py +++ b/sopel_modules/SpiceBot/Sherlock.py @@ -30,6 +30,10 @@ class Sherlock(): self.dict[sherlockdict]["cache"] = dict() def check_network(self, username, social_network): + + if username in self.dict[social_network]["cache"]: + return True + url = self.dict.get(social_network).get("url").format(username) error_type = self.dict.get(social_network).get("errorType") cant_have_period = self.dict.get(social_network).get("noPeriod") @@ -40,28 +44,30 @@ class Sherlock(): r, error_type = self.make_request(url=url, error_type=error_type, social_network=social_network) + user_exists = True + if error_type == "message": error = self.dict.get(social_network).get("errorMsg") # Checks if the error message is in the HTML - if error not in r.text: - return True - else: - return False + if error in r.text: + user_exists = False elif error_type == "status_code": # Checks if the status code of the repsonse is 404 - if not r.status_code == 404: - return True - else: - return False + if r.status_code == 404: + user_exists = False elif error_type == "response_url": error = self.dict.get(social_network).get("errorUrl") # Checks if the redirect url is the same as the one defined in data.json - if error not in r.url: - return True - else: - return False + if error in r.url: + user_exists = False + + if user_exists: + self.dict[social_network]["cache"].append(username) + return True + else: + return False def make_request(self, url, error_type, social_network): try: From 8f2b1896dcbe13f282fbd64af49de8ac258dfeec Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 15:23:30 -0400 Subject: [PATCH 13/20] test --- sopel_modules/SpiceBot/Sherlock.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sopel_modules/SpiceBot/Sherlock.py b/sopel_modules/SpiceBot/Sherlock.py index fbf54bf..d8ec4ec 100644 --- a/sopel_modules/SpiceBot/Sherlock.py +++ b/sopel_modules/SpiceBot/Sherlock.py @@ -25,9 +25,9 @@ class Sherlock(): valid_usernames_dict = read_directory_json_to_dict(dir_to_scan, "Gif API", "SpiceBot_Gif") - for sherlockdict in list(valid_usernames_dict.keys()): - self.dict[sherlockdict] = valid_usernames_dict[sherlockdict] - self.dict[sherlockdict]["cache"] = dict() + for social_network in list(valid_usernames_dict.keys()): + self.dict[social_network] = valid_usernames_dict[social_network] + self.dict[social_network]["cache"] = [] def check_network(self, username, social_network): From c34524299782270a66e49210913dce0942e5e58c Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 15:27:11 -0400 Subject: [PATCH 14/20] url display for single site --- sopel_modules/SpiceBot_Core_Commands/Sherlock.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sopel_modules/SpiceBot_Core_Commands/Sherlock.py b/sopel_modules/SpiceBot_Core_Commands/Sherlock.py index 452c6c4..c30a9b6 100644 --- a/sopel_modules/SpiceBot_Core_Commands/Sherlock.py +++ b/sopel_modules/SpiceBot_Core_Commands/Sherlock.py @@ -39,7 +39,7 @@ def bot_command_sherlock(bot, trigger): if inlist != []: if checklistname != 'all': - bot.osd(["The username " + username + " is in " + checklist[0]]) + bot.osd(["The username " + username + " is in " + checklist[0], SpiceBot.sherlock.dict.get(social_network).get("url").format(username)]) else: bot.osd(["The username " + username + " is in the following:", spicemanip.main(inlist, "andlist")]) if notinlist != []: From 79d6f8678481bcfbcdc700444ad7f2c717b58d65 Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 15:46:29 -0400 Subject: [PATCH 15/20] 30 minute cache for false --- sopel_modules/SpiceBot/Sherlock.py | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/sopel_modules/SpiceBot/Sherlock.py b/sopel_modules/SpiceBot/Sherlock.py index d8ec4ec..50193c5 100644 --- a/sopel_modules/SpiceBot/Sherlock.py +++ b/sopel_modules/SpiceBot/Sherlock.py @@ -9,6 +9,7 @@ from .Tools import read_directory_json_to_dict import os from fake_useragent import UserAgent import requests +import time class Sherlock(): @@ -27,12 +28,16 @@ class Sherlock(): for social_network in list(valid_usernames_dict.keys()): self.dict[social_network] = valid_usernames_dict[social_network] - self.dict[social_network]["cache"] = [] + self.dict[social_network]["cache"] = dict() def check_network(self, username, social_network): - if username in self.dict[social_network]["cache"]: - return True + if username in list(self.dict[social_network]["cache"].keys()): + if not self.dict[social_network]["cache"][username]["exists"]: + if time.time() - self.dict[social_network]["cache"][username]["time"] <= 1800: + return True + else: + return True url = self.dict.get(social_network).get("url").format(username) error_type = self.dict.get(social_network).get("errorType") @@ -63,8 +68,11 @@ class Sherlock(): if error in r.url: user_exists = False + if username not in list(self.dict[social_network]["cache"].keys()): + self.dict[social_network]["cache"][username] = {} + self.dict[social_network]["cache"][username]["time"] = time.time() + self.dict[social_network]["cache"][username]["exists"] = user_exists if user_exists: - self.dict[social_network]["cache"].append(username) return True else: return False From 92414f85f03a6261d1d8764c376feb67b3c898f7 Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 16:00:03 -0400 Subject: [PATCH 16/20] test reverse logic --- sopel_modules/SpiceBot/Sherlock.py | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/sopel_modules/SpiceBot/Sherlock.py b/sopel_modules/SpiceBot/Sherlock.py index 50193c5..d99e0f1 100644 --- a/sopel_modules/SpiceBot/Sherlock.py +++ b/sopel_modules/SpiceBot/Sherlock.py @@ -49,29 +49,30 @@ class Sherlock(): r, error_type = self.make_request(url=url, error_type=error_type, social_network=social_network) - user_exists = True + user_exists = False if error_type == "message": error = self.dict.get(social_network).get("errorMsg") # Checks if the error message is in the HTML - if error in r.text: - user_exists = False + if error not in r.text: + user_exists = True elif error_type == "status_code": # Checks if the status code of the repsonse is 404 - if r.status_code == 404: - user_exists = False + if not r.status_code == 404: + user_exists = True elif error_type == "response_url": error = self.dict.get(social_network).get("errorUrl") # Checks if the redirect url is the same as the one defined in data.json - if error in r.url: - user_exists = False + if error not in r.url: + user_exists = True if username not in list(self.dict[social_network]["cache"].keys()): self.dict[social_network]["cache"][username] = {} self.dict[social_network]["cache"][username]["time"] = time.time() self.dict[social_network]["cache"][username]["exists"] = user_exists + if user_exists: return True else: From 827449c97456976cf018f047fc0a17058d162767 Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 16:04:42 -0400 Subject: [PATCH 17/20] test --- sopel_modules/SpiceBot/Sherlock.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sopel_modules/SpiceBot/Sherlock.py b/sopel_modules/SpiceBot/Sherlock.py index d99e0f1..5f7f6f0 100644 --- a/sopel_modules/SpiceBot/Sherlock.py +++ b/sopel_modules/SpiceBot/Sherlock.py @@ -68,10 +68,10 @@ class Sherlock(): if error not in r.url: user_exists = True - if username not in list(self.dict[social_network]["cache"].keys()): - self.dict[social_network]["cache"][username] = {} - self.dict[social_network]["cache"][username]["time"] = time.time() - self.dict[social_network]["cache"][username]["exists"] = user_exists + self.dict[social_network]["cache"][username] = { + "time": time.time(), + "exists": user_exists + } if user_exists: return True From 761238038034316d6efc39ab5063ab0bf6cbe756 Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 16:07:50 -0400 Subject: [PATCH 18/20] better --- sopel_modules/SpiceBot/Sherlock.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/sopel_modules/SpiceBot/Sherlock.py b/sopel_modules/SpiceBot/Sherlock.py index 5f7f6f0..43b6dfa 100644 --- a/sopel_modules/SpiceBot/Sherlock.py +++ b/sopel_modules/SpiceBot/Sherlock.py @@ -33,11 +33,8 @@ class Sherlock(): def check_network(self, username, social_network): if username in list(self.dict[social_network]["cache"].keys()): - if not self.dict[social_network]["cache"][username]["exists"]: - if time.time() - self.dict[social_network]["cache"][username]["time"] <= 1800: - return True - else: - return True + if time.time() - self.dict[social_network]["cache"][username]["time"] <= 1800: + return self.dict[social_network]["cache"][username]["exists"] url = self.dict.get(social_network).get("url").format(username) error_type = self.dict.get(social_network).get("errorType") From 9f2890441dfca7745fa8cbf84f77f106425c6db4 Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Mon, 17 Jun 2019 16:22:30 -0400 Subject: [PATCH 19/20] cleanup --- sopel_modules/SpiceBot_Core_Commands/Sherlock.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sopel_modules/SpiceBot_Core_Commands/Sherlock.py b/sopel_modules/SpiceBot_Core_Commands/Sherlock.py index c30a9b6..86e5c4b 100644 --- a/sopel_modules/SpiceBot_Core_Commands/Sherlock.py +++ b/sopel_modules/SpiceBot_Core_Commands/Sherlock.py @@ -37,10 +37,10 @@ def bot_command_sherlock(bot, trigger): else: notinlist.append(social_network) - if inlist != []: + if len(inlist): if checklistname != 'all': bot.osd(["The username " + username + " is in " + checklist[0], SpiceBot.sherlock.dict.get(social_network).get("url").format(username)]) else: bot.osd(["The username " + username + " is in the following:", spicemanip.main(inlist, "andlist")]) - if notinlist != []: + if len(notinlist): bot.osd(["The username " + username + " is NOT in the following:", spicemanip.main(notinlist, "andlist")]) From 0cdf5230e5568367186aea503b9338b3d706149c Mon Sep 17 00:00:00 2001 From: deathbybandaid Date: Wed, 19 Jun 2019 07:41:36 -0400 Subject: [PATCH 20/20] all notice --- sopel_modules/SpiceBot_Core_Commands/Sherlock.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sopel_modules/SpiceBot_Core_Commands/Sherlock.py b/sopel_modules/SpiceBot_Core_Commands/Sherlock.py index 86e5c4b..d38f32d 100644 --- a/sopel_modules/SpiceBot_Core_Commands/Sherlock.py +++ b/sopel_modules/SpiceBot_Core_Commands/Sherlock.py @@ -41,6 +41,9 @@ def bot_command_sherlock(bot, trigger): if checklistname != 'all': bot.osd(["The username " + username + " is in " + checklist[0], SpiceBot.sherlock.dict.get(social_network).get("url").format(username)]) else: - bot.osd(["The username " + username + " is in the following:", spicemanip.main(inlist, "andlist")]) + bot.osd(["The username " + username + " is in the following:", spicemanip.main(inlist, "andlist")], trigger.nick, 'NOTICE') if len(notinlist): - bot.osd(["The username " + username + " is NOT in the following:", spicemanip.main(notinlist, "andlist")]) + if checklistname != 'all': + bot.osd(["The username " + username + " is NOT in the following:", spicemanip.main(notinlist, "andlist")]) + else: + bot.osd(["The username " + username + " is NOT in the following:", spicemanip.main(notinlist, "andlist")], trigger.nick, 'NOTICE')