Method: Aka.count_export
- Defined in:
- lib/aka/helpers.rb
.count_export ⇒ Object
445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 |
# File 'lib/aka/helpers.rb', line 445 def self.count_export export_count = 0 str = is_config_file_present?(readYML("#{CONFIG_PATH}")["dotfile"]) if content=File.open(str).read content_array = product_content_array(content) content_array.each_with_index { |line, index| value = line.split(" ") if value.length > 1 && value.first == "export" answer = value[1].split("=") export_count += 1 end } return export_count end end |