# Pastebin 6yVYCA82 require 'bundler' module RefineBundlerDefinition refine Bundler::Definition do def specs @specs ||= begin specs = resolve.materialize( Bundler.settings[:cache_all_platforms] ? dependencies : requested_dependencies, [] ) unless specs["bundler"].any? local = Bundler.settings[:frozen] ? rubygems_index : index bundler = local.search(Gem::Dependency.new("bundler", VERSION)).last specs["bundler"] = bundler if bundler end specs end end end end using RefineBundlerDefinition Bundler.setup(:default) require 'rack'