:find
and gf
know how to find files.:make
builds and populates the QuickFix window.Update your login script:
Steps #2 and #3 depend on configuration set by the fx set
command. Add these lines to your startup script (typically ~/.bashrc
).
export FUCHSIA_DIR=/path/to/fuchsia-dir fx set core.x64
Update your vim startup file:
If this line exists in your ~/.vimrc file
, remove it:
filetype plugin indent on
Then add these lines to your ~/.vimrc
.
if $FUCHSIA_DIR != "" source $FUCHSIA_DIR/scripts/vim/fuchsia.vim endif filetype plugin indent on
Install YouCompleteMe (YCM):
Optionally install YouCompleteMe for fancy completion, source navigation and inline errors.
If it's installed, fuchsia.vim
configures YCM properly.
If everything is working properly, you can place the cursor on an identifier in a .cc or .h file then hit Ctrl+], to navigate to the definition of the identifier.
Use fx compdb
to build a compilation database. YCM will use the compilation database which is more reliable and efficient than the default ycm_extra_config.py
configuration.
In the future it would be nice to support: