Sha256: f995f8c5e15d3010bb2ef6fef74d414e48fcbe27ce56312f493cce9dec491872

Contents?: true

Size: 500 Bytes

Versions: 4

Compression:

Stored size: 500 Bytes

Contents

#!/usr/bin/env ruby

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

options = SOPT.setup <<EOF
Read a TSV file and dump it

$ rbbt tsv read [options] <filename.tsv|->

Use - to read from STDIN

-k--key_field* Key field
-f--fields* Fields
-t--type* Type
-m--merge* Merge from multiple rows
-h--help Print this help

EOF
rbbt_usage and exit 0 if options[:help]

file = ARGV.shift

file = STDIN if file == '-'

tsv = TSV.open file, :merge => true, :type => :double


puts tsv.to_unmerged_expanded_s

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
rbbt-util-5.27.12 share/rbbt_commands/tsv/uncollapse
rbbt-util-5.27.11 share/rbbt_commands/tsv/uncollapse
rbbt-util-5.27.10 share/rbbt_commands/tsv/uncollapse
rbbt-util-5.27.9 share/rbbt_commands/tsv/uncollapse