How to install bundler for Ruby < 2.3

Bundler 2 requires at least Ruby 2.3.0 and RubyGems 2.5.0. You might get the following error when you try to install bundler for Ruby < 2.3:

ERROR:  Error installing bundler:
	bundler requires Ruby version >= 2.3.0.

To fix this error upgrade your project's ruby version or install the last supported version of Bundler for Ruby < 2.3:

gem install bundler -v '~>1'

You will also see an error if your RubyGems version is < 2.5.0.

Emanuel About 5 years ago