Sha256: 98529cf9696915fda98f3fc7e2795ae4ccf09c5906afd2e19e83627b5cdcb7ec
Contents?: true
Size: 1.21 KB
Versions: 50
Compression:
Stored size: 1.21 KB
Contents
module Flydata module Command class Conf < Base def run data_entries = retrieve_data_entries copy_conf_tmpl(data_entries) usage(data_entries) end def copy_templates copy_conf_tmpl(retrieve_data_entries) end def help usage(retrieve_data_entries) end private def copy_conf_tmpl(data_entries) data_entries.each { |de| Flydata::Preference::DataEntryPreference.copy_template(de) } end def usage(data_entries) puts "Data Entry Configuration" puts "=" * 64 cnt = 0 data_entries.each do |de| name = "#{de['display_name']}" || de['name'] file = if Flydata::Preference::DataEntryPreference.configurable?(de) cnt += 1 Flydata::Preference::DataEntryPreference.conf_path(de) else "(not supported)" end puts "#{name.ljust(24)} -> #{file}" end puts "=" * 64 puts if cnt < 1 puts "There are no configurable data entries." else puts "Edit above files to change the configuration." end end end end end
Version data entries
50 entries across 50 versions & 1 rubygems