summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xmodules/atwall11
-rwxr-xr-xmodules/join14
-rwxr-xr-xmodules/test10
-rwxr-xr-xmodules/twitter10
4 files changed, 37 insertions, 8 deletions
diff --git a/modules/atwall b/modules/atwall
new file mode 100755
index 00000000..66fca5e6
--- /dev/null
+++ b/modules/atwall
@@ -0,0 +1,11 @@
+#! /bin/sh
+
+case "$1" in
+ (--help) echo send text to everyone with @@ prepended ;;
+ (q)
+ echo quit chat mode
+ echo /set default_command espeak >$NOISE_linefeed;;
+
+ (*)
+ echo /wall @@ $* >$NOISE_linefeed
+esac
diff --git a/modules/join b/modules/join
new file mode 100755
index 00000000..af1c0117
--- /dev/null
+++ b/modules/join
@@ -0,0 +1,14 @@
+#! /bin/sh
+
+case "$1" in
+ (--help) echo set default_command to atwall and back ;;
+ (off)
+ echo /set default_command espeak >$NOISE_linefeed
+ echo "disabled chat mode (set back to espeak)" ;;
+ (*)
+ echo /set default_command atwall >$NOISE_linefeed
+ echo "enabled chat mode"
+ echo q or /chat off to go back to espeak ;;
+
+
+esac
diff --git a/modules/test b/modules/test
index 30444bf7..2c0b8e0d 100755
--- a/modules/test
+++ b/modules/test
@@ -3,7 +3,11 @@
case "$1" in
(--help) echo do some test-module related stuff ;;
(*)
- echo test-module called with following arguments: "$@"
- ## send command for re-evaluation:
- echo /espeak test >$NOISE_linefeed
+
+ echo -n ">> "
+ read TEST
+ if [ $TEST == 'q' ]; then exit; fi
+ echo /wall @@ $TEST >$NOISE_linefeed
+ #sleep 1
+ #sleep 1; echo /test >$NOISE_linefeed &
esac
diff --git a/modules/twitter b/modules/twitter
index e8962657..fa4d366d 100755
--- a/modules/twitter
+++ b/modules/twitter
@@ -33,7 +33,7 @@ def parse(text):
escape = ""
if piece.startswith("@"):
escape = ""
- if piece[1:].lower() == "shackspace":
+ if piece[1:].lower() == "shackspam" or piece[1:].lower() == "shackspace":
escape = ""
elif piece.startswith("#"):
@@ -48,16 +48,16 @@ def parse(text):
return new
if len(sys.argv) > 1 and sys.argv[1] == "--help":
- print "read or post to the shackspace twitter timeline"
+ print "read or post to the shackspam twitter timeline"
if len(sys.argv) == 3 and sys.argv[2] == "--verbose":
print "call without parameters to read"
- print "use /twitter [your tweet] to tweet something to the shackspace twitter timeline"
+ print "use /twitter [your tweet] to tweet something to the shackspam twitter timeline"
exit()
-api = twitter.Api(username="shackspace", password="0b0dallaf4lla")
+api = twitter.Api(username="shackspam", password="sh4ckit")
#api.SetXTwitterHeaders("Shackspace UTTERANCE","","0.00.0.01.42")
@@ -93,7 +93,7 @@ else:
a.reverse()
for i in a:
text = i.text
- if i.user.screen_name.lower() == "shackspace":
+ if i.user.screen_name.lower() == "shackspace" or i.user.screen_name.lower() == "shackspam":
info = "" + i.user.screen_name + " " + shorten(i.GetRelativeCreatedAt()) + ""
else:
info = "" + i.user.screen_name + " " + shorten(i.GetRelativeCreatedAt()) + ""