Skip to main content

TwitVim: Tweeting in the vim

很久没更新了,因为很久没折腾了。

昨晚火星地发现了一个好东西:twitvim,是个vim script。
试用了下,很不错,该有的功能都有了。这里做个笔记。


1、安装
vim script下载twitvim的vba包。
用vim打开下载到的twitvim.vba,输入
:so %
回车完成安装。
安装curl,twitvim需要curl来fetching。
sudo apt-get install curl
2、配置
在.vimrc里添加
let twitvim_login = "user:pwd"
试用api,则添加
let twivim_api_root = "api_url"
使用代理,添加
let twitvim_proxy = "proxyhost:proxyport"
3、使用
进入vim
(via http://www.vim.org/scripts/script.php?script_id=2204
:PosttoTwitter - This command will prompt you for a message to send to Twitter.
:CPosttoTwitter - This command posts the current line in the current buffer to Twitter.
:BPosttoTwitter - This command posts the current buffer to Twitter.

Alt-T - In Visual select mode, the Alt-T key posts the selected text to Twitter.
  (use Ctrl-T instead if menu bar is enabled)
NOTE: The T mapping was changed to Alt-T to avoid overriding the T search command.

Alt-R - Starts a @-reply. (from timeline buffer)
Alt-D - Starts a direct message. (from timeline buffer)

:FriendsTwitter - View friends timeline.
:UserTwitter - View your timeline.
:RepliesTwitter - View @-replies.
:PublicTwitter - View public timeline.
:DMTwitter - View direct messages.

:Tweetburner - Shorten a URL with Tweetburner and insert at cursor.
:ATweetburner - Same as above but insert after cursor.
:PTweetburner - Same as above but start tweet on cmdline with short URL.

PS:某些情况下要用proxy
本人使用proxychains
连上ssh后,proxychains vim,即可正常使用。
附proxychains.conf

Comments

Popular posts from this blog

考试

公考成绩出了...发挥很稳定,和大四第一次考的成绩一样。排名23,还不错,今年有好好复习的动力了。 本周考职称外语,四月份考会计从业资格证,五月的计算机中级不知道要不要报名.. 今年肯定是考试的一年。

公考旅游

昨天是一年一度的浙江省公务员考试的日子,我也多了个借口到温州玩2天。 来之前早早的计划好了行程……没想到天有不测风云,同学开得披萨店没吃到,大学城故地重游也没去。 最后,两天半的时间和同学去了3次KTV...还是同一批人- -! ps:公务员对我来说就是个旅游的机会,2月前的国考让我去杭州玩了2天,为划船去了3次西湖但是都未能如愿……今年年底继续~

BACK HERE!

it has been a long time Since 2006 i set my blog at blogspot.com. i have tried other services such as wordpress, typecho, hexo, hugo etc because google had been blocked in 2008. Just tired of buying vps,install database and install blog applications. Get back here to stay simple.