Class: Ufo::TaskDefinition::Erb::Base
- Defined in:
- lib/ufo/task_definition/erb/base.rb
Instance Attribute Summary
Attributes inherited from CLI::Base
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Base
constructor
A new instance of Base.
- #print_code(text) ⇒ Object
Methods included from Utils::Sure
Methods included from Utils::Pretty
#pretty_home, #pretty_path, #pretty_time
Methods included from Utils::Logging
Methods included from Concerns
Methods included from Concerns::Names
Methods included from AwsServices
#acm, #applicationautoscaling, #aws_options, #cfn, #cloudwatchlogs, #ec2, #ecr, #ecs, #elb, #s3, #ssm_client, #waf_client
Methods included from AwsServices::Concerns
#find_stack, #find_stack_resources, #stack_resources, #status, #task_definition_arns
Constructor Details
#initialize(options = {}) ⇒ Base
Returns a new instance of Base.
3 4 5 6 7 |
# File 'lib/ufo/task_definition/erb/base.rb', line 3 def initialize(={}) super @path = [:path] @task_definition = [:task_definition] end |
Instance Method Details
#print_code(text) ⇒ Object
9 10 11 12 13 14 15 16 |
# File 'lib/ufo/task_definition/erb/base.rb', line 9 def print_code(text) lines = text.split("\n") lpad = lines.size.to_s.size lines.each_with_index do |line,n| printf("%#{lpad}d %s\n", n+1, line) end nil end |