Sha256: fb7777f341fe7607dc52fb164bedf95ae29c198f827d20cd29c4256078803b09

Contents?: true

Size: 535 Bytes

Versions: 6

Compression:

Stored size: 535 Bytes

Contents

require 'vagrant/version'
require 'rubygems/version'

# Check for deprecated Vagrant versions
class PEBuild::Action::VersionCheck
  MINIMUM_VERSION = '2.0.0'

  def initialize(app, env)
    @app = app
  end

  def call(env)
    unless Gem::Version.new(Vagrant::VERSION) > Gem::Version.new(MINIMUM_VERSION)
      env[:env].ui.warn I18n.t(
        'pebuild.action.version_check.deprecated_vagrant_version',
        minimum_version: MINIMUM_VERSION,
        vagrant_version: Vagrant::VERSION
      )
    end

    @app.call(env)
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
vagrant-pe_build-0.19.2 lib/pe_build/action/version_check.rb
vagrant-pe_build-0.19.1 lib/pe_build/action/version_check.rb
vagrant-pe_build-0.19.0 lib/pe_build/action/version_check.rb
vagrant-pe_build-0.18.2 lib/pe_build/action/version_check.rb
vagrant-pe_build-0.18.1 lib/pe_build/action/version_check.rb
vagrant-pe_build-0.18.0 lib/pe_build/action/version_check.rb