Sha256: 48909d63743abdc8463e91b0cb42063727832fff35d6975a936db90093e49cba
Contents?: true
Size: 721 Bytes
Versions: 3
Compression:
Stored size: 721 Bytes
Contents
# frozen_string_literal: true module NeetoCompliance class WebpackerConfigVerifier < Base def local_copy "config/webpacker.yml" end def commons_copy NeetoCompliance::NeetoCommons.path.join "common_files/webpacker.yml" end def compare_files @file_difference = `diff #{commons_copy} #{local_copy} | grep '<'` end def valid? compare_files @file_difference.empty? end def autofix_suggestion warning = "Following configuration lines are missing in webpacker config (config/webpacker.yml). Please refer #{commons_copy}" .yellow missing_lines = @file_difference.delete("<").red "#{warning}\n\n#{missing_lines}" end end end
Version data entries
3 entries across 3 versions & 1 rubygems