{"id":13411668,"url":"https://github.com/castwide/solargraph","last_synced_at":"2025-05-14T09:06:19.853Z","repository":{"id":38552115,"uuid":"85402340","full_name":"castwide/solargraph","owner":"castwide","description":"A Ruby language server.","archived":false,"fork":false,"pushed_at":"2025-05-06T11:22:10.000Z","size":34041,"stargazers_count":1937,"open_issues_count":132,"forks_count":158,"subscribers_count":32,"default_branch":"master","last_synced_at":"2025-05-07T08:03:59.506Z","etag":null,"topics":["intellisense","language-server","ruby"],"latest_commit_sha":null,"homepage":"https://solargraph.org","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/castwide.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"patreon":"castwide"}},"created_at":"2017-03-18T13:15:12.000Z","updated_at":"2025-05-06T00:45:08.000Z","dependencies_parsed_at":"2022-07-11T19:53:07.087Z","dependency_job_id":"2a6ef8fc-81f9-4bac-9130-a65c38fe857b","html_url":"https://github.com/castwide/solargraph","commit_stats":{"total_commits":3446,"total_committers":74,"mean_commits":"46.567567567567565","dds":0.0281485780615206,"last_synced_commit":"524c94e955938292fb63eee1741a4d95ce86f643"},"previous_names":[],"tags_count":166,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/castwide%2Fsolargraph","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/castwide%2Fsolargraph/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/castwide%2Fsolargraph/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/castwide%2Fsolargraph/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/castwide","download_url":"https://codeload.github.com/castwide/solargraph/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254110373,"owners_count":22016391,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["intellisense","language-server","ruby"],"created_at":"2024-07-30T20:01:15.585Z","updated_at":"2025-05-14T09:06:19.831Z","avatar_url":"https://github.com/castwide.png","language":"Ruby","readme":"# Solargraph\n\n[![RSpec](https://github.com/castwide/solargraph/actions/workflows/rspec.yml/badge.svg)](https://github.com/castwide/solargraph/actions/workflows/rspec.yml)\n\n## A Ruby Language Server\n\nSolargraph provides a comprehensive suite of tools for Ruby programming: intellisense, diagnostics, inline documentation, and type checking.\n\n## Online Demo\n\nA web-based demonstration of Solargraph's autocomplete is available at https://solargraph.org/demo.\n\n## Installation\n\nInstall the gem from the command line:\n\n    gem install solargraph\n\nOr add it to your Gemfile:\n\n    gem 'solargraph', group: :development\n\n## Using Solargraph\n\nPlug-ins and extensions are available for the following editors:\n\n* **Visual Studio Code**\n    * Extension: https://marketplace.visualstudio.com/items?itemName=castwide.solargraph\n    * GitHub: https://github.com/castwide/vscode-solargraph\n\n* **Sublime Text**\n    * Extension: https://packagecontrol.io/packages/LSP\n    * GitHub: https://github.com/sublimelsp/LSP\n    * Instructions: https://lsp.sublimetext.io/language_servers/#solargraph\n\n* **Vim**\n    * Github: `nvim-lspconfig`, https://github.com/neovim/nvim-lspconfig/blob/master/doc/configs.md#solargraph\n    * GitHub: `LanguageClient-neovim`, https://github.com/autozimu/LanguageClient-neovim\n    * GitHub: `coc`, https://github.com/neoclide/coc-solargraph\n    * GitHub: `Vim-EasyComplete`, https://github.com/jayli/vim-easycomplete\n\n* **Emacs**\n    * GitHub: `eglot.el`, https://github.com/joaotavora/eglot\n    * GitHub: `lsp-mode.el`, https://github.com/emacs-lsp/lsp-mode\n\n* **Eclipse**\n    * Plugin: https://marketplace.eclipse.org/content/ruby-solargraph\n    * GitHub: https://github.com/PyvesB/eclipse-solargraph\n\n### Configuration\n\nSolargraph's behavior can be controlled via optional [configuration](https://solargraph.org/guides/configuration) files. The highest priority file is a `.solargraph.yml` file at the root of the project. If not present, any global configuration at `~/.config/solargraph/config.yml` will apply. The path to the global configuration can be overridden with the `SOLARGRAPH_GLOBAL_CONFIG` environment variable.\n\n### Plugins\n\nSolargraph supports [plugins](https://solargraph.org/guides/plugins) that implements their own Solargraph features, such as diagnostics reporters and conventions to provide LSP features and type-checking, e.g. for frameworks which use metaprogramming and/or DSLs.\n\nFor better Rails support, please consider using [solargraph-rails](https://github.com/iftheshoefritz/solargraph-rails/)\n\nThe RSpec framework is supported via [solargraph-rspec](https://github.com/lekemula/solargraph-rspec/)\n\n### Gem Support\n\n**Note: Before version 0.53.0, it was recommended to run `yard gems` periodically or automate it with `yard config` to ensure that Solargraph had access to gem documentation. These steps are no longer necessary. Solargraph maintains its own gem documentation cache independent of the yardocs in your gem installations.**\n\nSolargraph automatically generates code maps from installed gems. You can also manage your cached gem documentation with the `solargraph gems` command.\n\nWhen editing code, a `require` call that references a gem will pull the documentation into the code maps and include the gem's API in code completion and intellisense.\n\nIf your project automatically requires bundled gems (e.g., `require 'bundler/require'`), Solargraph will add all of the Gemfile's default dependencies to the map.\n\n### Type Checking\n\nAs of version 0.33.0, Solargraph includes a [type checker](https://github.com/castwide/solargraph/issues/192) that uses a combination of YARD tags and code analysis to report missing type definitions. In strict mode, it performs type inference to determine whether the tags match the types it detects from code.\n\n### The Documentation Cache\n\nSolargraph uses a cache directory to store documentation for the Ruby core and gems. The default location is `~/.cache/solargraph`, e.g., `/home/\u003cusername\u003e/.cache/solargraph` on Linux or `C:\\Users\\\u003cusername\u003e\\.cache\\solargraph` on Windows.\n\nYou can change the location of the cache directory with the `SOLARGRAPH_CACHE` environment variable.\n\n### Solargraph and Bundler\n\nIf you're using the language server with a project that uses Bundler, the most comprehensive way to use your bundled gems is to bundle Solargraph.\n\nIn the Gemfile:\n\n    gem 'solargraph', group: :development\n\nRun `bundle install` and optionally use `bundle exec solargraph gems` to generate the documentation. This process documents cached or vendored gems, or even gems that are installed from a local path.\n\nIn order to make sure you're using the correct dependencies, you can start the language server with Bundler. In VS Code, there's a `solargraph.useBundler` option. Other clients will vary, but the command you probably want to run is `bundle exec solargraph socket` or `bundle exec solargraph stdio`.\n\n### Rubocop Version\n\nIf you have multiple versions of [`rubocop`](https://rubygems.org/gems/rubocop) installed and you would like to choose a version other than the latest to use, this specific version can be configured.\n\nIn `.solargraph.yml`:\n\n```yaml\n---\nreporters:\n- rubocop:version=0.61.0  # diagnostics\nformatter:\n  rubocop:\n    version: 0.61.0       # formatting\n```\n\n### Integrating Other Editors\n\nThe [language server protocol](https://microsoft.github.io/language-server-protocol/specification) is the recommended way for integrating Solargraph into editors and IDEs. Clients can connect using either stdio or TCP. Language client developers should refer to [https://solargraph.org/guides/language-server](https://solargraph.org/guides/language-server).\n\n### More Information\n\nSee [https://solargraph.org/guides](https://solargraph.org/guides) for more tips and tutorials about Solargraph.\n\n## Contributing to Solargraph\n\n### Bug Reports and Feature Requests\n\n[GitHub Issues](https://github.com/castwide/solargraph/issues) are the best place to ask questions, report problems, and suggest improvements.\n\n### Development\n\nCode contributions are always appreciated. Feel free to fork the repo and submit pull requests. Check for open issues that could use help. Start new issues to discuss changes that have a major impact on the code or require large time commitments.\n\n### Sponsorship and Donation\n\nUse Patreon to support ongoing development of Solargraph at [https://www.patreon.com/castwide](https://www.patreon.com/castwide).\n\nYou can also make one-time donations via PayPal at [https://www.paypal.me/castwide](https://www.paypal.me/castwide).\n","funding_links":["https://patreon.com/castwide","https://www.patreon.com/castwide","https://www.paypal.me/castwide"],"categories":["Ruby","Languages"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcastwide%2Fsolargraph","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcastwide%2Fsolargraph","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcastwide%2Fsolargraph/lists"}