Must Feed Jenkins Troller

It’s true!

Our bot is live! And thou his name?

Must Feed Jenkins Troller!

His avatar?

Jenkins Jenkins of course!!

Following instructions from sevabot (documentation here), we managed to install him on an Ubuntu 12.04.4 LTS Server. Though this is a temporary server running on a home computer (and under a VM), future plans say that this bot will be imported to a more stable one, including specialized implementation for Jenkins, and Capistrano automation.

For now, since the scope is “trolling and feeding the trolls” we will present some of our scripts implementing funny mustfeedly available API’s from the Programmable Web and of course the ultimate , the one and only troll of our modern times :

Approved by Chuck Norris
Unlimited Data reside here…

Okay, so the first script is called and its a custom script, which allows our Troller to send a random Chuck Norris Fact to our channel (and everyone who wishes to learn a little bit about Chuck’s wisdom).

curl -s ';lastName=Norris' | grep -Po '(?<="joke": ")[^"]*'

In one line. and there is a problem with the html encoding, since icndb responds with html special chars like &quote &amp etc. This would be fixed though, in our second version with python integration.

curl -s '' | grep '&lt;p&gt;' | cut -c4-

The above line stops the drudgery in commit messages. Bored of watching those hooks in the commit message, and/or want to introduce a little more fun (and sometimes drama) in your message?

Well, just type !what to Must Feed Troller and he’ll give you the answer.

Now this one was the most elaborate. Who does not like pirates? Well we hell do! So, we found out that there is an api which translates what we want to say (but do not) into pirate talk!! ARRR!!

if [ "$1" == "" ]
          echo "Arrr!"
          for i in "$@"
            text+="$i "
          curl -s -G "" --data-urlencode "text=$text"

How it works you say? Well, simply type !p and the stuff you want to say to Mr. Pirate Troller ,

–And he replies: [11:10:28 PM] Must Feed Jenkins Troller: and yonder stuff you want to say to Mr. Pirate Troller

All our custom modules can be found at  : GitHub