Skip to content

Latest commit

 

History

History
898 lines (699 loc) · 73 KB

CHANGELOG.md

File metadata and controls

898 lines (699 loc) · 73 KB

Cookstyle Changelog

v7.10.1 (2021-04-17)

Merged Pull Requests

v7.10.0 (2021-03-24)

Merged Pull Requests

v7.9.0 (2021-03-08)

Merged Pull Requests

v7.8.3 (2021-02-17)

Merged Pull Requests

  • Stop producing markdown docs + update styleguide to docs.chef.io #832 (tas50)
  • Stop generating the legacy markdown docs #833 (tas50)
  • Update link to the docs in the readme #834 (tas50)

v7.8.0 (2021-02-15)

Merged Pull Requests

  • Generate yaml docs pages for each cop on each PR merge #826 (tas50)
  • Enable Lint/ErbNewArguments cop #828 (tas50)
  • Improve the yaml we generate #829 (tas50)
  • Bump RuboCop to 1.10 #830 (tas50)

v7.7.2 (2021-02-01)

Merged Pull Requests

  • Update the list of SPDX license strings #824 (tas50)
  • Always enable the styleguide links to provide better docs #823 (tas50)
  • Update RuboCop to 1.9.1 #825 (tas50)

v7.6.1 (2021-01-29)

Merged Pull Requests

  • Update dstr handling for new rubocop-ast #820 (tas50)
  • Update RuboCop engine from 1.7 to 1.9 #819 (tas50)
  • Enable Lint/DeprecatedConstants #821 (tas50)

v7.5.3 (2020-12-31)

Merged Pull Requests

  • Update the list of deprecated fauxhai platforms #818 (tas50)

v7.5.2 (2020-12-31)

Merged Pull Requests

  • TrailingBlankLines was renamed TrailingEmptyLines #817 (tas50)

v7.5.1 (2020-12-30)

Merged Pull Requests

  • Update RuboCop to 1.7.0 #814 (tas50)
  • Update UnnecessaryNameProperty to not care about order #815 (tas50)

v7.4.0 (2020-12-21)

Merged Pull Requests

v7.3.11 (2020-12-04)

Merged Pull Requests

v7.3.10 (2020-12-01)

Merged Pull Requests

  • Disable cop with potentially misleading warning message. #799 (phiggins)
  • Bump RuboCop to 1.4.1 #800 (tas50)
  • Update RuboCop to 1.4.2 #801 (tas50)
  • Unpin parallel gem since it supports Ruby 2.4 again #806 (tas50)
  • Don't use DSL actions in HWRPs #802 (tas50)
  • Exclude more files in our cops to speed them up #803 (tas50)
  • Add new Chef/Deprecations/DeprecatedYumRepositoryActions cop #804 (tas50)
  • Run Chef/Modernize/RespondToProvides in resources as well #808 (tas50)
  • Update Chef/Style/CommentSentenceSpacing to use the new RuboCop methods #807 (tas50)
  • Add new Chef/Deprecations/ChefSugarHelpers cop #805 (tas50)
  • Update to RuboCop 1.5.0 #810 (tas50)
  • Add additional deprecated Fauxhai platforms #811 (tas50)

v7.2.1 (2020-11-16)

Merged Pull Requests

v7.1.2 (2020-11-05)

Merged Pull Requests

  • Remove the release branch constraints #782 (tas50)
  • Add a new Chef/Deprecations/LibrarianChefSpec cop #783 (tas50)
  • Add new Chef/Deprecations/FoodcriticTesting cop #785 (tas50)
  • Update to RuboCop 1.2.0 #791 (tas50)
  • Enable Style/CollectionCompact #792 (tas50)
  • Handle more multipackage scenarios #790 (tas50)

v7.0.0 (2020-10-29)

Merged Pull Requests

v6.21.1 (2020-10-15)

Merged Pull Requests

  • Add new ChefCorrectness/OctalModeAsString cop #777 (tas50)
  • Add ChefDeprecations/UseYamlDump cop #778 (tas50)
  • Add release notes for 6.21 #779 (tas50)

v6.20.2 (2020-10-12)

Merged Pull Requests

v6.20.1 (2020-10-08)

Merged Pull Requests

v6.19.11 (2020-10-02)

Merged Pull Requests

  • Speedup runs by 4.3% with restrict on send #766 (tas50)
  • Simplify ChefDeprecations/ResourceOverridesProvidesMethod #767 (tas50)
  • Remove extra Gem::Dependency.new code #768 (tas50)
  • Use + instead of dup to unfreeze a string #769 (tas50)
  • Ident all the heredocs #770 (tas50)
  • Enable rubocop-performance in CI #771 (tas50)

v6.19.5 (2020-09-28)

Merged Pull Requests

v6.18.8 (2020-09-17)

Merged Pull Requests

  • Update RuboCop to 0.91 #748 (tas50)
  • Add new ChefCorrectness/LazyInResourceGuard cop #750 (tas50)
  • Backport a fix for Layout/RescueEnsureAlignment #749 (tas50)
  • Enable Lint/RedundantRequireStatement cop #752 (tas50)
  • Add new ChefCorrectness/PropertyWithoutType cop #751 (tas50)
  • Enable 8 more RuboCop cops to simplify code #753 (tas50)
  • Optimize our slowest cop #754 (tas50)
  • Enable 3 new ruby cops & remove duplicate disables #756 (tas50)
  • Cookstyle 6.18 release notes #755 (tas50)

