Sha256: 78825a9dc7e3b047585ce0048382dee964d92c6046f754508df3460d2695eccd

Contents?: true

Size: 304 Bytes

Versions: 16

Compression:

Stored size: 304 Bytes

Contents

#!/usr/bin/env ruby
$: << File.expand_path('lib')

require 'cl'

class Cmd < Cl::Cmd
  arg :one, type: :integer
  arg :two, type: :float
  arg :three, type: :boolean

  def run
    p [one.class, two.class, three.class]
  end
end

Cl.new('owners').run(%w(cmd 1 2.1 yes))

# => [Integer, Float, TrueClass]

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
cl-0.1.28 examples/readme/arg_type
cl-0.1.27 examples/readme/arg_type
cl-0.1.26 examples/readme/arg_type
cl-0.1.25 examples/readme/arg_type
cl-0.1.24 examples/readme/arg_type
cl-0.1.23 examples/readme/arg_type
cl-0.1.22 examples/readme/arg_type
cl-0.1.21 examples/readme/arg_type
cl-0.1.20 examples/readme/arg_type
cl-0.1.19 examples/readme/arg_type
cl-0.1.18 examples/readme/arg_type
cl-0.1.17 examples/readme/arg_type
cl-0.1.16 examples/readme/arg_type
cl-0.1.15 examples/readme/arg_type
cl-0.1.14 examples/readme/arg_type
cl-0.1.13 examples/readme/arg_type