-
-
Notifications
You must be signed in to change notification settings - Fork 154
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can I use solargraph in a bundle-managed project without including it in the Gemfile? #152
Comments
Running Solargraph without Bundler shouldn't be a problem as long as Ruby can find the gems that your application requires. You may run into caveats if your application uses a gem cache or your Gemfile specifies a different version of the gem than the one Ruby finds. At the moment, Solargraph can only find gems that are explicitly I'm also working on ways to improve Rails integration in particular. One solution I've found is to use a # @!parse
# require 'actioncable'
# require 'actionmailer'
# require 'actionpack'
# require 'actionview'
# require 'activejob'
# require 'activemodel'
# require 'activerecord'
# require 'activestorage'
# require 'activesupport'
# class ActiveRecord::Base
# extend ActiveRecord::QueryMethods
# extend ActiveRecord::FinderMethods
# extend ActiveRecord::Associations::ClassMethods
# end
nil With proper handling of (Note: the |
The |
I have a Rails project at work that I'd like to try Solargraph on, but I don't want to add it into the Gemfile. Are there any other ways?
Here's my .solargraph.yml:
I have the Rails methods available due to
rails
being in therequire
section, but I'd very much like to avoid requiring every gem in the Gemfile manually...The text was updated successfully, but these errors were encountered: