18 lines
273 B
Ruby
18 lines
273 B
Ruby
|
require 'thor'
|
||
|
require 'avm/image'
|
||
|
require 'pp'
|
||
|
|
||
|
module AVM
|
||
|
class CLI < ::Thor
|
||
|
default_task :convert
|
||
|
|
||
|
desc 'convert', "Convert a file from one format to another"
|
||
|
def convert
|
||
|
data = $stdin.read
|
||
|
|
||
|
pp AVM::Image.from_xml(data).to_h
|
||
|
end
|
||
|
end
|
||
|
end
|
||
|
|