commit 4d23bb14e5e90fc904ff3aa862533207673832e9
parent 87a32457bfdcdbdbccb4ff05b8bbca33136b7e8e
Author: Antoine Amarilli <ant.amarilli@free.fr>
Date: Sun, 13 Feb 2011 17:52:03 +0100
continue readme
Diffstat:
README | | | 22 | ++++++++++++++++------ |
1 file changed, 16 insertions(+), 6 deletions(-)
diff --git a/README b/README
@@ -61,7 +61,7 @@ Same, but address the message specifically to the person. The empty
"echo" indicates the end of our answer to the person.
Explain the "echo".
- $ cat fifo | ./irctk -Ffr wikibot@example.com '#chat' \
+ $ cat fifo | irctk -Ffr wikibot@example.com '#chat' \
| while read line; do
Q=$(echo "$line" | tr -dc 'a-zA-Z_()');
dig +short txt $Q.wp.dg.cx; echo;
@@ -69,7 +69,7 @@ Explain the "echo".
A bot which queries on wikipedia whatever is said to him.
- $ cat fifo | ./irctk -Ff DM@example.com '#adventure' \
+ $ cat fifo | irctk -Ff DM@example.com '#adventure' \
| while true; do
socat EXEC:adventure,pty,ctty,echo=0 STDIO;
done | tee fifo
@@ -79,15 +79,25 @@ their game, so run as a suitably unpriviledged user.) The "while true"
loop is to restart the game whenever it exits. The socat invocation
is used to disable buffering.
- $ ./irctk listener@source.com '#chan1' '#chan2' \
- | ./irctk repeater@destination.com
+ $ irctk listener@source.com '#chan1' '#chan2' \
+ | irctk repeater@destination.com
Repeat on destination.com whatever is said on channels #chan1 and #chan2
of source.com.
- $ cat fifo | ./irctk -fF0 gateway@server1.com '#chan1' \
- | ./irctk -fF0 gateway@server2.com '#chan2' | tee fifo
+ $ cat fifo | irctk -fF0 gateway@server1.com '#chan1' \
+ | irctk -fF0 gateway@server2.com '#chan2' | tee fifo
Two-way gateway: gateway posts on #chan1 on server1.com whatever
is said to him on #chan2 on server2.com, and vice-versa.
+ $ tail -f /var/log/syslog \
+ | irctk syslog@example.com '#syslog'
+
+Send your syslog messages to a channel.
+
+./irctk -pPo nick@localhost '#test' | cat > fifo
+cat fifo | while read line; do echo "`date +%R` $line"; done
+
+TODO poor man's irc client
+