Sha256: 2412436e545eb92298fa9e0bf0cb7f31e0942bc14f9daa68238d9ab21396faf6

Contents?: true

Size: 666 Bytes

Versions: 19

Compression:

Stored size: 666 Bytes

Contents

# -*- coding: utf-8 -*-
Gemirro::CLI.options.command 'index' do
  banner 'Usage: gemirro index [OPTIONS]'
  description 'Retrieve specs list from source.'
  separator "\nOptions:\n"

  on :c=, :config=, 'Path to the configuration file'

  run do |opts, _args|
    Gemirro::CLI.load_configuration(opts[:c])
    config = Gemirro.configuration

    unless File.directory?(config.destination)
      config.logger.error("The directory #{config.destination} does not exist")
      abort
    end

    indexer    = Gemirro::Indexer.new(config.destination)
    indexer.ui = Gem::SilentUI.new

    config.logger.info('Generating indexes')
    indexer.generate_index
  end
end

Version data entries

19 entries across 19 versions & 1 rubygems

Version Path
gemirro-0.10.5 lib/gemirro/cli/index.rb
gemirro-0.10.4 lib/gemirro/cli/index.rb
gemirro-0.10.3 lib/gemirro/cli/index.rb
gemirro-0.10.2 lib/gemirro/cli/index.rb
gemirro-0.10.1 lib/gemirro/cli/index.rb
gemirro-0.10.0 lib/gemirro/cli/index.rb
gemirro-0.9.1 lib/gemirro/cli/index.rb
gemirro-0.9.0 lib/gemirro/cli/index.rb
gemirro-0.8.1 lib/gemirro/cli/index.rb
gemirro-0.8.0 lib/gemirro/cli/index.rb
gemirro-0.7.0 lib/gemirro/cli/index.rb
gemirro-0.6.0 lib/gemirro/cli/index.rb
gemirro-0.5.0 lib/gemirro/cli/index.rb
gemirro-0.4.0 lib/gemirro/cli/index.rb
gemirro-0.3.0 lib/gemirro/cli/index.rb
gemirro-0.2.0 lib/gemirro/cli/index.rb
gemirro-0.1.0 lib/gemirro/cli/index.rb
gemirro-0.0.2 lib/gemirro/cli/index.rb
gemirro-0.0.1 lib/gemirro/cli/index.rb