Class: Packwerk::Commands::BaseCommand Abstract
- Inherits:
-
Object
- Object
- Packwerk::Commands::BaseCommand
- Defined in:
- lib/packwerk/commands/base_command.rb
Overview
This class is abstract.
Direct Known Subclasses
CheckCommand, HelpCommand, InitCommand, UpdateTodoCommand, ValidateCommand, VersionCommand
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(args, configuration:, out:, err_out:, progress_formatter:, offenses_formatter:) ⇒ BaseCommand
constructor
A new instance of BaseCommand.
- #run ⇒ Object abstract
Constructor Details
#initialize(args, configuration:, out:, err_out:, progress_formatter:, offenses_formatter:) ⇒ BaseCommand
Returns a new instance of BaseCommand.
29 30 31 32 33 34 35 36 |
# File 'lib/packwerk/commands/base_command.rb', line 29 def initialize(args, configuration:, out:, err_out:, progress_formatter:, offenses_formatter:) @args = args @configuration = configuration @out = out @err_out = err_out @progress_formatter = progress_formatter @offenses_formatter = offenses_formatter end |
Class Method Details
.description(description = nil) ⇒ Object
12 13 14 15 16 17 18 |
# File 'lib/packwerk/commands/base_command.rb', line 12 def description(description = nil) if description @description = description else @description end end |
Instance Method Details
#run ⇒ Object
This method is abstract.
40 |
# File 'lib/packwerk/commands/base_command.rb', line 40 def run = raise NotImplementedError, "Abstract method called" |