v6.17.7 (2020-09-15)

Merged Pull Requests

  • ChefCorrectness/IncorrectLibraryInjection: Avoid adding duplicate includes in autocorrection #747 (tas50)

v6.17.6 (2020-09-14)

Merged Pull Requests

  • ChefCorrectness/IncorrectLibraryInjection: Catch more offenses #745 (tas50)

v6.17.5 (2020-09-11)

Merged Pull Requests

  • Add missing description to rake task #738 (tas50)
  • Replace uses of File.dirname(FILE) with dir #737 (tas50)
  • Minor optimizations from rubocop-performance #739 (tas50)
  • Remove unused stuff from spec_helper. #741 (phiggins)
  • Spec cleanup from rubocop-rspec #740 (tas50)
  • Add new deprecation cops to help people get off Chef 12 #742 (tas50)
  • Add Cookstyle 6.17 release notes #743 (tas50)

v6.16.10 (2020-09-03)

Merged Pull Requests

  • Enable Lint/Syntax cop that previously enabled by default #735 (tas50)

v6.16.9 (2020-09-02)

Merged Pull Requests

  • Resolve another regression in CustomResourceWithAllowedActions #731 (tas50)
  • Resolve a regression in ResourceOverridesProvidesMethod #732 (tas50)

v6.16.7 (2020-09-02)

Merged Pull Requests

  • Use RESTRICT_ON_SEND to speedup on_send checks #728 (tas50)
  • Restrict on_sends to specific methods throughout #729 (tas50)
  • Resolve a regression in CustomResourceWithAllowedActions #730 (tas50)

v6.16.4 (2020-09-01)

Merged Pull Requests

  • Update Deprecations rules to latest RuboCop format #720 (scottvidmar)
  • Effortless and Redundant cops refactor to latest Rubocop format #721 (scottvidmar)
  • Update Correctness cops to latest Rubocop format and added corrector for ResourceWithNoneAction #722 (scottvidmar)
  • Update RuboCop engine to 0.90 #723 (tas50)
  • Refactoring Cookstyle rules to latest format of Rubocop #725 (scottvidmar)
  • Move CookbooksDependsOnSelf from ChefCorrectness to ChefDeprecations #726 (tas50)

v6.15.9 (2020-08-25)

Merged Pull Requests

  • Update the list of deprecated fauxhai/chefspec platforms #716 (tas50)
  • Refactor Ruby27KeywordArgumentWarnings #717 (tas50)
  • Fix IncludePropertyDescriptions to catch all occurrences #718 (tas50)
  • Update IncludeResourceDescriptions to allow string interpolation #719 (tas50)

v6.15.5 (2020-08-13)

Merged Pull Requests

  • Fix typo in ChefSharing/EmptyMetadataField #714 (tas50)
  • Optimize requires for non omnibus installs #715 (tas50)

v6.15.3 (2020-08-10)

Merged Pull Requests

v6.14.7 (2020-07-30)

Merged Pull Requests

  • Fix matcher name to match what we're doing #691 (tas50)
  • Multiple spelling corrections including a cop name #697 (tas50)
  • Update dead links #696 (dg42xyz)
  • Cleanup leftover config from rubocop-chef project #698 (tas50)
  • Fix a few incorrect StyleGuide links #699 (tas50)
  • Fix target_chef_version support in the new Rubocop 0.88+ format of cops #700 (tas50)
  • Add 2 new cops for macos_userdefaults changes in 16.3 #701 (tas50)
  • Update ChefStyle/FileMode to support files_mode as well #702 (tas50)

v6.13.3 (2020-07-17)

Merged Pull Requests

  • Add ChefCorrectness/InvalidDefaultAction cop #685 (tas50)
  • Add new ChefModernize/CronDFileOrTemplate cop #686 (tas50)
  • Add ChefRedundantCode/DoubleCompileTime cop #687 (tas50)
  • Add ChefCorrectness/SupportsMustBeFloat #689 (tas50)
  • Add release notes for 6.13 #690 (tas50)
  • Add ChefModernize/ActionMethodInResource cop #688 (tas50)

v6.12.6 (2020-07-15)

Merged Pull Requests

  • Detect additional ways to shellout to apt-get update #670 (tas50)
  • Add new ChefDeprecations/ChefDKGenerators cop #671 (tas50)
  • Add ChefDeprecations/ChefHandlerRecipe cop #678 (tas50)
  • Add ChefDeprecations/UseAutomaticResourceName cop #680 (tas50)
  • Bump RuboCop to 0.88 #683 (tas50)
  • Set frozen string literals to true in all files #682 (tas50)
  • Copy over profiling support from RuboCop #681 (tas50)

v6.11.4 (2020-07-09)

Merged Pull Requests

  • Update RuboCop engine to 0.87.1 #664 (tas50)
  • Expand NodeInitPackage to catch more bad systemd tests #665 (tas50)
  • Add new ChefStyle/IncludeRecipeWithParentheses #667 (tas50)
  • Add new cop ChefModernize/ConditionalUsingTest #666 (tas50)
  • Expand IncorrectLibraryInjection to detect more types of injection #668 (tas50)

v6.10.2 (2020-07-07)

Merged Pull Requests

  • Add cookstyle cop to detect using .to_s on ohai attribute #659 (tas50)
  • Add new ChefRedundantCode/MultiplePlatformChecks cop #660 (tas50)
  • Monkeypatch the Migration/DepartmentName cop to suggest cookstyle #661 (tas50)
  • Add ChefSharing/IncludeResourceExamples #662 (tas50)

