Sha256: 7e9426ada593292a72d3d9a7af0b072689547f0ebe581a6e8db043c851f24376

Contents?: true

Size: 689 Bytes

Versions: 26

Compression:

Stored size: 689 Bytes

Contents

#!/usr/bin/env ruby

lib = File.expand_path('../../lib', __FILE__)
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)

require "inquisitio"

# Index a spdf file in AWS CloudSearch
#
# example usage:
#
# ruby ./bin/index <document_endpoint> "id" "version" "field_name" "field_value"

endpoint = ARGV[0]
id = ARGV[1]

version = Time.now.to_i

Inquisitio.config do |config|
  config.document_endpoint = endpoint
end

fields = { :title => 'The Title',
           :author => 'The Author' }
document = Inquisitio::Document.new("add",
                                    id,
                                    version,
                                    fields)
Inquisitio.index(document)

Version data entries

26 entries across 26 versions & 1 rubygems

Version Path
inquisitio-1.5.0 bin/index
inquisitio-1.4.1 bin/index
inquisitio-1.4.0 bin/index
inquisitio-1.3.1 bin/index
inquisitio-1.3.0 bin/index
inquisitio-1.2.4 bin/index
inquisitio-1.2.3 bin/index
inquisitio-1.2.2 bin/index
inquisitio-1.2.1 bin/index
inquisitio-1.2.0 bin/index
inquisitio-1.1.2 bin/index
inquisitio-1.1.1 bin/index
inquisitio-1.1.0 bin/index
inquisitio-1.0.0 bin/index
inquisitio-0.2.0 bin/index
inquisitio-0.1.7 bin/index
inquisitio-0.1.6 bin/index
inquisitio-0.1.5 bin/index
inquisitio-0.1.4 bin/index
inquisitio-0.1.3 bin/index