Class: Textus::CLI::Verb::RuleLint
- Inherits:
-
Textus::CLI::Verb
- Object
- Textus::CLI::Verb
- Textus::CLI::Verb::RuleLint
- Defined in:
- lib/textus/cli/verb/rule_lint.rb
Instance Attribute Summary
Attributes inherited from Textus::CLI::Verb
Instance Method Summary collapse
Methods inherited from Textus::CLI::Verb
command_name, #context_for, descendants, #emit, inherited, #initialize, needs_store?, option, options, parent_group, #parse, #resolved_role, #session_for
Constructor Details
This class inherits a constructor from Textus::CLI::Verb
Instance Method Details
#call(store) ⇒ Object
10 11 12 13 14 |
# File 'lib/textus/cli/verb/rule_lint.rb', line 10 def call(store) path = against or raise UsageError.new("rule lint --against=FILE required") yaml = File.read(path) emit(session_for(store).rule_lint(candidate_yaml: yaml).to_h) end |