phoenix.vim


Ⅰ. 插件描述

phoenix.vim: rails.vim inspired tools for Phoenix

Ⅱ. 基本信息

创建日期:  2016-04-05
使用用户:  79
Github星:  31
插件作者:  Conor Brennan

Ⅲ. 安装方法

使用Vundle管理器安装

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

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

使用NeoBundle管理器安装

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

使用VimPlug管理器安装

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

使用Pathogen管理器安装

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

Ⅳ. 文档说明

# phoenix.vim

phoenix.vim is a plugin inspired by rails.vim, aiming to offer the same
features (eventually).

phoenix.vim supports:

FeatureDescription
Projectionist NavigationNavigation using Projectionist - :Emodel and friends
JumpsUse the word under the cursor to jump to files with gf. For example, in an Ecto model: has_many :users, with the cursor on users, gf brings you to web/models/user.ex
GeneratorsRun Phoenix generators from within vim :Pgenerate model Foo foos bar:string
Server:Pserver runs mix phoenix.server - in a term for Neovim users or with dispatch for Vim users
Preview:Ppreview endpoints in your browser

Check out the documentation :h phoenix for the full list of features!

Installation

Use your favourite plugin manager, here we use vim-plug

As this plugin relies on Projectionist, you will need to
install it too.

Plug 'c-brenn/phoenix.vim'
Plug 'tpope/vim-projectionist' " required for some navigation features

Make sure to have this plugin before projectionist in your vimrc.

Documentation

Check out :h phoenix to find out more.

More Features To Come

The plan is to try and get feature parity with rails.vim eventually.
For now, the focus is on improving the navigation commands.

Issues

If you run into any bugs, open an issue in the tracker

添加新评论