Class: Bgem::Config::DSL
- Inherits:
-
Object
- Object
- Bgem::Config::DSL
- Defined in:
- lib/bgem.rb
Instance Method Summary collapse
- #entry(file) ⇒ Object
-
#initialize(config, code) ⇒ DSL
constructor
A new instance of DSL.
- #inside(*headers) ⇒ Object
- #output(file) ⇒ Object
Constructor Details
#initialize(config, code) ⇒ DSL
Returns a new instance of DSL.
27 28 29 30 |
# File 'lib/bgem.rb', line 27 def initialize config, code @config = config instance_eval code end |
Instance Method Details
#entry(file) ⇒ Object
32 33 34 |
# File 'lib/bgem.rb', line 32 def entry file @config.entry = file end |
#inside(*headers) ⇒ Object
40 41 42 |
# File 'lib/bgem.rb', line 40 def inside *headers @config.scope = headers end |
#output(file) ⇒ Object
36 37 38 |
# File 'lib/bgem.rb', line 36 def output file @config.output = file end |