aboutsummaryrefslogtreecommitdiffstats
path: root/twittperator/echo-tweet.tw
diff options
context:
space:
mode:
authoranekos2010-07-31 13:28:06 +0000
committeranekos2010-07-31 13:28:06 +0000
commit2b3369c42933e0fe8a7e4badaeaeb25e0a8f985d (patch)
tree9520cb04c70f9c9ea8ee513a6a6a77fccfcb2bd0 /twittperator/echo-tweet.tw
parent69738e4e99457425f9ea3d3c26feb8de4e50c5e4 (diff)
downloadvimperator-plugins-2b3369c42933e0fe8a7e4badaeaeb25e0a8f985d.tar.bz2
twittperator のプラグイン
git-svn-id: http://svn.coderepos.org/share/lang/javascript/vimperator-plugins/trunk@38105 d0d07461-0603-4401-acd4-de1884942a52
Diffstat (limited to 'twittperator/echo-tweet.tw')
-rwxr-xr-xtwittperator/echo-tweet.tw15
1 files changed, 15 insertions, 0 deletions
diff --git a/twittperator/echo-tweet.tw b/twittperator/echo-tweet.tw
new file mode 100755
index 0000000..ff85e79
--- /dev/null
+++ b/twittperator/echo-tweet.tw
@@ -0,0 +1,15 @@
+/*
+ * Please write the below line into .vimperatorrc.
+ * let g:twittperator_plugin_echo_tweet = 1
+ */
+
+(function () {
+ plugins.twittperator.ChirpUserStream.addListener(
+ function onMsg (msg, raw) {
+ if (msg.text)
+ liberator.echo(msg.user.screen_name + ": " + msg.text, commandline.FORCE_SINGLELINE);
+ }
+ );
+})();
+
+// vim: sw=2 ts=2 et fdm=marker ft=javascript: