@@ -1,14 +1,22 @@ ( Rx to IRC Bindings ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ) ( Copyright [c] 2010, Charles Childers ) ( License: ISC ) ( ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ) +( Commands: ) +( /server servername ) +( /nick nickname ) +( /who identity ) +( /join channel ) +( say text ) +( in channel ) +( ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ) &net open ( Data ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ) create crlf 10 , 13 , 0 , -variable socket +2 elements socket channel ( Code ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ) : send ( $- ) @socket net.send drop ; : sendn ( $- ) send crlf send ; @@ -24,22 +32,29 @@ : lines ( n- ) for line next ; : skim ( "- ) repeat key 27 = if; line again ; }} -: say ( "- ) - s" PRIVMSG #retro :" send 27 accept tib sendn ; +: in ( "- ) token keepString !channel ; +{{ + : to ( - ) s" PRIVMSG " send @channel send s" :" send ; + : msg ( "- ) 27 accept tib sendn ; +---reveal--- + : say ( "- ) to msg pong ; +}} : /server ( "- ) token 6667 net.socket dup !socket net.connect drop ; -: /nick ( "- ) - s" NICK " send token sendn ; -: /user ( "- ) - s" USER " send token send - s" 8 * : Charles Childers" sendn ; -: /join ( "- ) - s" JOIN " send token sendn ; +: /nick ( "- ) s" NICK " send token sendn ; +: /join ( "- ) s" JOIN " send token sendn ; +{{ + : who ( "- ) s" USER " send token send ; + : ident ( - ) s" 8 * : Charles Childers" sendn ; +---reveal--- + : /user ( "- ) who ident ; +}} ( Make Connection ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ) /server kornbluth.freenode.net /nick rx-irc /user crc /join #retro +in #retro