Sha256: d59e9d5ad34bd1a0dd20a2ebe9e13cbf7ac6c06a54dc53e63914688002944706

Contents?: true

Size: 684 Bytes

Versions: 31

Compression:

Stored size: 684 Bytes

Contents

require 'vagrant/util/template_renderer'

module VagrantPlugins
  module Parallels
    module Action
      class PackageConfigFiles
        # For TemplateRenderer
        include Vagrant::Util

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

        def call(env)
          @env = env
          create_metadata
          @app.call(env)
        end

        def create_metadata
          File.open(File.join(@env['export.temp_dir'], 'metadata.json'), 'w') do |f|
            f.write(template_metadatafile)
          end
        end

        private

        def template_metadatafile
          %Q({"provider": "parallels"}\n)
        end
      end
    end
  end
end

Version data entries

31 entries across 31 versions & 1 rubygems

Version Path
vagrant-parallels-2.4.2 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-2.4.1 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-2.4.0 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-2.3.1 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-2.3.0 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-2.2.6 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-2.2.5 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-2.2.4 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-2.2.3 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-2.2.2 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-2.2.1 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-2.2.0 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-2.1.0 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-2.0.1 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-2.0.0 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-1.7.8 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-1.7.7 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-1.7.6 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-1.7.5 lib/vagrant-parallels/action/package_config_files.rb
vagrant-parallels-1.7.4 lib/vagrant-parallels/action/package_config_files.rb