Sha256: 2d0fa55b6a98c8501fd7cb0217769eb067ae48d3f144582b0aac862ee83cb3f1

Contents?: true

Size: 572 Bytes

Versions: 15

Compression:

Stored size: 572 Bytes

Contents

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

require 'cl'

class Add < Cl::Cmd
  opt '--notifications', 'Send out notifications to the team', negate: %w(skip)

  def run
    p notifications?
  end
end

Cl.new('owners').run(%w(add --notifications))

# Output:
#
#   true

Cl.new('owners').run(%w(add --no_notifications))

# Output:
#
#   false

Cl.new('owners').run(%w(add --no-notifications))

# Output:
#
#   false

Cl.new('owners').run(%w(add --skip_notifications))

# Output:
#
#   false

Cl.new('owners').run(%w(add --skip-notifications))

# Output:
#
#   false

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
cl-1.2.2 examples/readme/negate
cl-1.2.1 examples/readme/negate
cl-1.2.0 examples/readme/negate
cl-1.1.5 examples/readme/negate
cl-1.1.4 examples/readme/negate
cl-1.1.3 examples/readme/negate
cl-1.1.2 examples/readme/negate
cl-1.1.1 examples/readme/negate
cl-1.1.0 examples/readme/negate
cl-1.0.5 examples/readme/negate
cl-1.0.4 examples/readme/negate
cl-1.0.3 examples/readme/negate
cl-1.0.2 examples/readme/negate
cl-1.0.1 examples/readme/negate
cl-1.0.0 examples/readme/negate