Sha256: b6ea87f89df530a924f4591322e65f613d5cb1e680626c98199b4d6e57efca25

Contents?: true

Size: 595 Bytes

Versions: 84

Compression:

Stored size: 595 Bytes

Contents

require "terraspace-bundler"

class Terraspace::CLI
  class Bundle
    def initialize(options={})
      @options = options
    end

    def run
      TerraspaceBundler.config.deep_merge!(Terraspace.config.bundle)
      TerraspaceBundler::CLI.start(args)
    end

    # Allows bundle to be called without install. So both work:
    #
    #    terraspace bundle
    #    terraspace bundle install
    #
    def args
      args = @options[:args]
      if args.empty? or args.first.include?('--')
        args.unshift("install")
      end
      args = ["bundle"] + args
      args
    end
  end
end

Version data entries

84 entries across 84 versions & 1 rubygems

Version Path
terraspace-2.2.17 lib/terraspace/cli/bundle.rb
terraspace-2.2.16 lib/terraspace/cli/bundle.rb
terraspace-2.2.15 lib/terraspace/cli/bundle.rb
terraspace-2.2.14 lib/terraspace/cli/bundle.rb
terraspace-2.2.13 lib/terraspace/cli/bundle.rb
terraspace-2.2.12 lib/terraspace/cli/bundle.rb
terraspace-2.2.11 lib/terraspace/cli/bundle.rb
terraspace-2.2.10 lib/terraspace/cli/bundle.rb
terraspace-2.2.9 lib/terraspace/cli/bundle.rb
terraspace-2.2.8 lib/terraspace/cli/bundle.rb
terraspace-2.2.7 lib/terraspace/cli/bundle.rb
terraspace-2.2.6 lib/terraspace/cli/bundle.rb
terraspace-2.2.5 lib/terraspace/cli/bundle.rb
terraspace-2.2.4 lib/terraspace/cli/bundle.rb
terraspace-2.2.3 lib/terraspace/cli/bundle.rb
terraspace-2.2.2 lib/terraspace/cli/bundle.rb
terraspace-2.2.1 lib/terraspace/cli/bundle.rb
terraspace-2.2.0 lib/terraspace/cli/bundle.rb
terraspace-2.1.7 lib/terraspace/cli/bundle.rb
terraspace-2.1.6 lib/terraspace/cli/bundle.rb