Sha256: 274137108d2ace3ee5c84c782351f2ff5e5a3443cd6152c3d11e20fc5a55c18e

Contents?: true

Size: 639 Bytes

Versions: 6

Compression:

Stored size: 639 Bytes

Contents

require 'guard'
require 'guard/guard'

module Guard
  class MarvTemplates < ::Guard::Guard
    def initialize(watchers=[], options={})
      super
    end

    def start
      UI.info "Copying templates over"
      ::Marv::Guard.builder.copy_templates
    end

    def run_all
      UI.info "Rebuilding all templates"
      ::Marv::Guard.builder.clean_templates
      ::Marv::Guard.builder.copy_templates
    end

    # Called on file(s) modifications
    def run_on_change(paths)
      UI.info "Templates have changed, copying over"
      ::Marv::Guard.builder.clean_templates
      ::Marv::Guard.builder.copy_templates
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
marv-0.2.5 lib/guard/marv/templates.rb
marv-0.2.4 lib/guard/marv/templates.rb
marv-0.2.3 lib/guard/marv/templates.rb
marv-0.2.2 lib/guard/marv/templates.rb
marv-0.2.1 lib/guard/marv/templates.rb
marv-0.2.0 lib/guard/marv/templates.rb