fuzzy_ruby_server
fuzzy_ruby_server copied to clipboard
Installation question w/ neovim/coc.nvim
I apologize for this question but do I need to clone this repo and get the binaries in my bin PATH to use it? Did you publish the binary to a registry?
For an example of how I would configure this, it would be similar to Sublime Text LSP that ruby-lsp
has in their docs. The coc.nvim docs are here but I don't mean for you to have to dig around in them.
Also, I am not super knowledgeable about rust but there is an existing crate named fuzzy that threw me off because I see your package has the same name in your cargo.toml file
same question here, as neovim user with no knowledge of rust isn't clear to me how to get the fuzzy
command available to neovim.
would awesome if I could do cargo install fuzzy_ruby_server
I think what I did was just to clone the repo and cp bin/fuzzy_<your_architecture> <somewhere_in_your_PATH>/fuzzy
.
If you want to build it yourself, I'm guessing you can just run cargo build --release
and then cp target/release/fuzzy <some PATH>/fuzzy
Thanks @iovis this worked for me:
curl -o ~/bin/fuzzy -L https://github.com/pheen/fuzzy_ruby_server/raw/master/bin/fuzzy_darwin-arm64
chmod +x ~/bin/fuzzy
Although I would like to have an easy way to ask neovim to update all the installed lsp-servers
One thought is you could rig up something like the following, I am still using vim-plug so my example would run anytime the plugins update:
Plug 'pheen/fuzzy_ruby_server', { 'do': 'sh ~/.config/utils/move_binary_and_chmod.sh' }
Alright, so shoving this in my coc-settings.json
seems to do the trick for me. I did the curl
method mentioned above to shove it in my PATH. 👍
{
...
"languageserver": {
"fuzzyRubyServer": {
"command": "fuzzy",
"initializationOptions": {
"allocationType": "ram",
"indexGems": true,
"reportDiagnostics": true
},
"filetypes": ["ruby"]
},
}
...
}
Yup cargo build --release
is the way if you need to build the binary yourself. Also see https://github.com/pheen/fuzzy_ruby_server#publishing which shows how to build for other platforms. Sorry I'm not planning on working on this project anymore for the foreseeable future.