Sha256: 15e293b083942237190aa8b9e8976e57a1b4f883dac4078bd8538854de7fdd14

Contents?: true

Size: 548 Bytes

Versions: 13

Compression:

Stored size: 548 Bytes

Contents

#!/usr/bin/env ruby

require 'rbbt-util'
require 'rbbt/util/simpleopt'

options = SOPT.get("-tch--tokyocabinet:-tcb--tokyocabinet_bd")

file = ARGV.shift

file = STDIN if file == '-'

case
when options[:tokyocabinet]
  tsv = Persist.open_tokyocabinet(file, false)
when options[:tokyocabinet_bd]
  tsv = Persist.open_tokyocabinet(file, false, nil, TokyoCabinet::BDB)
else
  if String === file
    file = file.dup
    Path.setup(File.expand_path(file))
  end
  tsv = TSV.open(file)
end

tsv.each{|k,v| puts (Array === v ? v.flatten*"\t" : v.to_s ) }

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
rbbt-util-5.6.14 share/rbbt_commands/tsv/values
rbbt-util-5.6.13 share/rbbt_commands/tsv/values
rbbt-util-5.6.12 share/rbbt_commands/tsv/values
rbbt-util-5.6.11 share/rbbt_commands/tsv/values
rbbt-util-5.6.10 share/rbbt_commands/tsv/values
rbbt-util-5.6.9 share/rbbt_commands/tsv/values
rbbt-util-5.6.8 share/rbbt_commands/tsv/values
rbbt-util-5.6.7 share/rbbt_commands/tsv/values
rbbt-util-5.6.6 share/rbbt_commands/tsv/values
rbbt-util-5.6.5 share/rbbt_commands/tsv/values
rbbt-util-5.6.4 share/rbbt_commands/tsv/values
rbbt-util-5.6.3 share/rbbt_commands/tsv/values
rbbt-util-5.6.2 share/rbbt_commands/tsv/values