Sha256: 5aaf9757afb7cf73548f3f4f3238bf779666dc3b7ae7ec70eda30055b5b5e487

Contents?: true

Size: 701 Bytes

Versions: 25

Compression:

Stored size: 701 Bytes

Contents

module ThreeScaleToolbox
  module Commands
    module RemoteCommand
      class RemoteRemoveSubcommand < Cri::CommandRunner
        include ThreeScaleToolbox::Command

        def self.command
          Cri::Command.define do
            name        'remove'
            usage       'remove <name>'
            summary     'remote remove'
            description 'Remove remote from list'
            param       :remote_name
            runner RemoteRemoveSubcommand
          end
        end

        def run
          remotes.delete(arguments[:remote_name]) do |el|
            raise ThreeScaleToolbox::Error, "could not remove remote '#{el}'"
          end
        end
      end
    end
  end
end

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
3scale_toolbox-1.0.1 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-1.0.0 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.20.0 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.19.3 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.19.2 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.19.1 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.19.0 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.18.3 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.18.2 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.18.0 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.17.1 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.17.0 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.16.0 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.15.0 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.14.0 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.13.0 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.12.4 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.12.3 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.12.2 lib/3scale_toolbox/commands/remote_command/remote_remove.rb
3scale_toolbox-0.11.0 lib/3scale_toolbox/commands/remote_command/remote_remove.rb