aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Daniel Washburn <daniel@washburn.at> 2015-06-27 14:10:34 -0400
committerGravatar Daniel Washburn <daniel@washburn.at> 2015-06-27 14:10:34 -0400
commitb35098a2039e432efc5f4b22e4f9e6dcd08aa66b (patch)
tree7f8131c659ce80cd7f0bc72e0f11aeab86b66902
parentdf7830e8a9278588b878f9226752dae1cf79e099 (diff)
downloadpyrc-b35098a2039e432efc5f4b22e4f9e6dcd08aa66b.tar.gz
pyrc-b35098a2039e432efc5f4b22e4f9e6dcd08aa66b.tar.bz2
pyrc-b35098a2039e432efc5f4b22e4f9e6dcd08aa66b.zip
Add README with license info and example usageHEADv1.0.0master
-rw-r--r--README.md48
1 files changed, 48 insertions, 0 deletions
diff --git a/README.md b/README.md
new file mode 100644
index 0000000..ff3a957
--- /dev/null
+++ b/README.md
@@ -0,0 +1,48 @@
+# PyRC #
+
+An IRC library written in Python
+
+## License ##
+
+[BSD 3-Clause](http://opensource.org/licenses/BSD-3-Clause). See LICENSE.
+
+## Usage ##
+
+```
+#!/usr/bin/python
+
+import PyRC
+import sys
+import time
+
+Irc = PyRC.Client()
+
+Irc.connect(host='irc.example.com')
+
+# Give the server a moment to respond
+time.sleep(2.0)
+
+print Irc.main_loop()
+
+Irc.join("#example)
+
+print Irc.main_loop()
+
+Irc.message('#example', 'PyRC Bot is listening')
+
+print Irc.main_loop()
+
+while True:
+ try:
+ msgs = Irc.main_loop()
+ if msgs:
+ for line in msgs:
+ print line
+ time.sleep(1.0)
+ msgs = []
+ except KeyboardInterrupt:
+ Irc.quit('Powered by PyRC Bot')
+```
+
+<br />
+Copyright (c) 2009-2015, Daniel Washburn. All rights reserved.