Class: Agent::Lock::CLI::Commands::ShowRepos

Inherits:
Show
  • Object
show all
Defined in:
lib/agent/lock/cli/commands/show.rb

Overview

alock show repos.

Instance Attribute Summary

Attributes inherited from Base

#launcher

Instance Method Summary collapse

Methods inherited from Show

inherited

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from Agent::Lock::CLI::Commands::Base

Instance Method Details

#call(**options) ⇒ void

This method returns an undefined value.

Parameters:

  • options (Hash) —

    :redis_url



111
112
113
114
115
116
# File 'lib/agent/lock/cli/commands/show.rb', line 111

def call(**options)
  found = index(options)
  rows = found.repos.map { |repo| row(repo) }
  table(rows, header: %w[Namespace Locks Memory], empty: "No locks in Redis.")
  warn_legacy(found.legacy_count)
end