Module: Headdesk::CliCommand

Overview

Helper for CLI command modules

Class Method Summary collapse

Class Method Details

.each(&block) ⇒ Object



32
33
34
# File 'lib/headdesk.rb', line 32

def self.each(&block)
  @commands.each(&block)
end

.included(cmd) ⇒ Object



36
37
38
39
# File 'lib/headdesk.rb', line 36

def self.included(cmd)
  @commands ||= []
  @commands << cmd
end