Sha256: e4dfeacbe1262399d7162574b9a9eea02c1722fbd925601a7d5b05c5b38bd309

Contents?: true

Size: 696 Bytes

Versions: 25

Compression:

Stored size: 696 Bytes

Contents

#!/usr/bin/env ruby
$:.unshift(File.expand_path("../../lib", __FILE__))
require 'rubygems'
require 'rdf'

options = RDF::CLI.options(ARGV)

abort options.banner if ARGV.empty? && !options.options[:evaluate]

# Add option_parser to parsed options to enable help
begin
  messages = {}
  RDF::CLI.exec(options.args, option_parser: options, **options.options.merge(messages: messages))

  unless messages.empty?
    $stdout.puts "Messages:"
    messages.each do |kind, term_messages|
      term_messages.each do |term, messages|
        $stdout.puts "#{kind}  #{term}"
        messages.each {|m| $stdout.puts "  #{m}"}
      end
    end
  end
rescue ArgumentError => e
  RDF::CLI.abort e.message
end

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
rdf-3.2.12 bin/rdf
rdf-3.3.2 bin/rdf
rdf-3.3.1 bin/rdf
rdf-3.3.0 bin/rdf
rdf-3.2.11 bin/rdf
rdf-3.2.10 bin/rdf
rdf-3.2.9 bin/rdf
rdf-3.2.8 bin/rdf
rdf-3.2.7 bin/rdf
rdf-3.2.6 bin/rdf
rdf-3.2.5 bin/rdf
rdf-3.2.4 bin/rdf
rdf-3.2.3 bin/rdf
rdf-3.2.2 bin/rdf
rdf-3.2.1 bin/rdf
rdf-3.1.15 bin/rdf
rdf-3.1.13 bin/rdf
rdf-3.1.12 bin/rdf
rdf-3.1.11 bin/rdf
rdf-3.1.10 bin/rdf