Sha256: 51f60c3efa7f922d9a7ca15b904353d16260142f3251278840f606211b784646

Contents?: true

Size: 1.05 KB

Versions: 1

Compression:

Stored size: 1.05 KB

Contents

require 'rake'
require 'rake/clean'

CLOBBER.include('docs/guides')

namespace :hayde do
  desc "Generates guides documentation."
  task :build, [:output_dir, :assets_dir] do |t, args|
	  guides_generator = Hayde::Generator.new do |g|
	    g.sources.include 'guides/source/**/*'
	    g.sources.exclude 'guides/source/layout.*'
	    g.output_dir = args.output_dir if args.output_dir
	    g.assets_dir = args.assets_dir if args.assets_dir
	  end
	  guides_generator.generate
  end

  desc "Generates guides documentation (force rebuild)."
  task :rebuild, [:output_dir, :assets_dir] do |t, args|
	  guides_generator = Hayde::Generator.new do |g|
	    g.sources.include 'guides/source/**/*'
	    g.sources.exclude 'guides/source/layout.*'
	    g.output_dir = args.output_dir if args.output_dir
	    g.assets_dir = args.assets_dir if args.assets_dir
	    g.force = true
	  end
	  guides_generator.generate
  end

  desc "Removes generated guides."
  task :clean do
	  guides_generator = Hayde::Generator.new
	  guides_generator.clean
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
hayde-0.1.10 lib/tasks/haydetasks.rb