Sha256: 1ff7949f11b6a6941191f486ca1b2922c4588d15451e8397175d5163812e06f3
Contents?: true
Size: 1.5 KB
Versions: 3
Compression:
Stored size: 1.5 KB
Contents
require_relative 'cookstyle/version' require 'pathname' require 'yaml' # ensure the desired target version of RuboCop is gem activated gem 'rubocop', "= #{Cookstyle::RUBOCOP_VERSION}" require 'rubocop' require 'rubocop/monkey_patches/comment_config.rb' require 'rubocop/monkey_patches/json_formatter.rb' # monkey patches needed for the TargetChefVersion config option require 'rubocop/monkey_patches/config.rb' require 'rubocop/monkey_patches/cop.rb' require 'rubocop/monkey_patches/commissioner.rb' module RuboCop class ConfigLoader RUBOCOP_HOME.gsub!( /^.*$/, File.realpath(File.join(File.dirname(__FILE__), '..')) ) DEFAULT_FILE.gsub!( /^.*$/, File.join(RUBOCOP_HOME, 'config', 'default.yml') ) end end # Cookstyle patches the RuboCop tool to set a new default configuration that # is vendored in the Cookstyle codebase. module Cookstyle # @return [String] the absolute path to the main RuboCop configuration YAML file def self.config RuboCop::ConfigLoader::DEFAULT_FILE end end require_relative 'rubocop/chef' require_relative 'rubocop/chef/autocorrect_helpers' require_relative 'rubocop/chef/cookbook_helpers' require_relative 'rubocop/chef/platform_helpers' require_relative 'rubocop/chef/cookbook_only' require_relative 'rubocop/cop/target_chef_version' # Chef Infra specific cops Dir.glob(File.dirname(__FILE__) + '/rubocop/cop/chef/**/*.rb') do |file| next if File.directory?(file) require_relative file # not actually relative but require_relative is faster end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
cookstyle-5.23.0 | lib/cookstyle.rb |
cookstyle-5.22.6 | lib/cookstyle.rb |
cookstyle-5.21.9 | lib/cookstyle.rb |