v6.9.0 (2020-06-25)

Merged Pull Requests

  • Add Cookstyle 6.8 release notes #652 (tas50)
  • Minor optimizations from Rubocop Performance #653 (tas50)
  • Update Rubocop to 0.86 #656 (tas50)

v6.8.0 (2020-06-08)

Merged Pull Requests

  • Make sure we autocorrect to both provide and resource_name for Chef < 16 #647 (tas50)
  • Update to rubocop 0.85.1 #650 (tas50)
  • Update resource_name/provides cops to detect new Chef 16.2+ behavior #648 (lamont-granquist)

v6.7.3 (2020-06-02)

Merged Pull Requests

  • Expand ChefModernize/IncludingMixinShelloutInResources to work in HWRPs #643 (tas50)
  • Update RuboCop engine to 0.85 #634 (tas50)
  • Improve a few specs #645 (tas50)
  • Add ChefDeprecations/ResourceUsesOnlyResourceName #644 (tas50)

v6.6.9 (2020-05-27)

Merged Pull Requests

  • Add new ChefCorrectness/LazyEvalNodeAttributeDefaults cop #632 (tas50)
  • Minor update RELEASE_NOTES.md#cookstyle-62 #633 (vsingh-msys)
  • Catch conditionals in ChefDeprecations/IncludingXMLRubyRecipe #635 (tas50)
  • Add oracle as an invalid platform_family #636 (tas50)
  • Add new ChefCorrectness/OpenSSLPasswordHelpers cop #638 (tas50)
  • Detect package installs w/o an action in the multipackage cop #637 (tas50)
  • Add new cops for incorrect platforms / platform families #639 (tas50)
  • Add Cookstyle 6.6 release notes #640 (tas50)
  • Add more styleguide links #641 (tas50)
  • Add in the remaining styleguide links #642 (tas50)

v6.5.3 (2020-05-19)

Merged Pull Requests

  • mistyped name #627 (Xorima)
  • More cleanup of legacy ChefSpec/Fauxhai platforms #628 (tas50)
  • Add ChefDeprecations/Ruby27KeywordArgumentWarnings cop #629 (tas50)
  • Add Cookstyle 6.5 release notes #631 (tas50)
  • Add new ChefModernize/ShellOutHelper cop #630 (tas50)

v6.4.4 (2020-05-12)

Merged Pull Requests

  • Wire up the 5-stable branch #612 (tas50)
  • Document the target chef version of each cop #617 (tas50)
  • Remove double spaces after periods in documentation #618 (tas50)
  • Update some descriptions #619 (tas50)
  • Enable ChefModernize/FoodcriticComments by default #622 (tas50)
  • Update RuboCop to 0.83 #623 (tas50)
  • Support an edge case where the supports / manage_home value is a method #624 (tas50)
  • Fix our files and vendor exclusion to work #625 (tas50)
  • Add Cookstyle 6.4 release notes #626 (tas50)

v6.3.4 (2020-04-16)

Merged Pull Requests

  • Catch more offenses in ChefModernize/RespondToProvides #605 (tas50)
  • Add new ChefModernize/RespondToCompileTime cop #607 (tas50)
  • Update to RuboCop 0.82 engine #608 (tas50)
  • Add ChefDeprecations/DeprecatedShelloutMethods cop #609 (tas50)
  • Add Cookstyle 6.3 notes #610 (tas50)
  • Add a few missing shell_out methods #611 (tas50)

v6.2.9 (2020-04-04)

Merged Pull Requests

  • Fix a crash and false positive in ChefStyle/NegatingOnlyIf #602 (tas50)
  • Improve ChefModernize/WhyRunSupportedTrue to detect a common typo #603 (tas50)
  • Improve the LogResourceNotifications to tell when notify_group was introduced #604 (tas50)
  • Fix typo in ChefRedundantCode/SensitivePropertyInResource warning #606 (tas50)

v6.2.5 (2020-04-03)

Merged Pull Requests

  • Add ChefRedundantCode/UseCreateIfMissing cop #595 (tas50)
  • Update RuboCop to 0.81 #596 (tas50)
  • Fix syntax on ChefCorrectness/IncorrectLibraryInjection. #598 (ncerny)
  • Add Chef version constraints to multiple deprecation cops #600 (tas50)
  • Detect code that negates an only_if #537 (tas50)
  • Add Cookstyle 6.2 notes #601 (tas50)

v6.1.6 (2020-03-27)

Merged Pull Requests

  • Add ChefCorrectness/ConditionalRubyShellout cop #586 (tas50)
  • Move WindowsVersionHelper to ChefDeprecations & add autocorrect #587 (tas50)
  • Add ChefDeprecations/PowershellCookbookHelpers #588 (tas50)
  • Add ChefModernize/NodeRolesInclude rule #589 (tas50)
  • Fix chef infra version in PowershellInstallWindowsFeature #591 (tas50)
  • Add cops for resource / property descriptions #590 (tas50)
  • Add Cookstyle 6.1 release notes #593 (tas50)

v6.0.19 (2020-03-20)

Merged Pull Requests

  • Move Cookstyle to the Chef Infra project #538 (tas50)
  • Update RuboCop engine to 0.80.1 #479 (tas50)
  • Disable the Naming/PredicateName #552 (tas50)
  • Update ChefRedundant/UnnecessaryNameProperty to detect attributes #551 (tas50)
  • Update DefaultActionFromInitialize to not care about variable order #555 (tas50)
  • Enable ChefStyle/UnnecessaryOSCheck #573 (tas50)
  • Add autocorrection to ChefCorrectness/DnfPackageAllowDowngrades #571 (tas50)
  • Update ChefModernize/PowerShellGuardInterpreter to look at all resources #572 (tas50)
  • Add ChefCorrectness/ChefApplicationFatal cop #570 (tas50)
  • Add new cop ChefModernize/UseMultipackageInstalls #553 (tas50)
  • Detect the short form the of registry key in ChefModernize/WindowsRegistryUAC #575 (tas50)
  • Add ChefCorrectness/PowershellScriptDeleteFile #576 (tas50)
  • Add ChefModernize/ProvidesFromInitialize cop #574 (tas50)
  • Add ChefModernize/DatabagHelpers #577 (tas50)
  • Allow arrays in match_property_in_resource and fix powershell interp cop #578 (tas50)
  • Add ChefDeprecations/DeprecatedWindowsVersionCheck check #580 (tas50)
  • Add ChefDeprecations/ChefWindowsPlatformHelper cop #581 (tas50)
  • Add ChefDeprecations/LogResourceNotifications cop #583 (tas50)
  • Add ChefDeprecations/ResourceWithoutNameOrProvides cop #584 (tas50)
  • Update the severity for all deprecation cops to be :warning #585 (tas50)
  • Add release notes for Cookstyle 6 #582 (tas50)

v5.22.6 (2020-02-28)

Merged Pull Requests

  • Add ChefModernize/UseRequireRelative #535 (tas50)
  • Use node['init_package'] to detect systemd #536 (tas50)
  • Add ChefDeprecations/WindowsFeatureServermanagercmd #541 (tas50)
  • Revert "Match on attributes in TrueClassFalseClassResourceProperties" #542 (tas50)
  • Add ChefModernize/WindowsRegistryUAC cop #540 (tas50)
  • Detect more apt-get update scenarios #546 (tas50)
  • Disable Naming/MethodName and Naming/VariableName #545 (tas50)

v5.21.9 (2020-02-19)

Merged Pull Requests

  • Disable Style/ModuleFunction #517 (tas50)
  • Set the target ruby version to 2.3 to support Chef 12 #518 (tas50)
  • Make sure metadata cops properly autocorrect heredocs #520 (tas50)
  • Remove the duplicate Style/ModuleFunction config #521 (tas50)
  • Expand ChefStyle/UsePlatformHelpers to also detect node['platform'].eql? #523 (tas50)
  • Autocorrect Layout/EndAlignment and Layout/DefEndAlignment #529 (tas50)
  • Autocorrect 'apache v2' to 'Apache-2.0' #530 (tas50)
  • Don't fail ChefDeprecations/WindowsTaskChangeAction with a non-string action #531 (tas50)
  • Fix IncludingYumDNFCompatRecipe to not break with inline conditionals #532 (tas50)
  • Add 3 new cops #522 (tas50)
  • Add new ChefStyle/UnnecessaryOSCheck cop #524 (tas50)

v5.20.0 (2020-01-24)

Merged Pull Requests

  • Add Style/ChefWhaaat cop #507 (tas50)
  • Add autocorrect to libarchive_file resources #509 (tas50)
  • Catch shelling out to sysctl when using the full path #510 (tas50)
  • Add ChefDeprecations/DeprecatedChefSpecPlatform #511 (tas50)
  • Fix autocorrection failures in ChefDeprecations/ChefHandlerUsesSupports #508 (tas50)

v5.19.9 (2020-01-13)

Merged Pull Requests

  • Update metadata.rb cops to not leave empty lines behind #487 (tas50)
  • Properly cleanup heredoc long_description metadata #488 (tas50)
  • Add ChefRedundantCode/GroupingMetadata #489 (tas50)
  • Better trim metadata.rb whitespace #490 (tas50)
  • Remove more empty lines in autocorrection #491 (tas50)
  • Handle user resource supports with hash rockets #493 (tas50)
  • Fix ChefStyle/FileMode to autocorrect single quotes #494 (tas50)
  • Add ChefStyle/OverlyComplexSupportsDependsMetadata #495 (tas50)
  • Add clarity to License Strings #501 (Xorima)
  • Additional fixes for ChefDeprecations/UserDeprecatedSupportsProperty #502 (tas50)
  • Fix false positives in ChefModernize/AllowedActionsFromInitialize #503 (tas50)
  • Avoid false positives in ChefModernize/DefaultActionFromInitialize #504 (tas50)

v5.18.4 (2020-01-03)

Merged Pull Requests

  • Test on Ruby 2.7 + other minor testing updates #477 (tas50)
  • Improve property cops #478 (tas50)
  • Match on attributes in TrueClassFalseClassResourceProperties #480 (tas50)
  • Better exclude the files / vendor directories #481 (tas50)
  • Add ChefModernize/ResourceForcingCompileTime #482 (tas50)
  • Add 5.18 release notes #484 (tas50)
  • Add ChefModernize/ExecuteSysctl cop #483 (tas50)

v5.17.4 (2019-12-21)

Merged Pull Requests

  • Add ChefModernize/DslIncludeInResource #470 (tas50)
  • Add Powershell mixins to ChefModernize/IncludingMixinShelloutInResources #469 (tas50)
  • Handle supports metadata in an array #473 (tas50)
  • Add 2 new cops for removing redundant config in apt_repository #472 (tas50)
  • Fix .start_with? errors on Ruby 2.4 #474 (tas50)
  • Substitute require for require_relative #476 (tas50)

