Sha256: 1f7c4e8fab1d82348d2c10869ffe11df7801a6a34cb9b9ead1d7de9906087abc
Contents?: true
Size: 629 Bytes
Versions: 22
Compression:
Stored size: 629 Bytes
Contents
require_relative '../../common' module Kontena::Cli::Master::Users class RemoveCommand < Clamp::Command include Kontena::Cli::Common parameter "EMAIL ...", "List of emails" option "--force", :flag, "Force remove", default: false, attribute_name: :forced def execute require_api_url token = require_token confirm unless forced? email_list.each do |email| begin client(token).delete("users/#{email}") rescue => exc STDERR.puts "Failed to remove user #{email}".colorize(:red) STDERR.puts exc.message end end end end end
Version data entries
22 entries across 22 versions & 1 rubygems