Skip to content

Instantly share code, notes, and snippets.

@jamtur01
Created February 6, 2012 03:35
Show Gist options
  • Save jamtur01/1749382 to your computer and use it in GitHub Desktop.
Save jamtur01/1749382 to your computer and use it in GitHub Desktop.
#! /usr/bin/env ruby
require 'socket'
action = ARGV[0]
alert = ARGV[1]
irccat_server = "localhost"
irccat_port = "12345"
irccat_channel = "#plops"
message = "#{irccat_channel} PUPPET: The user #{ENV['USER']} did #{action} to #{alert}"
s = TCPSocket.open(irccat_server,irccat_port)
s.write(message)
s.close
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment