From f66aafa6df7fd356ef61ec6be7f5e911922a2429 Mon Sep 17 00:00:00 2001
From: anekos
Date: Wed, 19 Jan 2011 06:40:03 +0900
Subject: tw!info で RT の情報も得られるようにした
---
twittperator.js | 20 +++++++++++++-------
1 file changed, 13 insertions(+), 7 deletions(-)
(limited to 'twittperator.js')
diff --git a/twittperator.js b/twittperator.js
index 038a9f1..fe721b0 100644
--- a/twittperator.js
+++ b/twittperator.js
@@ -28,7 +28,7 @@ let PLUGIN_INFO =
Twittperator
Twitter Client using OAuth and Streaming API
OAuth/StreamingAPI対応Twitterクライアント
- 1.13.1
+ 1.13.2
2.3
3.0
teramako
@@ -1914,11 +1914,15 @@ let PLUGIN_INFO =
function removeNewLine (text)
text.replace(/\r\n|[\r\n]/g, ' ');
- function completer(generator)
- function(filter)
- makeTimelineCompleter(
- filter ? function(context, args) context.completions = history.map(rt).filter(filter).map(generator)
- : function(context, args) context.completions = history.map(rt).map(generator));
+ function completer(generator, nort) {
+ let getHistory = nort ? function() history
+ : function() history.map(rt);
+ return function(filter) {
+ return makeTimelineCompleter(
+ filter ? function(context, args) context.completions = getHistory().filter(filter).map(generator)
+ : function(context, args) context.completions = getHistory().map(generator));
+ }
+ }
return {
name:
@@ -1929,6 +1933,8 @@ let PLUGIN_INFO =
completer(function(s) [removeNewLine(s.text), s]),
id:
completer(function(s) [s.id, s]),
+ rawid:
+ completer(function(s) [s.id, s], true),
name_id:
completer(function(s) ["@" + s.user.screen_name + "#" + s.id, s]),
name_id_text:
@@ -2061,7 +2067,7 @@ let PLUGIN_INFO =
history.filter(function(st) st.id === id).map(dtdd).forEach(liberator.echo);
},
timelineCompleter: true,
- completer: Completers.id()
+ completer: Completers.rawid(function(st) st.id)
}),
SubCommand({
command: ["track"],
--
cgit v1.2.3