Sha256: 8d8109b637ce058f8f7589ff8cad08c1390caeeaf52dd030b1ede16c19e0d920

Contents?: true

Size: 470 Bytes

Versions: 1

Compression:

Stored size: 470 Bytes

Contents

#!/usr/bin/env ruby
# frozen_string_literal: true
$LOAD_PATH.unshift File.join(File.dirname(__FILE__), '..', 'lib')
require 'kktix_api'

keyword = ARGV[0]
unless keyword
  puts 'USAGE: kktix [keyword]'
  exit(1)
end

puts "Search for #{keyword}..."
events = KktixEvent::Event.search(keyword)

events.first(10).each.with_index(1) do |event, index|
  print "#{index}: "
  puts "#{event.title} (#{event.author[:name]})"
  puts event.summary
  puts event.content
  puts
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
kktix_api-1.0.0 bin/kktix