Sha256: 29933604e75bd0b4d9c7891fc5db935f8b415b761c8b4932df50a86e51018a19

Contents?: true

Size: 440 Bytes

Versions: 28

Compression:

Stored size: 440 Bytes

Contents

# frozen_string_literal: true
module RuboCop
  # we're monkey patching the config regex to allow for # cookstyle: disable whatever
  # in addition to the # rubocop: disable whatever that comes with RuboCop
  class DirectiveComment
    remove_const('DIRECTIVE_COMMENT_REGEXP')
    DIRECTIVE_COMMENT_REGEXP = Regexp.new(
      "# (?:rubocop|cookstyle) : ((?:disable|enable|todo))\\b #{COPS_PATTERN}"
        .gsub(' ', '\s*')
    )
  end
end

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
cookstyle-7.25.10 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.25.9 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.25.8 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.25.6 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.24.1 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.23.0 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.22.3 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.21.0 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.20.0 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.19.0 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.18.0 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.17.0 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.16.1 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.15.4 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.15.3 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.15.2 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.15.1 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.15.0 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.14.2 lib/rubocop/monkey_patches/directive_comment.rb
cookstyle-7.13.0 lib/rubocop/monkey_patches/directive_comment.rb