Class: Strata::CLI::Generators::Relation
- Defined in:
- lib/strata/cli/generators/relation.rb
Overview
Generates a relationship definition YAML file from template.
Instance Method Summary collapse
Methods inherited from Group
Instance Method Details
#create_relation_file ⇒ Object
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 |
# File 'lib/strata/cli/generators/relation.rb', line 16 def create_relation_file output_path = resolve_output_path # Ensure directory exists empty_directory File.dirname(output_path) # Load template and update with datasource template_content = load_template updated_content = update_template(template_content) # Write the updated template create_file output_path, updated_content say_status :created, output_path, :green end |