diff --git a/README-cn.md b/README-cn.md index 3bbad8c..d00bf95 100644 --- a/README-cn.md +++ b/README-cn.md @@ -1,36 +1,21 @@ 一个私人的维基——vim插件 ============================================================================== -这是http://www.vim.org/scripts/script.php?script_id=2226 的一个镜像。 - -在http://code.google.com/p/vimwiki/ 有部分截图文件。 -如果你不喜欢vimball,你也可以在那里找到zip的打包文件。 - - -在安装之前,你需要做的 -============================================================================== - -确定在`vimrc`中,你的设置是这样的。 - - set nocompatible - filetype plugin on - syntax on - -如果没有他们,Vimwiki将无法正常工作。 - +![screenshot1](doc/screenshot_1.png) +![screenshot2](doc/screenshot_2.png) 介绍 -============================================================================== +------------------------------------------------------------------------------ Vimwiki是私人维基的vim插件 -- 许多有自己代码高亮的text文件。 -通过vimwiki,你可以: +通过Vimwiki,你可以: * 组织笔记和想法 * 制作代办事项表 * 写文档 -一个快速的开始,通常使用`ww`(一般是'\ww'),然后创建你的index wiki文件。 +一个快速的开始,通常使用`ww`(一般是`\ww`),然后创建你的index wiki文件。 通常,它在: ~/vimwiki/index.wiki @@ -42,30 +27,33 @@ Vimwiki是私人维基的vim插件 -- 许多有自己代码高亮的text文件 * Project Gutenberg -- good books are power. * Scratchpad -- various temporary stuff. -将你的光标放到'Tasks'(任务)上,并且按回车键去创建一个链接。一旦按下,'Task'将会 -变成'[[Tasks]]' -- 一个vimwiki的链接。再按一次回车去打开它。编辑文件,保存它, +将你的光标放到`Tasks`(任务)上,并且按回车键去创建一个链接。一旦按下,`Task`将会 +变成`[[Tasks]]` -- 一个vimwiki的链接。再按一次回车去打开它。编辑文件,保存它, 然后按backspace来返回你的index。 一个vimwiki链接可以一句话创建。只需要通过选择visual模式选择这个句子,然后按回车。 -你可以通过选择'Project Gutenberg'来尝试。结果像是这个样子: +你可以通过选择`Project Gutenberg`来尝试。结果像是这个样子: = My knowledge base = * [[Tasks]] -- things to be done _yesterday_!!! * [[Project Gutenberg]] -- good books are power. * Scratchpad -- various temporary stuff. -更多的选项,请用`:h vimwiki-options`来查看。 - 基本标记 -============================================================================== -查看`:h vimwiki-syntax` +------------------------------------------------------------------------------ - *bold* -- bold - _italic_ -- italic + = Header1 = + == Header2 == + === Header3 === + + + *bold* -- bold text + _italic_ -- italic text + + [[wiki link]] -- wiki link + [[wiki link|description]] -- wiki link with description - [[wiki link]] -- link with spaces - [[wiki link|description]] -- link with description 列表: @@ -84,16 +72,14 @@ Vimwiki是私人维基的vim插件 -- 许多有自己代码高亮的text文件 a) numbered list item 3 b) numbered list item 4 - = Header1 = - == Header2 == - === Header3 === + +查看`:h vimwiki-syntax` 键位绑定 -============================================================================== -查看`:h vimwiki-mappings` +------------------------------------------------------------------------------ -normal 模式: +normal 模式: * `ww` -- 打开默认的wiki index文件 * `wt` -- 通过tab实现上一个功能 @@ -107,22 +93,39 @@ normal 模式: * `` -- 寻找下一个wiki链接 * `` -- 寻找上一个wiki链接 +查看`:h vimwiki-mappings` + 命令 -============================================================================== +------------------------------------------------------------------------------ * `:Vimwiki2HTML` -- 转换当前wiki成为html * `:VimwikiAll2HTML` -- 转化你的全部wiki到html * `:help vimwiki-commands` -- 显示全部命令 - + + 安装细节 -============================================================================== +============================================================================== + +在安装之前,你需要做的 +------------------------------------------------------------------------------ + +确定在`vimrc`中,你的设置是这样的。 + + set nocompatible + filetype plugin on + syntax on + +如果没有他们,Vimwiki将无法正常工作。 + + 使用 pathogen (译者注:一个插件) (http://www.vim.org/scripts/script.php?script_id=2332 ) +------------------------------------------------------------------------------ cd ~/.vim mkdir bundle cd bundle - git clone git://github.com/vim-scripts/vimwiki.git + git clone https://github.com/vimwiki/vimwiki.git 然后启动vim,使用`:Helptags` 然后 `:help vimwiki`来确保他已经被安装了。 diff --git a/README.md b/README.md index 004a5cd..9eee1f1 100644 --- a/README.md +++ b/README.md @@ -1,38 +1,25 @@ -A Personal Wiki For Vim Plugin +A Personal Wiki For Vim ============================================================================== -This is a mirror of http://www.vim.org/scripts/script.php?script_id=2226 - -Screenshots are available on http://code.google.com/p/vimwiki/ -There are also zipped vimwiki files there in case you do not like vimball archives. - - -Prerequisites -============================================================================== - -Make sure you have these settings in your vimrc file: - - set nocompatible - filetype plugin on - syntax on - -Without them Vimwiki will not work properly. - +![screenshot1](doc/screenshot_1.png) +![screenshot2](doc/screenshot_2.png) Intro -============================================================================== +------------------------------------------------------------------------------ + Vimwiki is a personal wiki for Vim -- a number of linked text files that have their own syntax highlighting. -With vimwiki you can: +With Vimwiki you can: - * organize notes and ideas; - * manage todo-lists; - * write documentation. + * organize notes and ideas + * manage todo-lists + * write documentation + * maintain a diary + * export everything to HTML To do a quick start press `ww` (this is usually `\ww`) to go to your index -wiki file. By default it is located in: - ~/vimwiki/index.wiki +wiki file. By default it is located in `~/vimwiki/index.wiki`. Feed it with the following example: @@ -41,32 +28,35 @@ Feed it with the following example: * Project Gutenberg -- good books are power. * Scratchpad -- various temporary stuff. -Place your cursor on 'Tasks' and press Enter to create a link. Once pressed, -'Tasks' will become '[[Tasks]]' -- a vimwiki link. Press Enter again to +Place your cursor on `Tasks` and press Enter to create a link. Once pressed, +`Tasks` will become `[[Tasks]]` -- a Vimwiki link. Press Enter again to open it. Edit the file, save it, and then press Backspace to jump back to your index. -A vimwiki link can be constructed from more than one word. Just visually -select the words to be linked and press Enter. Try it with 'Project -Gutenberg'. The result should look something like: +A Vimwiki link can be constructed from more than one word. Just visually +select the words to be linked and press Enter. Try it with `Project Gutenberg`. +The result should look something like: = My knowledge base = * [[Tasks]] -- things to be done _yesterday_!!! * [[Project Gutenberg]] -- good books are power. * Scratchpad -- various temporary stuff. -For the various options see `:h vimwiki-options`. - Basic Markup -============================================================================== -see `:h vimwiki-syntax` +------------------------------------------------------------------------------ - *bold* -- bold - _italic_ -- italic + = Header1 = + == Header2 == + === Header3 === + + + *bold* -- bold text + _italic_ -- italic text + + [[wiki link]] -- wiki link + [[wiki link|description]] -- wiki link with description - [[wiki link]] -- link with spaces - [[wiki link|description]] -- link with description Lists: @@ -85,45 +75,61 @@ Lists: a) numbered list item 3 b) numbered list item 4 - = Header1 = - == Header2 == - === Header3 === + +For other syntax elements, see `:h vimwiki-syntax` Key bindings -============================================================================== -see `:h vimwiki-mappings` +------------------------------------------------------------------------------ -normal mode: +normal mode: - * `ww` -- Open default wiki index file. - * `wt` -- Open default wiki index file in a new tab. - * `ws` -- Select and open wiki index file. - * `wd` -- Delete wiki file you are in. - * `wr` -- Rename wiki file you are in. - * `` -- Follow/Create wiki link - * `` -- Split and follow/create wiki link - * `` -- Vertical split and follow/create wiki link - * `` -- Go back to parent(previous) wiki link - * `` -- Find next wiki link - * `` -- Find previous wiki link + * `ww` -- Open default wiki index file. + * `wt` -- Open default wiki index file in a new tab. + * `ws` -- Select and open wiki index file. + * `wd` -- Delete wiki file you are in. + * `wr` -- Rename wiki file you are in. + * `` -- Follow/Create wiki link + * `` -- Split and follow/create wiki link + * `` -- Vertical split and follow/create wiki link + * `` -- Go back to parent(previous) wiki link + * `` -- Find next wiki link + * `` -- Find previous wiki link + +For more keys, see `:h vimwiki-mappings` -Commands -============================================================================== +Commands +------------------------------------------------------------------------------ - * `:Vimwiki2HTML` -- Convert current wiki link to HTML - * `:VimwikiAll2HTML` -- Convert all your wiki links to HTML + * `:Vimwiki2HTML` -- Convert current wiki link to HTML + * `:VimwikiAll2HTML` -- Convert all your wiki links to HTML * `:help vimwiki-commands` -- list all commands - -Install details -============================================================================== -Using pathogen (http://www.vim.org/scripts/script.php?script_id=2332 ) + +Installation +============================================================================== + +Prerequisites +------------------------------------------------------------------------------ + +Make sure you have these settings in your vimrc file: + + set nocompatible + filetype plugin on + syntax on + +Without them Vimwiki will not work properly. + + +Installation using [Pathogen](http://www.vim.org/scripts/script.php?script_id=2332) +------------------------------------------------------------------------------ cd ~/.vim mkdir bundle cd bundle - git clone git://github.com/vim-scripts/vimwiki.git + git clone https://github.com/vimwiki/vimwiki.git -Then launch vim, run `:Helptags` and then `:help vimwiki` to verify it was installed. +Or download the [zip archive](https://github.com/vimwiki/vimwiki/archive/master.zip) and extract it in `~/.vim/bundle/` + +Then launch Vim, run `:Helptags` and then `:help vimwiki` to verify it was installed.