html_FileCompletion


Ⅰ. 插件描述

Base dir- and URL-aware file completion for HTML links.

Ⅱ. 基本信息

创建日期:  2012-05-15
使用用户:  1
Github星:  1
插件作者:  Ingo Karkat

Ⅲ. 安装方法

使用Vundle管理器安装

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

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

使用NeoBundle管理器安装

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

使用VimPlug管理器安装

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

使用Pathogen管理器安装

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

Ⅳ. 文档说明

DESCRIPTION
This plugin offers insert mode file completion for HTML links to local files,
taking into account a base directory (document root) and base URL (web server
location) to enable completion of absolute (/foo...) and fully qualified
(http://host/foo...) links.

RELATED WORKS

  • FilePathConvert.vim (vimscript #4885) converts filespecs between absolute,
      relative, and URL (file://) formats.

USAGE
CTRL-X CTRL-F           Find matches for file names that start with the same
                        'isfname' characters as before the cursor. File names
                        are inserted in URL-escaped form (e.g. <Space> -> %20)
                        and always with forward slashes as path separator.
                        An absolute file path starting with "/" is interpreted
                        relative to b:basedir, and a base URL b:baseurl is
                        stripped off the front. This enables you to complete
                        file links even though they are specified as absolute
                        or fully qualified links in the HTML.
                        When there are no matches within the base directory,
                        this falls back to default, non-URL-escaped file
                        completion (i_CTRL-X_CTRL-F).

添加新评论