Skip to content

Setup LOAD_PATH from require_paths#648

Open
mkon wants to merge 1 commit intocastwide:masterfrom
mkon:load-paths
Open

Setup LOAD_PATH from require_paths#648
mkon wants to merge 1 commit intocastwide:masterfrom
mkon:load-paths

Conversation

@mkon
Copy link

@mkon mkon commented Apr 11, 2023

Hey everyone, thanks for this nice gem, I am trying to incorporate it into more parts of my ruby development.

Sometimes I am using a setup where I do not want to add solargraph to the Gemfile, so I can not start it via bundle exec. However I still want a diagnoser like rubocop to be able to require files of local gems, for example custom cops provided by a local gem (with a path pointer in the local Gemfile).

Currently rubocop will just crash because it can not load those files for custom cop definitions, but with some simple change we can expose the configuration of require_files to rubocop by updating LOAD_PATH. In many cases require_files already has a working default and there is no additional configuration required.

WDYT? @castwide

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant