Sha256: 057646469311168ce56a54b8cf138eacafbaffedb73a89dc58f755571192f79c

Contents?: true

Size: 1.2 KB

Versions: 21

Compression:

Stored size: 1.2 KB

Contents

class SdocAllGenerator < RubiGen::Base
  DEFAULT_SHEBANG = File.join(Config::CONFIG['bindir'],
                              Config::CONFIG['ruby_install_name'])

  def initialize(runtime_args, runtime_options = {})
    super
    usage if args.empty?
    @destination_root = File.expand_path(args.shift)
    @name = base_name
    extract_options
  end

  def manifest
    record do |m|
      m.directory ''
      BASEDIRS.each { |path| m.directory path }

      m.file_copy_each %w(Rakefile)
      m.file_copy_each %w(config.yml)
    end
  end

  protected
    def banner
      <<-EOS
Creates an app for all ruby related documentation
edit sdoc.config.yml.erb if you need
run rake tasks
wait until finished (it takes some time)
all your documentation is in public folder

note:
content of docs and sources folders can be destroyed during rebuild
public folder is destroyed and recreated every build!

USAGE: #{File.basename($0)} name
EOS
    end

    def add_options!(opts)
      opts.separator ''
      opts.separator 'Options:'

      opts.on("-v", "--version", "Show the #{File.basename($0)} version number and quit.")
    end

    def extract_options
    end

    BASEDIRS = %w(
      docs
      public
      sources
    )
end

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
sdoc_all-1.3.3 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-1.3.2 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-1.3.1 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-1.0.7 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-1.0.6 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-1.0.5 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-1.0.4 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-1.0.2.2 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-1.0.2.1 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-1.0.2 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-1.0.0 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-1.0.0.1 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-1.0.1 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-0.2.0.8 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-0.2.0.9 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-0.2.0.10 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-0.2.0.11 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-0.2.1.0 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-0.2.0.6 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb
sdoc_all-0.2.0.1 lib/sdoc_all/generator/sdoc_all/sdoc_all_generator.rb