AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |
Back to Blog
Visual studio code install rubocop3/26/2023 ![]() ![]() ![]() Other Clientsįor editors other than VS Code or Atom, please refer to the software or extension’s own documentation. The Atom extension uses the same techniques as the VS Code extension to integrate with rvm/rbenv, so the same suggestions are mostly applicable. See the vscode-solargraph or atom-solargraph documentation for more information. If your editor still can’t find the solargraph executable, you can try referencing it by its absolute path in the mandPath setting. See Visual Studio Code on MacOS for more information. The suggestions for Linux should also work on MacOS, with one exception: you need to add the code command to your PATH in order to run it from the command line. Only bash and zsh shells are offically supported. If that works as expected, there might be a problem with how your shell is integrated with rvm/rbenv. (note the dot at the end of the command). If the Ruby and Solargraph versions are correct but Solargraph still doesn’t work in the editor, try opening it from the command-line, e.g., run code. LinuxĬonfirm that your environment is configured correctly from the command-line. In VS Code, Solargraph makes an attempt to detect the correct version of Ruby to run based on your workspace environment. I’m using rbenv or rvm, and when I open a project in my editor, Solargraph runs a different version of Ruby than I expected. ![]() Solargraph Uses the Wrong Version of Ruby In VS Code, you can do this by setting the eBundler preference to true. Use bundle exec to start the language server.Add solargraph to your Gemfile and bundle install.You need to use Bundler to document cached/vendored gems and make them available to the language server: I have a project that keeps a local directory of cached or vendored gems, and I don’t get any intellisense for them in my IDE. No Intellisense for Cached or Vendored Gems You can generate the documentation by running yard gems on the command line. The most common reason for a gem to be missing from your intellisense is missing YARD documentation. I have a gem installed on my system and required in my code, but I don’t get any intellisense for it in my IDE (no autocomplete, documentation, etc.). The following FAQ provides solutions to common issues running and using Solargraph. ![]()
0 Comments
Read More
Leave a Reply. |