Sha256: 625382e7b798182ad769fa439cc83e53b547bfc05e6272c2de9975d17826c5d7

Contents?: true

Size: 593 Bytes

Versions: 32

Compression:

Stored size: 593 Bytes

Contents

#!/usr/bin/env ruby
require 'optparse'
require 'ostruct'

exec('mandy-cp -h') unless ARGV.size >= 2


options = OpenStruct.new

OptionParser.new do |opts|
  opts.banner = "USAGE: mandy-cp source destination [options]"

  opts.on("-c", "--conf HADOOP_CONF", "Use this cluster xml config file.") do |config|
    options.config = config
  end
  
  opts.on_tail("-h", "--help", "Show this message") do
    puts opts
    exit
  end
end.parse!

source = ARGV[0]
destination = ARGV[1]
config = options.config || 'cluster.xml'

`$HADOOP_HOME/bin/hadoop fs -conf #{config} -cp #{source} #{destination}`

Version data entries

32 entries across 32 versions & 1 rubygems

Version Path
mandy-0.5.9 bin/mandy-cp
mandy-0.5.8 bin/mandy-cp
mandy-0.5.7 bin/mandy-cp
mandy-0.5.6 bin/mandy-cp
mandy-0.5.5 bin/mandy-cp
mandy-0.5.3 bin/mandy-cp
mandy-0.5.2 bin/mandy-cp
mandy-0.5.1 bin/mandy-cp
mandy-0.5 bin/mandy-cp
mandy-0.4.996 bin/mandy-cp
mandy-0.4.995 bin/mandy-cp
mandy-0.4.994 bin/mandy-cp
mandy-0.4.993 bin/mandy-cp
mandy-0.4.992 bin/mandy-cp
mandy-0.4.991 bin/mandy-cp
mandy-0.4.99 bin/mandy-cp
mandy-0.4.98 bin/mandy-cp
mandy-0.4.97 bin/mandy-cp
mandy-0.4.96 bin/mandy-cp
mandy-0.4.95 bin/mandy-cp