Sha256: 80ff453c511ae62633d07c75ddb74e32a9f1779ce0f27ffc3230e10812ab8ca3

Contents?: true

Size: 433 Bytes

Versions: 14

Compression:

Stored size: 433 Bytes

Contents

require_relative 'common'

module Kontena::Cli::Grids
  class CurrentCommand < Clamp::Command
    include Kontena::Cli::Common
    include Common

    def execute
      require_api_url
      if current_grid.nil?
        abort 'No grid selected. To select grid, please run: kontena grid use <grid name>'
      else
        grid = client(require_token).get("grids/#{current_grid}")
        print_grid(grid)
      end
    end
  end
end

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
kontena-cli-0.10.3 lib/kontena/cli/grids/current_command.rb
kontena-cli-0.10.2 lib/kontena/cli/grids/current_command.rb
kontena-cli-0.10.1 lib/kontena/cli/grids/current_command.rb
kontena-cli-0.10.0 lib/kontena/cli/grids/current_command.rb
kontena-cli-0.9.3 lib/kontena/cli/grids/current_command.rb
kontena-cli-0.9.2 lib/kontena/cli/grids/current_command.rb
kontena-cli-0.9.1 lib/kontena/cli/grids/current_command.rb
kontena-cli-0.9.0 lib/kontena/cli/grids/current_command.rb
kontena-cli-0.8.4 lib/kontena/cli/grids/current_command.rb
kontena-cli-0.8.3 lib/kontena/cli/grids/current_command.rb
kontena-cli-0.8.2 lib/kontena/cli/grids/current_command.rb
kontena-cli-0.8.1 lib/kontena/cli/grids/current_command.rb
kontena-cli-0.8.0.1 lib/kontena/cli/grids/current_command.rb
kontena-cli-0.8.0 lib/kontena/cli/grids/current_command.rb