{
  "name": "compat_resource",
  "version": "12.7.3",
  "description": "Chef 12.5 Resources, For Chef 12.1-12.4",
  "long_description": "# compat_resource cookbook\n\n[![Build Status](https://travis-ci.org/chef-cookbooks/compat_resource.svg?branch=master)](https://travis-ci.org/chef-cookbooks/compat_resource)\n[![Cookbook Version](https://img.shields.io/cookbook/v/compat_resource.svg)](https://supermarket.chef.io/cookbooks/compat_resource)\n\n\nThis cookbook brings the custom resource syntax from Chef 12.5 to earlier Chef 12.X releases.\n\n## Converting cookbooks from the old resource model to the new\n\n### Boilerplate\n\n1. Depend on compat_resource\n   - Descend resources from ChefCompat::Resource\n   - Set resource_name in the class instead of the constructor\n2. Convert Attributes to Properties\n   - Rename attribute -> property\n   - Move set_or_return -> property\n   - Take kind_of/equal_to/regexes and make them types\n   - Use true/false/nil instead of TrueClass/FalseClass/NilClass\n   - Remove default: nil (it's the default)\n3. Convert Top-Level Providers to Actions\n   - Create any resources that don't already exist (for example in\n     multi-provider cases) and descend from the base resource\n   - Remove allowed_actions / @actions\n   - @action -> default_action\n   - Move `provides` and `action :x` to the resource\n   - Remove use_inline_resources and def whyrun_safe?\n   - Move other methods to `action_class.class_eval do`\n\nNow you have everything in a resource, are using properties, and have gotten rid\nof a bunch of boilerplate. Of course, this is just getting it *moved*. Now you\ncan start to really use the new features. And if you're making resources for\nthe first time, congrats--you probably didn't have to do very much of this :)\n\n### Advanced Concepts\n\n1. Resource Inheritance\n2. Resources That Are Different On Each OS?\n3. Coercion: Handling User Input\n4. Lazy Defaults\n5. Using Load Current Resource\n6. Using Converge If Changed\n7. Defaults Are For Creation\n8. Shared types: using a type multiple places\n\n\n\nRequirements\n------------\n#### Platforms\n- All platforms supported by Chef\n\n#### Chef\n- Chef 12.0+\n\n#### Cookbooks\n- none\n\n\n## Usage\n\nTo use this cookbook, put `depends 'compat_resource'` in the metadata.rb of your cookbook. Once this is done, you can use all the new custom resource features to define resources. It Just Works.\n\nFor example, if you create resources/myresource.rb, myresource can use `property`, `load_current_value` and `action` (no need to create a provider). If you want to create Resource classes directly, extend from `ChefCompat::Resource` instead of `Chef::Resource`. Properties, current value loading, converge_if_changed, and resource_name will all function the same across versions.\n\n## Custom Resources?\n\nCurious about how to use custom resources? Here are the 12.5 docs:\n\n- Docs: https://docs.chef.io/custom_resources.html\n- Slides: https://docs.chef.io/decks/custom_resources.html\n\n\n##License & Authors\n\n**Author:** John Keiser (<jkeiser@chef.io>)\n\n**Copyright:** 2015, Chef Software, Inc.\n```\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n",
  "maintainer": "John Keiser",
  "maintainer_email": "jkeiser@chef.io",
  "license": "Apache 2.0",
  "platforms": {
  },
  "dependencies": {
  },
  "recommendations": {
  },
  "suggestions": {
  },
  "conflicting": {
  },
  "providing": {
  },
  "replacing": {
  },
  "attributes": {
  },
  "groupings": {
  },
  "recipes": {
  }
}