v5.16.11 (2019-12-17)

Merged Pull Requests

  • Enable several cops that were accidently disabled #468 (tas50)

v5.16.10 (2019-12-17)

Merged Pull Requests

  • Add new TargetChefVersion config option #419 (tas50)
  • Add a cop for removing legacy Foodcritic comments #446 (tas50)
  • Add ChefDeprecations/RubyBlockCreateAction cop #449 (tas50)
  • Add ChefStyle/UnnecessaryPlatformCaseStatements #448 (tas50)
  • Add ChefDeprecations/DeprecatedPlatformMethods #450 (tas50)
  • Support checking both notifies and subscribes properties in cops #451 (tas50)
  • Add ChefCorrectness/InvalidNotificationTiming cop #454 (tas50)
  • Add ChefStyle/ImmediateNotificationTiming cop #453 (tas50)
  • Add ChefRedundantCode/SensitivePropertyInResource cop #457 (tas50)
  • Improve the cops that check properties / attributes #458 (tas50)
  • Detect additional ways of checking platform / platform_family with node data #456 (tas50)
  • Add ChefCorrectness/MalformedPlatformValueForPlatformHelper cop #459 (tas50)
  • Add ChefCorrectness/DnfPackageAllowDowngrades #452 (tas50)
  • Speed up Cookstyle by excluding more files #460 (tas50)
  • Add 5 new cops for the 5.16 release #462 (tas50)
  • Handle additional scenarios of platform checks #464 (tas50)
  • Add additional release notes for 5.16 #465 (tas50)

v5.15.7 (2019-12-11)

Merged Pull Requests

  • Add new rubygems metadata #425 (tas50)
  • Move the metadata cops to ChefModernize #426 (tas50)
  • Add a new ChefRedundantCode and ChefSharing cop groups #428 (tas50)
  • Add ChefCorrectness/InvalidPlatformHelper and ChefCorrectness/InvalidPlatformFamilyHelper #430 (tas50)
  • Add ChefCorrectness/ScopedFileExist cop #432 (tas50)
  • Update ChefModernize/LegacyBerksfileSource to detect REALLY old configs #434 (tas50)
  • Detect @default_action in the initializer as well #435 (tas50)
  • Don't detect poise resources in CustomResourceWithAllowedActions #439 (tas50)
  • Rework how we autocorrect allowed actions #436 (tas50)
  • Move invalid platform constants into a single helper #440 (tas50)
  • Add more invalid platform families to our helper #444 (tas50)
  • Add new platform cops for the value_for_platform / value_for_platform_family helpers #445 (tas50)

v5.14.1 (2019-12-06)

Merged Pull Requests

  • Add new ChefDeprecations/ChefRewind cop #422 (tas50)
  • Add new ChefModernize/ChefGemNokogiri cop #421 (tas50)
  • Improve IncludingMixinShelloutInResources cops message to include Chef Versions #423 (tas50)
  • Expand ChefDeprecations/UsesRunCommandHelper to catch more cases #424 (tas50)

v5.13.7 (2019-11-21)

Merged Pull Requests

  • DefaultActionFromInitialize: don't insert dupe default_action #410 (tas50)
  • Add ChefModernize/EmptyResourceInitializeMethod cop #411 (tas50)
  • Add ChefDeprecations/LegacyNotifySyntax #412 (tas50)
  • Adding correctable info to json formatter #413 (tyler-ball)
  • Improve auto correction in LegacyNotifySyntax #415 (tas50)
  • Add ChefDeprecations/NodeSetWithoutLevel cop #416 (tas50)
  • Add Ruby 2.7 testing in Buildkite #417 (tas50)
  • Cache the bundles in S3 to speed up tests #418 (tas50)
  • Add Cookstyle 5.13 notes #414 (tas50)

v5.12.13 (2019-11-14)

Merged Pull Requests

  • Readme updates to trigger a new build #409 (tas50)

v5.12.12 (2019-11-14)

Merged Pull Requests

  • Update the readme cop count on each merge #388 (tas50)
  • Add ChefModernize/IfProvidesDefaultAction cop #389 (tas50)
  • Add ChefStyle/DefaultCopyrightComments #393 (tas50)
  • Add ChefModernize/ZipfileResource #392 (tas50)
  • Autocorrect node['platform'] != to platform?() helpers #391 (tas50)
  • Handle non modifier if statements in ChefModernize/RespondToInMetadata #396 (tas50)
  • Add ChefCorrectness/ResourceWithNothingAction cop #399 (tas50)
  • Add ChefEffortless/Berksfile #398 (tas50)
  • Allow # cookstyle comments in addition to # rubocop comments #400 (tas50)
  • Add ChefDeprecations/Cheffile #397 (tas50)
  • add cops for chef-sugar's node.deep_fetch #402 (lamont-granquist)
  • Add ChefModernize/UnnecessaryMixlibShelloutRequire #403 (tas50)
  • Detect run_command_with_systems_locale in ChefDeprecations/UsesRunCommandHelper #407 (tas50)
  • Add Cookstyle 5.12 release notes #404 (tas50)

v5.11.0 (2019-11-08)

