Chef/Modernize/PropertyWithNameAttribute
The Cookstyle cops department: Chef/Modernize
Enabled by default | Supports autocorrection | Target Chef Version |
---|---|---|
Enabled | Yes | All Versions |
When using properties in a custom resource you should use name_property not the legacy name_attribute from the days of attributes
Examples
incorrect
property :bob, String, name_attribute: true
correct
property :bob, String, name_property: true
Configurable attributes
Name | Default value | Configurable values |
---|---|---|
Version Added | 5.1.0 | String |
Include |
| Array |