Sha256: 905c19099d3f1eab3f1e685c037388a1252ac126318d6045f19cdd30ae68da09

Contents?: true

Size: 732 Bytes

Versions: 17

Compression:

Stored size: 732 Bytes

Contents

# frozen_string_literal: true

class ThinkingSphinx::RakeInterface
  DEFAULT_OPTIONS = {:verbose => true}

  def initialize(options = {})
    @options           = DEFAULT_OPTIONS.merge options
    @options[:verbose] = false if @options[:silent]
  end

  def configure
    ThinkingSphinx::Commander.call :configure, configuration, options
  end

  def daemon
    @daemon ||= ThinkingSphinx::Interfaces::Daemon.new configuration, options
  end

  def rt
    @rt ||= ThinkingSphinx::Interfaces::RealTime.new configuration, options
  end

  def sql
    @sql ||= ThinkingSphinx::Interfaces::SQL.new configuration, options
  end

  private

  attr_reader :options

  def configuration
    ThinkingSphinx::Configuration.instance
  end
end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
thinking-sphinx-5.6.0 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-5.5.1 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-5.5.0 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-5.4.0 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-5.3.0 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-5.2.1 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-5.2.0 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-5.1.0 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-5.0.0 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-4.4.1 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-4.4.0 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-4.3.2 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-4.3.1 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-4.3.0 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-4.2.0 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-4.1.0 lib/thinking_sphinx/rake_interface.rb
thinking-sphinx-4.0.0 lib/thinking_sphinx/rake_interface.rb