Merged Pull Requests

  • Add additional helpers for working with resources #310 (tas50)
  • Fix docs updater script to work with Rubocop 0.75+ #361 (tas50)
  • Add new poise_archive cop and definition cop #362 (tas50)
  • Add ChefDeprecations/PartialSearchHelperUsage #363 (tas50)
  • Add ChefDeprecations/SearchUsesPositionalParameters: #366 (tas50)
  • Add ChefDeprecations/PartialSearchClassUsage #367 (tas50)
  • Add ChefEffortless/SearchForEnvironmentsOrRoles #368 (tas50)
  • Fix the description of ChefModernize/UseBuildEssentialResource #386 (tas50)
  • RespondToInMetadata: Catch if defined in metadata as well #385 (tas50)
  • Add 5.11 release notes #384 (tas50)

v5.10.13 (2019-10-25)

Merged Pull Requests

  • Detect poise-service in addition to just poise #353 (tas50)
  • Fix the files we target with NotifiesActionNotSymbol & IncorrectLibraryInjection #357 (tas50)

v5.10.11 (2019-10-24)

Merged Pull Requests

  • Add ChefCorrectness/NotifiesActionNotSymbol cop #335 (tas50)
  • Expand ChefModernize/CustomResourceWithAllowedActions to work in HWRPs #334 (tas50)
  • Add ChefCorrectness/IncorrectLibraryInjection cop #338 (tas50)
  • Add 3 new cops for migrating to Effortless #337 (tas50)
  • Add ChefDeprecations/LegacyYumRepositoryProperties #343 (tas50)
  • Add ChefDeprecations/EOLAuditModeUsage #344 (tas50)
  • Add ChefDeprecations/ResourceInheritsFromCompatResource #340 (tas50)
  • Add ChefDeprecations/VerifyPropertyUsesFileExpansion cop #339 (tas50)
  • Add Cookstyle 5.10 release notes #347 (tas50)
  • Expand what we detect in ChefModernize/CustomResourceWithAllowedActions #345 (tas50)
  • Add ChefModernize/DefaultActionFromInitialize and ChefModernize/ResourceNameFromInitialize: #348 (tas50)
  • Expand the detection of node.chef_environment #349 (tas50)

v5.9.3 (2019-10-16)

Merged Pull Requests

  • Add Cookstyle 5.8 release notes #319 (tas50)
  • Add ChefDeprecations/UsesRunCommandHelper cop #327 (tas50)
  • Add a better description to the gem #328 (tas50)
  • Add ChefModernize/PowerShellGuardInterpreter cop #329 (tas50)
  • Add ChefDeprecations/ChefHandlerUsesSupports #326 (tas50)
  • Fix ChefModernize/UnnecessaryDependsChef14 to detect version constraints #325 (tas50)

v5.8.1 (2019-10-12)

Merged Pull Requests

  • Update CustomResourceWithAllowedActions to trigger on LWRPs as well #305 (tas50)
  • Auto generate the docs with expeditor on PR merge #311 (tas50)
  • Reformat text comments for better docs #312 (tas50)
  • Catch use_inline_resources if respond_to?(:use_inline_resources) #318 (tas50)
  • Add autocorrection to ChefDeprecations/UserDeprecatedSupportsProperty #317 (tas50)
  • Add ChefCorrectness/UnnecessaryNameProperty #316 (tas50)
  • Add ChefDeprecations/ChefSpecCoverageReport & ChefDeprecations/ChefSpecLegacyRunner cops #306 (tas50)
  • Simplify ChefDeprecations/LongDescriptionMetadata #308 (tas50)
  • Add ChefStyle/SimplifyPlatformMajorVersionCheck #315 (tas50)
  • Add ChefCorrectness/EmptyMetadataField cop #313 (tas50)
  • Add ChefCorrectness/InvalidVersionMetadata cop #309 (tas50)

v5.7.0 (2019-10-04)

Merged Pull Requests

  • Add 5 more cops for LWRP deprecations in Chef 13 #296 (tas50)

v5.6.5 (2019-10-02)

Merged Pull Requests

  • Add release notes for 5.6 #293 (tas50)
  • Fix autocorrection of multiple platform helpers in a recipe #303 (tas50)
  • Remove the newline when autocorrecting long_description in metadata #304 (tas50)

v5.6.2 (2019-09-16)

Merged Pull Requests

  • Add ChefDeprecations/WindowsTaskChangeAction #288 (tas50)
  • Add ChefDeprecations/RecipeMetadata cop #287 (tas50)
  • Add ChefStyle/UsePlatformHelpers cop #286 (tas50)
  • Add 9 new cops for updating to resources in Chef Infra Client #289 (tas50)
  • Add autocorrects to 7 cops #290 (tas50)

v5.5.7 (2019-09-06)

Merged Pull Requests

  • Validate that all cops are in the config in CI + add missing Chef/CookbookUsesNodeSave #272 (tas50)
  • Add Chef/LibarchiveFile and Chef/SevenZipArchiveResource #271 (tas50)
  • Catch additional formats for default maintainer information in metadata #275 (tas50)
  • Add Chef/UsesChefRESTHelpers #276 (tas50)
  • Add helpers for matching on resource properties and add 11 new cops using those helpers #226 (tas50)
  • Add the documentation generation rake task from rubocop-rspec #278 (tas50)
  • Add release notes for Cookstyle 5.5 #279 (tas50)
  • Add additional autocorrect and improve autocorrection testing #282 (tas50)
  • Break up the Chef namespace into 4 namespaces #283 (tas50)

v5.4.13 (2019-08-30)

