Class: Nit::Config
- Inherits:
-
Thor::Group
- Object
- Thor::Group
- Nit::Config
- Includes:
- Thor::Actions
- Defined in:
- lib/nit/config.rb
Overview
we have to derive from Group to get the create_file working - that’s messy.
Defined Under Namespace
Classes: File
Instance Method Summary collapse
- #ignored_files ⇒ Object
- #ignored_files=(files) ⇒ Object
- #index_renderer ⇒ Object
- #index_renderer=(value) ⇒ Object
- #indexer ⇒ Object
- #indexer=(value) ⇒ Object
-
#initialize ⇒ Config
constructor
A new instance of Config.
Constructor Details
Instance Method Details
#ignored_files ⇒ Object
48 49 50 |
# File 'lib/nit/config.rb', line 48 def ignored_files file.read("ignored_files") or [] end |
#ignored_files=(files) ⇒ Object
52 53 54 |
# File 'lib/nit/config.rb', line 52 def ignored_files=(files) file.write("ignored_files", files.collect(&:to_s)) end |
#index_renderer ⇒ Object
65 66 67 68 |
# File 'lib/nit/config.rb', line 65 def index_renderer const = file.read("index_renderer") || "AppendIndexRenderer" Nit::Command::Status.const_get(const) end |
#index_renderer=(value) ⇒ Object
70 71 72 |
# File 'lib/nit/config.rb', line 70 def index_renderer=(value) file.write("index_renderer", value) end |
#indexer ⇒ Object
56 57 58 59 |
# File 'lib/nit/config.rb', line 56 def indexer const = file.read("indexer") || "CharIndexer" Nit::Files.const_get(const) end |
#indexer=(value) ⇒ Object
61 62 63 |
# File 'lib/nit/config.rb', line 61 def indexer=(value) file.write("indexer", value) end |