vim-draftin


Ⅰ. 插件描述

vim plugin for https://draftin.com

Ⅱ. 基本信息

创建日期:  2013-08-14
使用用户:  1
Github星:  4
插件作者:  Bartek Ciszkowski

Ⅲ. 安装方法

使用Vundle管理器安装

在你的.vimrc下添加:
Plugin 'bartek/vim-draftin'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall

对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。

使用NeoBundle管理器安装

在你的.vimrc下添加:
NeoBundle 'bartek/vim-draftin'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall

使用VimPlug管理器安装

在你的.vimrc下添加:
Plug 'bartek/vim-draftin'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall

使用Pathogen管理器安装

在终端中运行以下命令:
cd ~/.vim/bundle
git clone https://github.com/bartek/vim-draftin

Ⅳ. 文档说明

vim-draftin

Work in progress plugin for the excellent writing tool https://draftin.com

Dependencies

When creating/uploading a document the first time, a JSON response is received.
To parse this and extract the id,
vim-scripts/ParseJSON is used.

If the text/content contains certain characters (e.g. if you write about code), they
may have to be escaped in JSON.
vim-scripts/jsoncodecs.vim
handles this.

vim-draftin uses the program curl to send messages to draftin.com. How to install it
will depend on your system.

Installation

Pathogen
git clone https://github.com/bartek/vim-draftin ~/.vim/bundle/vim-draftin
Vundle
Plugin 'bartek/vim-draftin'
NeoBundle
NeoBundle 'bartek/vim-draftin'

Configuration

You'll need to set your https://draftin.com credentials to be able to
POST new documents. Within .vimrc (or in a file sourced from .vimrc):

let g:draftin_auth = "username:password"

Usage

  • :Draft will upload the document to Draft, echo'ing back the url. Arguments
    to the command will be used as the name of the document. If there are no

arguments, the name will be set to the first line of the content, or if that
is missing too, the file name.

  • :DraftRename <New name> will rename an existing Draft document to 'New name'

添加新评论