Merged Pull Requests

  • Add Chef/NodeMethodsInsteadofAttributes cop #224 (tas50)
  • Avoid scanning metadata.rb files for rules that don't apply there #225 (tas50)
  • Add Chef/MinitestHandlerUsage Chef/WindowsVersionHelper Chef/WindowsZipfileUsage #237 (tas50)
  • Add autocorrect to MetadataMissingName #244 (tas50)
  • Add Chef/UsesDeprecatedMixins #243 (tas50)
  • Add Chef/DefaultMetadataMaintainer #242 (tas50)
  • Add Chef/IncludingOhaiDefaultRecipe Chef/IncludingXMLRubyRecipe & Chef/LegacyYumCookbookRecipes #246 (tas50)
  • Improve error messages in CookbooksDependsOnSelf & PropertyWithRequiredAndDefault #262 (tas50)
  • Fix Chef/WhyRunSupportedTrue to find the correct method #261 (tas50)
  • Add UseInlineResourcesDefined cop #260 (tas50)
  • Exclude the files directory for scans #248 (tas50)
  • Add Chef/IncludingMixinShelloutInResources cop #249 (tas50)
  • Add spec for Chef/PropertyWithRequiredAndDefault #263 (tas50)
  • Remove old spec helpers leftover from rubocop-rspec #265 (tas50)

v5.3.6 (2019-08-20)

Merged Pull Requests

  • Add 3 new cops for detecting legacy recipes being included #214 (tas50)
  • Use Rubocop::RSpec::ExpectOffense for better specs #215 (tas50)
  • Add Chef/DefinesChefSpecMatchers: cop #216 (tas50)
  • Add auto correct specs where possible #220 (tas50)
  • Autocorrect Apache v2.0 license to Apache-2.0 #221 (tas50)
  • Add Chef/ExecuteAptUpdate rule #222 (tas50)
  • Fix autocorrection of comments that are indented with more than one space #223 (tas50)

v5.2.17 (2019-08-15)

Merged Pull Requests

  • Add Chef/CookbooksDependsOnSelf and Chef/MetadataMissingName #162 (tas50)
  • Add Chef/RequireRecipe rule #161 (tas50)
  • Add Chef/InvalidLicenseString cop #171 (tas50)
  • Add Chef/LongDescriptionMetadata cop #170 (tas50)
  • Add Chef/RespondToInMetadata cop #174 (tas50)
  • Add Chef/InvalidPlatformMetadata cop #173 (tas50)
  • fix node.set/set_unless autocorrects to not break ChefSpec tests #175 (lamont-granquist)
  • don't need the ${}'s guess that is grouping #176 (lamont-granquist)
  • Enable UseBuildEssentialResource and improve messaging #177 (tas50)
  • Fix file matching in the configs #178 (tas50)
  • Fix typo in method name #179 (tas50)
  • Add Chef/RespondToResourceName and Chef/RespondToProvides cops #180 (tas50)
  • Add Chef/SetOrReturnInResources cop #181 (tas50)
  • Add autocorrecting to CookbooksDependsOnSelf #186 (tas50)
  • Fix the regression where we no longer show the cookstyle version #188 (tas50)
  • Add Chef/BlockGuardWithOnlyString #189 (tas50)
  • Add Cookstyle 5.2 release notes #182 (tas50)
  • Add Chef/CustomResourceWithAttributes cop #193 (tas50)
  • Add Chef/CustomResourceWithAllowedActions #192 (tas50)

v5.1.19 (2019-08-08)

Merged Pull Requests

  • Add cop to detect old Berksfile sources #81 (tas50)
  • Add an autocorrect for insecure gitlab/github source/issue url metadata #82 (tas50)
  • Add Chef/CommentSentenceSpacing cop (disabled by default) #83 (tas50)
  • Add Chef/NodeSetUnless to autocorrect node.set_unless usage #102 (lamont-granquist)
  • Add Chef/NodeNormal & Chef/NodeNormalUnless for node.normal/node.normal_unless usage #104 (lamont-granquist)
  • Add Chef/WhyRunSupportedTrue #115 (tas50)
  • Test the cookstyle binary on Windows in Buildkite #116 (tas50)
  • Improve detection of double spaces after sentences #120 (tas50)
  • Add new UseBuildEssentialResource cop #118 (tas50)
  • Force the fail level to :convention and set rules to :refactor level #117 (tas50)
  • Add Chef/EpicFail #124 (tas50)
  • Add new PropertyWithNameAttribute rule #125 (tas50)
  • Add new Chef/PropertyWithRequiredAndDefault #129 (tas50)
  • Avoid false positives in header cleanup #133 (tas50)
  • Rework the docs for the new world of Chef specific rules #122 (tas50)
  • Add rules for Effortless Infra pattern #137 (tas50)
  • Add the majority of specs from rubocop-chef #138 (tas50)
  • Add introduced fields and turn off Chef/UseBuildEssentialResource by default #139 (tas50)
  • Add additional specs #142 (tas50)
  • Add Chef/CookbookDependsOnPoise rule #140 (tas50)
  • Add Chef/NamePropertyIsRequired cop #141 (tas50)
  • Add 10 additional cops for detected deprecated behavior #143 (tas50)

v5.0.4 (2019-07-15)

Merged Pull Requests

v5.0.0 (2019-07-02)

Merged Pull Requests

  • Add buildkite PR test pipeline #67 (tas50)
  • Fix buildkite pipeline setup #68 (tas50)
  • Update RuboCop to 0.72 & merge rubocop-chef #69 (tas50)

