Releases: Betterment/uncruft
Releases · Betterment/uncruft
v0.7.1: fixing Rails initialization to avoid STDERR output
v0.7.0 - git-sourced gem support
v0.6.2
What's Changed
- Fix: Add
Rails.application.deprecators
only on Rails 7.1+ by @Irving-Betterment in #42
New Contributors
- @Irving-Betterment made their first contribution in #42
Full Changelog: v0.6.1...v0.6.2
v0.6.1
v0.5.0
v0.4.0
v0.3.1
A new `deprecate_attribute` helper!
If you would like to deprecate an attribute by applying a ActiveSupport::Deprecation
warning on the deprecated attribute's getters and setters then look no further, we have a tool for that! Simply include Uncruft::Deprecatable
in your class, identify the attribute you would like deprecated and provide a message you would like applied to the deprecation warning.
class Customer
include Uncruft::Deprecatable
attr_accessor :first_name
def initialize(first_name)
@first_name = first_name
end
deprecate_attribute(:first_name,
message: "Please stop using first_name it is deprecated, please use legal_first_name instead!")
end
Within the Uncruft::Deprecatable
module there is also a .deprecate_method
method that can be used to apply a deprecation warning to an identified method, much like the deprecate_attribute
method described above.
From there you can use Uncruft's deprecation recording tools to generate ingorefiles and manage your deprecation backlog in an organized manner.