Sha256: febcee31824ff7fd53964f5c5a211c03dabcf3f1f55aef8cb56d46fdf3d998f1

Contents?: true

Size: 528 Bytes

Versions: 1

Compression:

Stored size: 528 Bytes

Contents

require 'gli'

module Vindetta
  class CLI
    extend GLI::App

    program_desc 'Vehicle Identification Number (VIN) CLI'

    desc 'Transliterates a VIN character'
    arg_name 'character'
    command :transliterate do |c|
      c.action do |_global, _options, args|
        puts Vindetta::Transliterator.run(args.first)
      end
    end

    desc 'Generates a random vin'
    command :generate do |c|
      c.action do |_global, options, _args|
        puts Vindetta::Generator.generate(options)
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
vindetta-0.4.0 lib/vindetta/cli.rb