Twitter notifications with TeamCity
I was surfing Stackoverflow when I saw a request for a Twitter Notifier for TeamCity from Lance Fisher. I decided to implement it because I’ve always been a big fan of how last.fm use IRC to do notifications and queries. Last.fm puts everything up on IRC there from Jira issues, builds, hosting alerts and more.
If you use to spend time on IRC you know it feels very similar using twitter. Using private accounts we can keep our companies notifications both restrictive and accessible. At our company I’m starting to get interested in more notifications so I can keep track of how what’s happening company wide.
What you’ll need
- Twitter TeamCity Notifier
- TeamCity
- Java 1.6
The default install of TeamCity installs with Java 1.5 so you’ll want to update to 1.6 if you haven’t already. You can do this by installing the JRE and then copying it into the c:\TeamCity\jre dir.
to check what version of java TeamCity is using try this command
c:\TeamCity\jre\bin\java.exe –version
After you install Java 1.6 you’ll want erase the contents of c:\TeamCity\jre and replace them with the jre folder that you can find under C:\Program Files\Java\. In my case the folder was C:\Program Files\Java\jdk1.6.0_10\jre
Installing Twitter Notifier
- extract the zip into C:\TeamCity\webapps\ROOT\WEB-INF\lib
- restart the teamcity service
Configuring your notifications
login to teamcity and goto My Tools and Settings
here you’ll see some boxes to enter your twitter account.
If you click edit you can specify the rules for the notifications
make sure you select all projects and tick off conditions you want to send tweets for
Notifications in action
Now when I trigger a build it notifies twitter.
Don’t worry I’m going to add fields that let you customize messages in the future.
Communication is harder when your distributed






Hi Scott,
After Java 1.6 JDK installation I erased the contents of c:\TeamCity\jre and replaced them with the jre folder that I found under C:\Program Files\Java\.
In my case the folder was C:\Program Files\Java\jdk1.6.0_13\jre\
Unfortunately when I try to start “TeamCity Web Server” the service doesn’t start
Have you any suggestion ?
Thanks
Claudio
Hi,
the twitter notifier is a nice idea but I have problems with the replacement of the jre folder. The teamcity web server won’t start when it is replaced with the one of java1.6 . Do you have any idea?
I used Orn’s code here http://kristjansson.us/?p=690 to replace the dependency on JRE 1.6. and I added custom messages to the latest build.
Hi,
I’ve got the twitter feed working fine, however is there a way of including the project name in the message?
cheers
Ian
@Ian It ok I found it on your google code project page.
cheers
Ian