v4.0.0 (2019-01-22)

Merged Pull Requests

  • Require Ruby 2.2+ and update boilerplate #57 (tas50)
  • Unpin the bundler dev dep #59 (tas50)
  • Fix the update version script for expeditor #60 (tas50)
  • Update cases in the readme #61 (tas50)
  • Update to RuboCop 0.62 and require Ruby 2.4 #62 (tas50)
  • Bump to 4.0 and resolve new cookstyle warnings #63 (tas50)

3.0.2 (2018-12-14)

  • Add back the gemspec and gemfile in the gem artifact so this gem can be appbundled in projects like Chef DK / Workstation.

3.0.1 (2018-11-20)

Cookstyle now ignores lazy { } for symbol proc check. The autocorrected code produced by the RuboCop engine would cause chef-client failures in this situation. Thanks @martinisoft for the fix

3.0.0 (2018-05-07)

The RuboCop engine has been updated from 0.49 to 0.55 in this release of Cookstyle. This fixes a very large number of bugs and may lead to new warnings being shown for existing rules. Additionally the names of many rules were changed which may require updating your .rubocop.yml files if you previously disabled these rules.

Newly Enabled Cops:

  • Bundler/InsecureProtocolSource
  • Layout/EmptyComment
  • Layout/EmptyLinesAroundArguments
  • Lint/BigDecimalNew
  • Lint/BooleanSymbol
  • Lint/InterpolationCheck:
  • Lint/RedundantWithIndex
  • Lint/RedundantWithObject
  • Lint/RegexpInCondition
  • Lint/ShadowedArgument
  • Lint/UnneededCopEnableDirective
  • Lint/UnneededRequireStatement
  • Lint/UriRegexp
  • Performance/UnneededSort
  • Performance/UriDefaultParser
  • Style/MinMax
  • Style/RedundantConditional
  • Style/TrailingBodyOnMethodDefinition
  • Style/UnpackFirst

2.2.0 (2017-12-6)

  • Style/GuardClause disabled as it forces consistency that may sacrifice readability in a cookbook.

2.1.0 (2017-08-24)

  • The Layout/EndOfLine cop now enforces a LF for line endings. This prevents users on Windows from seeing the "Carriage return character missing" error message.

2.0.0 (2017-05-31)

Security Update

RuboCop has been upgraded from 0.47.1 to 0.49.1 to resolve http://www.cvedetails.com/cve/CVE-2017-8418/. Unfortunately between these versions a large number of rules were moved from the style namespace to the layout namespace. If you previously enabled/disabled whitespace or layout related rules in your own .rubocop.yml there is a good chance you'll need to update your config.

Newly Enabled Cops:

  • Style/YodaCondition which alerts on backwards and confusing condition logic
  • Layout/EmptyLinesAroundExceptionHandlingKeywords which makes our empty line policy more consistent when using exception handling

1.4.0 (2017-05-30)

  • Our configuration of Lint/AmbiguousRegexpLiteral now ignores files in the test dir even if you run Cookstyle against a chef-repo directory instead of individual cookbook directories.
  • We now explicitly set TargetRubyVersion to 2.0, as Ruby 2.0 shipped in older Chef 12 releases.

Newly Disabled Cops:

  • BlockLength which completes Cookstyle ignoring length in cookbooks.
  • Performance/Casecmp which resulted in confusing code.

1.3.1 (2017-04-17)

Newly Disabled Cops:

  • Style/DoubleNegation which is needed in some situations to avoid Chef deprecation warnings

1.3.0 (2017-02-13)

  • Upgraded the RuboCop engine from 0.46 -> 0.47.1, but disabled all new cops. This aligns cookstyle with the RuboCop in Chefstyle and also resolves multiple bugs in RuboCop 0.46. If you previously disabled the Lint/Eval cop in your own RuboCop config you'll need to update that with the new cop name of Security/Eval.

1.2.0 (2017-01-19)

  • Change Style/NumericPredicate to use comparisons. We found that cookstyle autocorrecting code from foo == 0 to foo.zero? was breaking a lot of cookbooks. Additionally .zero? is significantly slower than just using foo == 0.

1.1.1 (2016-12-22)

  • Properly disabled the correct cop to avoid warning on InSpec matchers: Lint/AmbiguousRegexpLiteral

1.1.0 (2016-12-13)

Newly Disabled Cops:

  • All Rails cops since they don't apply to us
  • Metrics/ClassLength

1.0.1 (2016-12-12)

Newly Disabled Cops:

  • Style/TernaryParentheses

Newly Enabled Cops:

  • Lint/ShadowedException

1.0.0 (2016-12-12)

Newly Disabled Cops:

  • Metrics/CyclomaticComplexity
  • Style/NumericLiterals
  • Style/RegexpLiteral in /tests/ directory
  • Style/AsciiComments

Newly Enabled Cops:

  • Bundler/DuplicatedGem
  • Style/SpaceInsideArrayPercentLiteral
  • Style/NumericPredicate
  • Style/EmptyCaseCondition
  • Style/EachForSimpleLoop
  • Style/PreferredHashMethods
  • Lint/UnifiedInteger
  • Lint/PercentSymbolArray
  • Lint/PercentStringArray
  • Lint/EmptyWhen
  • Lint/EmptyExpression
  • Lint/DuplicateCaseCondition
  • Style/TrailingCommaInLiteral