rubygems / bundler

Manage your Ruby application's gem dependencies
https://bundler.io
MIT License
4.88k stars 1.99k forks source link

init_gems_rb setting is ignored in bundle-gem #7626

Closed dunrix closed 4 years ago

dunrix commented 4 years ago

When new project skeleton is generated with bundle gem, it does not heed any of the following options

init_gems_rb == true prefer_gems_rb == true

and creates Gemfile instead of expected gems.rb .

You have to change to projects directory, invoke bundle init which creates gems.rb afterwards, then throws following warning:

Multiple gemfiles (gems.rb and Gemfile) detected. Make sure you remove Gemfile and Gemfile.lock since bundler is ignoring them in favor of gems.rb and gems.rb.locked.

and have to remove Gemfile manually. It should not happen, while skeleton should pick gems.rb directly, in accordance to the preferences.