Guest User

Untitled

a guest
May 25th, 2018
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.28 KB | None | 0 0
  1. require 'socket'
  2. s=TCPSocket.new(*ARGV[0..1])
  3. s.puts "USER A B C D", "NICK waffles"
  4. while !s.eof?
  5. s.puts case s.gets
  6. when /^\S+ 001 .+/
  7. "JOIN #{ARGV[2]}"
  8. when /.+ :-quit( .+)?/
  9. "QUIT :#{$1}"
  10. when /.+ (.+) :-(.+)$/
  11. "PRIVMSG #{$1} :#{$2}"
  12. when /PING (.+)/
  13. "PONG #{$1}"
  14. end
  15. end
Add Comment
Please, Sign In to add comment