Sha256: bffffeb8edd78aebb89cf6e5448f2a2782da42f4a0229affcef9aefded34e8d8

Contents?: true

Size: 506 Bytes

Versions: 6506

Compression:

Stored size: 506 Bytes

Contents

# frozen_string_literal: true

module Byebug
  #
  # Custom exception exception to signal "command not found" errors
  #
  class CommandNotFound < NoMethodError
    def initialize(input, parent = nil)
      @input = input
      @parent = parent

      super("Unknown command '#{name}'. Try '#{help}'")
    end

    private

    def name
      build_cmd(@parent, @input)
    end

    def help
      build_cmd("help", @parent)
    end

    def build_cmd(*args)
      args.compact.join(" ")
    end
  end
end

Version data entries

6,506 entries across 6,502 versions & 34 rubygems

Version Path
cybrid_api_id_ruby-0.123.3 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_id_ruby-0.123.2 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_bank_ruby-0.123.2 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_organization_ruby-0.123.2 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_bank_ruby-0.122.72 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_organization_ruby-0.122.72 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_id_ruby-0.122.72 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_bank_ruby-0.122.71 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_id_ruby-0.122.71 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_organization_ruby-0.122.71 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_bank_ruby-0.122.70 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_organization_ruby-0.122.70 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_id_ruby-0.122.70 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_bank_ruby-0.122.69 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_id_ruby-0.122.69 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_organization_ruby-0.122.69 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_organization_ruby-0.122.68 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_bank_ruby-0.122.68 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_id_ruby-0.122.68 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb
cybrid_api_bank_ruby-0.122.67 vendor/bundle/ruby/3.3.0/gems/byebug-11.1.3/lib/byebug/errors.rb