Class: Paraduct::Configuration
- Inherits:
-
Object
- Object
- Paraduct::Configuration
- Includes:
- Singleton
- Defined in:
- lib/paraduct/configuration.rb
Instance Method Summary collapse
- #config_file ⇒ Pathname
- #exclude ⇒ Object
- #max_threads ⇒ Integer
- #root_dir ⇒ Pathname
- #rsync_option ⇒ Object
- #script ⇒ String+
- #variables ⇒ Pathname
- #work_dir ⇒ Pathname
Instance Method Details
#config_file ⇒ Pathname
38 39 40 |
# File 'lib/paraduct/configuration.rb', line 38 def config_file root_dir.join(".paraduct.yml") end |
#exclude ⇒ Object
27 28 29 |
# File 'lib/paraduct/configuration.rb', line 27 def exclude config_data[:exclude] || [] end |
#max_threads ⇒ Integer
19 20 21 |
# File 'lib/paraduct/configuration.rb', line 19 def max_threads config_data[:max_threads] || 4 end |
#root_dir ⇒ Pathname
43 44 45 |
# File 'lib/paraduct/configuration.rb', line 43 def root_dir Pathname.pwd end |
#rsync_option ⇒ Object
23 24 25 |
# File 'lib/paraduct/configuration.rb', line 23 def rsync_option config_data[:rsync_option] || {} end |
#script ⇒ String+
14 15 16 |
# File 'lib/paraduct/configuration.rb', line 14 def script config_data[:script] end |
#variables ⇒ Pathname
9 10 11 |
# File 'lib/paraduct/configuration.rb', line 9 def variables config_data[:variables] end |
#work_dir ⇒ Pathname
32 33 34 35 |
# File 'lib/paraduct/configuration.rb', line 32 def work_dir _work_dir = config_data[:work_dir] || "tmp/paraduct_workspace" root_dir.join(_work_dir) end |