ripta/drydock

View on GitHub
lib/drydock/runtime_options.rb

Summary

Maintainability
A
1 hr
Test Coverage

Method has too many lines. [41/20]
Open

    def self.parse!(args)
      opts = new

      parser = OptionParser.new do |cfg|
        cfg.banner = "Usage: #{$PROGRAM_NAME} [options...] [drydock-filename]"
Severity: Minor
Found in lib/drydock/runtime_options.rb by rubocop

This cop checks if the length of a method exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.

Assignment Branch Condition size for parse! is too high. [32.33/15]
Open

    def self.parse!(args)
      opts = new

      parser = OptionParser.new do |cfg|
        cfg.banner = "Usage: #{$PROGRAM_NAME} [options...] [drydock-filename]"
Severity: Minor
Found in lib/drydock/runtime_options.rb by rubocop

This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric

Method parse! has 41 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    def self.parse!(args)
      opts = new

      parser = OptionParser.new do |cfg|
        cfg.banner = "Usage: #{$PROGRAM_NAME} [options...] [drydock-filename]"
Severity: Minor
Found in lib/drydock/runtime_options.rb - About 1 hr to fix

    Block has too many lines. [35/25]
    Open

          parser = OptionParser.new do |cfg|
            cfg.banner = "Usage: #{$PROGRAM_NAME} [options...] [drydock-filename]"
    
            cfg.separator ''
            cfg.separator 'Runtime / build options:'
    Severity: Minor
    Found in lib/drydock/runtime_options.rb by rubocop

    This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.

    There are no issues that match your filters.

    Category
    Status