Skip to content
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

[Bundler] ::Bundler.default_gemfile finds the wrong Gemfile #24

Closed
jonabc opened this issue Apr 4, 2018 · 0 comments
Closed

[Bundler] ::Bundler.default_gemfile finds the wrong Gemfile #24

jonabc opened this issue Apr 4, 2018 · 0 comments
Labels
bug Something isn't working

Comments

@jonabc
Copy link
Contributor

jonabc commented Apr 4, 2018

::Bundler.default_gemfile.basename is used in the bundler source when looking for a Gemfile in the applications source path.

The issue is that when licensed is run via bundle exec, Bundler sets the ENV["BUNDLE_GEMFILE"] variable which is given preference over searching for a Gemfile from the file system.

This fails when

  • the application source path where dependencies are enumerated has a gems.rb file
  • bundle exec runs licensed based on a Gemfile in a different location

In this scenario Bundler#gemfile_path will return $pwd/Gemfile which doesn't exist, rather than $pwd/gems.rb which does.

This seems like a low priority edge case, but might be fixable in combination with #23?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant