Vimrepress

(or VimREpress)

DESCRIPTION

Vimpress is a plugin for managing wordpress blog from Vim.

(I also call it VimRepress because this is a fork from a broken version with no support and update for years.)

DOWNLOAD

INSTALL

Besure you have a vim compiled with python 2.6+ supported. Mainly linux distrubutins are commonly included with one.

Download vimpress_2.x.x.zip, extract it in your .vim directory:

cd ~/.vim
unzip /path/to/vimpress_2.x.x.zip

If you need Markdown support, simply run `sudo apt-get install python-markdown’ in Ubuntu.

If you use other distributions (or OSs), refer to your package manager or the python-markdown project page: http://www.freewisdom.org/projects/python-markdown/Installation

Both python-markdown and python-markdown2 module are supported.

CONFIGURE

Edit ~/.vimrc , add a variable named VIMPRESS. Multiple blog configurations are supported.

Example:

let VIMPRESS = [{'username':'user', 
                \'password':'pass', 
                \'blog_url':'http://your-first-blog.com/' 
                \}, 
                \{'username':'user', 
                \'blog_url':'http://your-second-blog.com/' 
                \}]

Hardcoding the password is optional. If a password is not provided the plugin will prompt for one the first time it’s needed.

COMMAND EXAMPLES

Some commands list above contain special usage, example below may clearify them for you.

:BlogList             -  List recent posts. 
:BlogList page        -  List recent pages. 
                        (In the list view, Press DEL to move a post to trash. 
                                           Press Enter to edit a post.)

:BlogNew post         -  Write an new post. 
:BlogNew page         -  Write an new page.

:BlogSave             -  Save (defautely draft.) 
:BlogSave publish     -  Save as published post/page.

:BlogPreview local    -  Preview page/post locally in your browser. 
:BlogPreview publish  -  Same as `:BlogSave publish' with brower opened. 
:BlogOpen 679         -  Open to edit a post with it's id/url/link
:BlogOpen http://your-first-blog.com/archives/679 
:BlogOpen http://your-second-blog.com/?p=679 
:BlogOpen http://your-third-blog.com/with-your-custom-permalink
5 comments on “Vimrepress
  1. hilojack说道:

    博主,你好。我用的是arch,我已经安装过vimrepress了。不过为啥我的has(“python”)没有呢。
    if !has(“python”)
    finish
    endif
    我确实安装了python呀。
    $ pacman -Qs python |grep python
    local/python 3.3.0-1 python2

    • hilojack说道:

      Sorry.
      原因是vim –version|grep +python结果为空。使用gvim就默认包含了python支持了。

      不过,我还有个问题,我已经安装过python-markdown,为何还有这个提示:
      The package python-markdown is required and is either not present or not properl
      y installed.

      当然,vim –version是没有markdown支持的。请问我需要怎么做让VIM支持markdown呢?
      感谢!

    • BOYPT说道:

      我用的也是arch啊,gvim默认就依赖了python的了。

  2. wsdjeg说道:

    “`sh
    sudo pacman -s gvim
    “`

发表评论

电子邮件地址不会被公开。 必填项已用*标注

*