class Devpad::CLI::Commands::Account::List
Public Class Methods
new(shell:)
click to toggle source
# File lib/devpad/cli/commands/account/list.rb, line 6 def initialize(shell:) @shell = shell end
Public Instance Methods
execute()
click to toggle source
# File lib/devpad/cli/commands/account/list.rb, line 10 def execute rows = Devpad::API::Account.all.each_with_index.map do |account, index| [index + 1, account.name, account.subdomain] end @shell.print_table rows end