Class: Middleman::BuildReporterExtension
- Inherits:
-
Extension
- Object
- Extension
- Middleman::BuildReporterExtension
- Defined in:
- lib/middleman-build-reporter/extension.rb
Instance Method Summary collapse
- #after_build(builder) ⇒ Object
-
#initialize(app, options_hash = {}, &block) ⇒ BuildReporterExtension
constructor
A new instance of BuildReporterExtension.
Constructor Details
#initialize(app, options_hash = {}, &block) ⇒ BuildReporterExtension
Returns a new instance of BuildReporterExtension.
8 9 10 11 12 13 |
# File 'lib/middleman-build-reporter/extension.rb', line 8 def initialize(app, = {}, &block) super @app = app @app.set :build_report, Middleman::BuildReporter::Reporter.new(@app, ) end |
Instance Method Details
#after_build(builder) ⇒ Object
15 16 17 18 19 |
# File 'lib/middleman-build-reporter/extension.rb', line 15 def after_build(builder) @app.build_report.write do |file| builder.say_status :create, file, :green end end |