0

I received the following error from the berks command when trying to init a new cookbook to use Berkshelf version 3

Could not find proper version of berkshelf (2.0.17) in any of the sources
Run `bundle install` to install missing gems.

I do not want to run "bundle install" as it recommends since the whole point was to use Berkshelf v3. How can I get this cookbook to accept Berkshelf v3?

1 Answer 1

0

It turns out I had to do the following to fix the issue; adjust the Gemfile to use berkshelf v3 e.g.,

gem 'berkshelf', '~> 3'

then, remove the old Gemfile.lock and run

bundle install
berks init

taking care not to overwrite any site specific files (such as kitchen tests).

1
  • If the Gemfile didn't have the version constraint before, this may have come as a constraint from a Gemfile.lock, which may be pulled in from a previous run of bundler, or checked into SCM by someone else. Oct 3, 2014 at 13:38

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .