Sha256: 7422805eea09b96dd2ba8a02ffeb052831051e22ddb5b118bc09f1d35deb2bb3

Contents?: true

Size: 660 Bytes

Versions: 15

Compression:

Stored size: 660 Bytes

Contents

module Guides
  class New < Thor
    include Thor::Actions

    source_root File.expand_path("../templates", __FILE__)

    desc "copy DEST NAME", "copy stuff"
    def copy(destination, name)
      self.destination_root = File.expand_path(destination)
      self.title = name

      directory "source"
      empty_directory "assets/stylesheets"
      empty_directory "assets/images"
      empty_directory "assets/javascripts"

      template "guides.yml.tt", "guides.yml"
      create_file "assets/stylesheets/overrides.style.css"
      create_file "assets/stylesheets/overrides.print.css"
    end

    no_tasks do
      attr_accessor :title
    end
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
guides-0.7.2 lib/guides/new.rb
guides-0.7.1 lib/guides/new.rb
guides-0.7.0 lib/guides/new.rb
guides-0.6.10 lib/guides/new.rb
guides-0.6.9 lib/guides/new.rb
guides-0.6.8.1 lib/guides/new.rb
guides-0.6.8 lib/guides/new.rb
guides-0.6.7 lib/guides/new.rb
guides-0.6.6 lib/guides/new.rb
guides-0.6.5 lib/guides/new.rb
guides-0.6.4 lib/guides/new.rb
guides-0.6.3 lib/guides/new.rb
guides-0.6.2 lib/guides/new.rb
guides-0.6.1 lib/guides/new.rb
guides-0.5.0 lib/guides/new.rb