Sha256: 4420d843c57a5fb3f158c81d934dffcff170dd0d156b82dc43beac66bcacecfc

Contents?: true

Size: 919 Bytes

Versions: 7

Compression:

Stored size: 919 Bytes

Contents

module Stamina
  #
  # Stamina - A Ruby Automaton & Induction Toolkit
  #
  # SYNOPSIS
  #   #{program_name} [--version] [--help] COMMAND [cmd opts] ARGS...
  #
  # OPTIONS
  # #{summarized_options}
  #
  # COMMANDS
  # #{summarized_subcommands}
  #
  # See '#{program_name} help COMMAND' for more information on a specific command.
  #
  class Command < ::Quickl::Delegator(__FILE__, __LINE__)

    # Install options
    options do |opt|

      # Show the help and exit
      opt.on_tail("--help", "Show help") do
        raise Quickl::Help
      end

      # Show version and exit
      opt.on_tail("--version", "Show version") do
        raise Quickl::Exit, "#{program_name} #{VERSION} (c) 2010-2011, Bernard Lambeau"
      end

    end

  end # class Command
end # module Stamina
require_relative 'command/robustness'
require_relative 'command/help'
require_relative 'command/adl2dot'
require_relative 'command/run'

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
stamina-core-0.6.1 lib/stamina-core/stamina/command.rb
stamina-core-0.6.0 lib/stamina-core/stamina/command.rb
stamina-core-0.5.4 lib/stamina-core/stamina/command.rb
stamina-core-0.5.3 lib/stamina-core/stamina/command.rb
stamina-core-0.5.2 lib/stamina-core/stamina/command.rb
stamina-core-0.5.1 lib/stamina-core/stamina/command.rb
stamina-core-0.5.0 lib/stamina-core/stamina/command.rb