Chef/Deprecations/Ruby27KeywordArgumentWarnings
The Cookstyle cops department: Chef/Deprecations
| Enabled by default | Supports autocorrection | Target Chef Version |
|---|---|---|
| Enabled | Yes | All Versions |
Pass options to shell_out helpers without the brackets to avoid Ruby 2.7 deprecation warnings.
Examples
incorrect
shell_out!('hostnamectl status', { returns: [0, 1] })
shell_out('hostnamectl status', { returns: [0, 1] })
correct
shell_out!('hostnamectl status', returns: [0, 1])
shell_out('hostnamectl status', returns: [0, 1])
Configurable attributes
| Name | Default value | Configurable values |
|---|---|---|
| Version Added | 6.5.0 | String |
| Include | Array |