Erlang syntax checking and compiler plugin for Vim
See the codevim-erlang-compiler is an Erlang syntax checking and compiler plugin for
Vim.
This is the recommended installation method if you use at least Vim 8 and you don't use another package manager.
Information about Vim's built-in package manager: :help packages.
Installation steps:
Clone this repository (you can replace foo with the directory name of your
choice):
$ git clone https://github.com/vim-erlang/vim-erlang-compiler.git \
~/.vim/pack/foo/start/vim-erlang-compiler
Restart Vim.
Generate help page (replace foo with the same directory name as above):
:helptags ~/.vim/pack/foo/start/vim-erlang-compiler/doc
Information about Pathogen: Pathogen repository.
Installation steps:
Clone this repository:
$ git clone https://github.com/vim-erlang/vim-erlang-compiler.git \
~/.vim/bundle/vim-erlang-compiler
Restart Vim.
Generate help page:
:Helptags
Information about Vundle: Vundle repository.
Installation steps:
Add vim-erlang-compiler to your plugin list in .vimrc by inserting
the line that starts with Plugin:
call vundle#begin()
[...]
Plugin 'vim-erlang/vim-erlang-compiler'
[...]
call vundle#end()
Restart Vim.
Run :PluginInstall.
Information about Vim-Plug: vim-plug repository.
Installation steps:
Add vim-erlang-compiler to your plugin list in .vimrc by inserting the
line that starts with Plug:
call plug#begin()
[...]
Plug 'vim-erlang/vim-erlang-compiler'
[...]
call plug#end()
Restart Vim.
Run :PlugInstall.
:help vim-erlang-compiler.If vim-erlang-compiler shows you a compilation error even though there is no
compilation error when using your usual build tool, please follow these steps:
Compile your project with your usual build tool first (e.g., rebar compile, rebar3 compile or make), and then try again with
vim-erlang-compiler.
Reason: vim-erlang-compiler needs the ebin directories and app files
to be in place, because that is how Erlang itself finds applications when
compiling the -include_lib directives.
Execute the following command from the terminal:
$ /path/to/vim-erlang-compiler/compiler/erlang_check.erl \
--verbose /path/to/myfile.erl
Reason:
vim-erlang-compiler uses erlang_check.erl to compile the Erlang
source files. The --verbose option shows more information, which might
help you to figure out the problem.
If this produces the same error, we can be sure that the problem is on the Erlang side (not the Vim side).
Check the existing open issues on GitHub. Someone may have already reported the same problem.
If none of the above helps, open a new issue with the following information:
Which build system do you use? rebar2, rebar3, Makefile, or nothing?
What is the piece of code that cannot be compiled?
What is the verbose output of the erlang_check.erl script? (See
step 2.)
It helps if you can share the project which fails to compile (or a simplified version of it).
g:erlang_make_options but it didn't take effectSee the "Reloading" paragraph in the g:erlang_make_options_rules section in
the user documentation.
Please read the Contributing section of the
vim-erlang README.
If you modify compiler/erlang_check.erl, please:
update the tests in the vim-erlang repository.
also modify vim-erlang-omnicomplete (if you modify the
"load build information" code block)
Erlang
81.8%
Vim Script
18.2%
Erlang syntax checking and compiler plugin for Vim
See the codevim-erlang-compiler is an Erlang syntax checking and compiler plugin for
Vim.
This is the recommended installation method if you use at least Vim 8 and you don't use another package manager.
Information about Vim's built-in package manager: :help packages.
Installation steps:
Clone this repository (you can replace foo with the directory name of your
choice):
$ git clone https://github.com/vim-erlang/vim-erlang-compiler.git \
~/.vim/pack/foo/start/vim-erlang-compiler
Restart Vim.
Generate help page (replace foo with the same directory name as above):
:helptags ~/.vim/pack/foo/start/vim-erlang-compiler/doc
Information about Pathogen: Pathogen repository.
Installation steps:
Clone this repository:
$ git clone https://github.com/vim-erlang/vim-erlang-compiler.git \
~/.vim/bundle/vim-erlang-compiler
Restart Vim.
Generate help page:
:Helptags
Information about Vundle: Vundle repository.
Installation steps:
Add vim-erlang-compiler to your plugin list in .vimrc by inserting
the line that starts with Plugin:
call vundle#begin()
[...]
Plugin 'vim-erlang/vim-erlang-compiler'
[...]
call vundle#end()
Restart Vim.
Run :PluginInstall.
Information about Vim-Plug: vim-plug repository.
Installation steps:
Add vim-erlang-compiler to your plugin list in .vimrc by inserting the
line that starts with Plug:
call plug#begin()
[...]
Plug 'vim-erlang/vim-erlang-compiler'
[...]
call plug#end()
Restart Vim.
Run :PlugInstall.
:help vim-erlang-compiler.If vim-erlang-compiler shows you a compilation error even though there is no
compilation error when using your usual build tool, please follow these steps:
Compile your project with your usual build tool first (e.g., rebar compile, rebar3 compile or make), and then try again with
vim-erlang-compiler.
Reason: vim-erlang-compiler needs the ebin directories and app files
to be in place, because that is how Erlang itself finds applications when
compiling the -include_lib directives.
Execute the following command from the terminal:
$ /path/to/vim-erlang-compiler/compiler/erlang_check.erl \
--verbose /path/to/myfile.erl
Reason:
vim-erlang-compiler uses erlang_check.erl to compile the Erlang
source files. The --verbose option shows more information, which might
help you to figure out the problem.
If this produces the same error, we can be sure that the problem is on the Erlang side (not the Vim side).
Check the existing open issues on GitHub. Someone may have already reported the same problem.
If none of the above helps, open a new issue with the following information:
Which build system do you use? rebar2, rebar3, Makefile, or nothing?
What is the piece of code that cannot be compiled?
What is the verbose output of the erlang_check.erl script? (See
step 2.)
It helps if you can share the project which fails to compile (or a simplified version of it).
g:erlang_make_options but it didn't take effectSee the "Reloading" paragraph in the g:erlang_make_options_rules section in
the user documentation.
Please read the Contributing section of the
vim-erlang README.
If you modify compiler/erlang_check.erl, please:
update the tests in the vim-erlang repository.
also modify vim-erlang-omnicomplete (if you modify the
"load build information" code block)
Erlang
81.8%
Vim Script
18.2%