2017-03-28 22:25:44 +00:00
|
|
|
===============================================================================
|
|
|
|
ALE C++ Integration *ale-cpp-options*
|
|
|
|
|
|
|
|
|
2017-07-08 13:17:26 +00:00
|
|
|
===============================================================================
|
2017-06-24 11:38:16 +00:00
|
|
|
Global Options
|
|
|
|
|
|
|
|
g:ale_c_build_dir_names *g:ale_c_build_dir_names*
|
|
|
|
*b:ale_c_build_dir_names*
|
|
|
|
|
|
|
|
Type: |List|
|
|
|
|
Default: `['build', 'bin']`
|
|
|
|
|
|
|
|
A list of directory names to be used when searching upwards from cpp
|
|
|
|
files to discover compilation databases with. For directory named `'foo'`,
|
|
|
|
ALE will search for `'foo/compile_commands.json'` in all directories on and above
|
|
|
|
the directory containing the cpp file to find path to compilation database.
|
|
|
|
This feature is useful for the clang tools wrapped around LibTooling (namely
|
|
|
|
here, clang-tidy)
|
|
|
|
|
|
|
|
|
|
|
|
g:ale_c_build_dir *g:ale_c_build_dir*
|
|
|
|
*b:ale_c_build_dir*
|
|
|
|
|
|
|
|
Type: |String|
|
|
|
|
Default: `''`
|
|
|
|
|
|
|
|
A path to the directory containing the `compile_commands.json` file to use
|
|
|
|
with c-family linters. Usually setting this option to a non-empty string
|
|
|
|
will override the |g:ale_c_build_dir_names| option to impose a compilation
|
|
|
|
database (it can be useful if multiple builds are in multiple build
|
|
|
|
subdirectories in the project tree).
|
|
|
|
This feature is also most useful for the clang tools linters, wrapped
|
|
|
|
aroung LibTooling (namely clang-tidy here)
|
|
|
|
|
2017-07-08 13:17:26 +00:00
|
|
|
===============================================================================
|
2017-03-28 22:25:44 +00:00
|
|
|
clang *ale-cpp-clang*
|
|
|
|
|
|
|
|
g:ale_cpp_clang_options *g:ale_cpp_clang_options*
|
2017-04-27 21:04:34 +00:00
|
|
|
*b:ale_cpp_clang_options*
|
2017-03-28 22:25:44 +00:00
|
|
|
Type: |String|
|
|
|
|
Default: `'-std=c++14 -Wall'`
|
|
|
|
|
|
|
|
This variable can be changed to modify flags given to clang.
|
|
|
|
|
|
|
|
|
2017-07-08 13:17:26 +00:00
|
|
|
===============================================================================
|
2017-06-24 15:10:04 +00:00
|
|
|
clangcheck *ale-cpp-clangcheck*
|
|
|
|
|
|
|
|
`clang-check` will be run only when files are saved to disk, so that
|
|
|
|
`compile_commands.json` files can be used. It is recommended to use this
|
|
|
|
linter in combination with `compile_commands.json` files.
|
|
|
|
Therefore, `clang-check` linter reads the options |g:ale_c_build_dir| and
|
|
|
|
|g:ale_c_build_dir_names|. Also, setting |g:ale_c_build_dir| actually
|
|
|
|
overrides |g:ale_c_build_dir_names|.
|
|
|
|
|
|
|
|
|
|
|
|
g:ale_cpp_clangcheck_options *g:ale_cpp_clangcheck_options*
|
|
|
|
*b:ale_cpp_clangcheck_options*
|
|
|
|
Type: |String|
|
|
|
|
Default: `''`
|
|
|
|
|
|
|
|
This variable can be changed to modify flags given to clang-check.
|
|
|
|
|
|
|
|
This variable should not be set to point to build subdirectory with
|
|
|
|
`-p path/to/build` option, as it is handled by the |g:ale_c_build_dir|
|
|
|
|
option.
|
|
|
|
|
|
|
|
|
2017-07-08 13:17:26 +00:00
|
|
|
===============================================================================
|
2017-03-28 22:25:44 +00:00
|
|
|
clangtidy *ale-cpp-clangtidy*
|
|
|
|
|
2017-05-02 21:44:08 +00:00
|
|
|
`clang-tidy` will be run only when files are saved to disk, so that
|
|
|
|
`compile_commands.json` files can be used. It is recommended to use this
|
|
|
|
linter in combination with `compile_commands.json` files.
|
2017-06-24 11:38:16 +00:00
|
|
|
Therefore, `clang-tidy` linter reads the options |g:ale_c_build_dir| and
|
|
|
|
|g:ale_c_build_dir_names|. Also, setting |g:ale_c_build_dir| actually
|
|
|
|
overrides |g:ale_c_build_dir_names|.
|
2017-05-02 21:44:08 +00:00
|
|
|
|
|
|
|
|
|
|
|
g:ale_cpp_clangtidy_checks *g:ale_cpp_clangtidy_checks*
|
|
|
|
*b:ale_cpp_clangtidy_checks*
|
|
|
|
Type: |List|
|
|
|
|
Default: `['*']`
|
|
|
|
|
|
|
|
The checks to enable for clang-tidy with the `-checks` argument.
|
|
|
|
|
|
|
|
All options will be joined with commas, and escaped appropriately for
|
|
|
|
the shell. The `-checks` flag can be removed entirely by setting this
|
|
|
|
option to an empty List.
|
|
|
|
|
2017-03-28 22:25:44 +00:00
|
|
|
g:ale_cpp_clangtidy_options *g:ale_cpp_clangtidy_options*
|
2017-04-27 21:04:34 +00:00
|
|
|
*b:ale_cpp_clangtidy_options*
|
2017-03-28 22:25:44 +00:00
|
|
|
Type: |String|
|
2017-05-02 21:44:08 +00:00
|
|
|
Default: `''`
|
|
|
|
|
|
|
|
This variable can be changed to modify flags given to clang-tidy.
|
2017-03-28 22:25:44 +00:00
|
|
|
|
2017-06-24 15:10:04 +00:00
|
|
|
- Setting this variable to a non-empty string,
|
|
|
|
- and working in a buffer where no compilation database is found using
|
|
|
|
|g:ale_c_build_dir_names| or |g:ale_c_build_dir|,
|
|
|
|
will cause the `--` argument to be passed to `clang-tidy`, which will mean
|
|
|
|
that detection of `compile_commands.json` files for compile command
|
|
|
|
databases will be disabled.
|
|
|
|
Only set this option if you want to control compiler flags
|
|
|
|
entirely manually, and no `compile_commands.json` file is in one
|
|
|
|
of the |g:ale_c_build_dir_names| directories of the project tree.
|
2017-03-28 22:25:44 +00:00
|
|
|
|
|
|
|
|
2017-07-08 13:17:26 +00:00
|
|
|
===============================================================================
|
2017-03-28 22:25:44 +00:00
|
|
|
cppcheck *ale-cpp-cppcheck*
|
|
|
|
|
|
|
|
g:ale_cpp_cppcheck_options *g:ale_cpp_cppcheck_options*
|
2017-04-27 21:04:34 +00:00
|
|
|
*b:ale_cpp_cppcheck_options*
|
2017-03-28 22:25:44 +00:00
|
|
|
Type: |String|
|
|
|
|
Default: `'--enable=style'`
|
|
|
|
|
|
|
|
This variable can be changed to modify flags given to cppcheck.
|
|
|
|
|
|
|
|
|
2017-07-08 13:17:26 +00:00
|
|
|
===============================================================================
|
2017-05-10 17:41:58 +00:00
|
|
|
cpplint *ale-cpp-cpplint*
|
|
|
|
|
|
|
|
g:ale_cpp_cpplint_options *g:ale_cpp_cpplint_options*
|
|
|
|
*b:ale_cpp_cpplint_options*
|
|
|
|
Type: |String|
|
|
|
|
Default: `''`
|
|
|
|
|
|
|
|
This variable can be changed to modify flags given to cpplint.
|
|
|
|
|
|
|
|
|
2017-07-08 13:17:26 +00:00
|
|
|
===============================================================================
|
2017-03-28 22:25:44 +00:00
|
|
|
gcc *ale-cpp-gcc*
|
|
|
|
|
|
|
|
g:ale_cpp_gcc_options *g:ale_cpp_gcc_options*
|
2017-04-27 21:04:34 +00:00
|
|
|
*b:ale_cpp_gcc_options*
|
2017-03-28 22:25:44 +00:00
|
|
|
Type: |String|
|
|
|
|
Default: `'-std=c++14 -Wall'`
|
|
|
|
|
|
|
|
This variable can be changed to modify flags given to gcc.
|
|
|
|
|
|
|
|
|
2017-07-08 13:17:26 +00:00
|
|
|
===============================================================================
|
2017-03-28 22:25:44 +00:00
|
|
|
vim:tw=78:ts=2:sts=2:sw=2:ft=help:norl:
|