Releases: crystal-garage/lustra
Releases · crystal-garage/lustra
v0.12.0
In memory of my cat Sviatoslav. RIP 💔😿
26.04.2023 - 13.10.2025
What's Changed
- add update_all (bypasses validations and callbacks) by @mamantoha in #47
- add find_by by @mamantoha in #48
- add find by ids by @mamantoha in #49
- add increment/decrement by @mamantoha in #50
- update column(s) directly in the database without running validations… by @mamantoha in #51
- Touch instance by @mamantoha in #52
- implement delete and destroy (with callbacks) by @mamantoha in #53
- add default scope for models by @mamantoha in #54
- Attribute change tracking by @mamantoha in #55
- shortcut for getting array of primary keys by @mamantoha in #56
- Postgres explain by @mamantoha in #57
Additions:
- ✅
update_all- Bulk updates without loading models - ✅
find_by/find_by!- Convenient finders - ✅
find([ids])- Multiple ID lookup - ✅
increment!/decrement!- Atomic counter updates - ✅
update_column/update_columns- Direct updates without validations/callbacks - ✅
touch- Update timestamps without validations/callbacks - ✅
destroy/destroy_all- Rails-compatible deletion with callbacks - ✅
:destroycallbacks - Renamed from:deletefor Rails compatibility - ✅
default_scope- Automatically apply filters to all queries (soft deletes, multi-tenancy) - ✅
query.unscoped- Bypass default_scope when needed - ✅ Attribute change tracking -
column.change,changes,changedfor auditing - ✅
ids- Convenient shortcut for getting array of primary keys - ✅
explain/explain_analyze- PostgreSQL query performance analysis
Breaking Changes:
deletenow skips callbacks (fast deletion)destroytriggers callbacks (safe deletion)- Callback event renamed:
:delete→:destroy - Use
before(:destroy)andafter(:destroy)instead ofbefore(:delete)andafter(:delete)
Full Changelog: v0.11.0...v0.12.0
v0.11.0
v0.10.1
v0.10.0
What's Changed
- Handle append_operation for has_many through relationships by @mamantoha in #42
- prevent duplicate associations by @mamantoha in #43
- Join a relation using association name by @mamantoha in #44
- autosave functionality by @mamantoha in #41
Full Changelog: v0.9.0...v0.10.0
v0.9.0
What's Changed
- test callbacks by @mamantoha in #34
- remove Kemal cli generator by @mamantoha in #35
- Add queries by @mamantoha in #36
- Counter cache by @mamantoha in #37
- add specs for constructs join SQL by @mamantoha in #39
- improve supported features by @mamantoha in #38
- Clear -> Lustra by @mamantoha in #40
Full Changelog: v0.8.24...v0.9.0
v0.8.24
What's Changed
- Bump actions/checkout from 4 to 5 by @dependabot[bot] in #32
- implement touch for belongs_to association by @mamantoha in #33
Full Changelog: v0.8.23...v0.8.24
v0.8.23
Full Changelog: v0.8.22...v0.8.23
v0.8.22
Full Changelog: v0.8.21...v0.8.22
v0.8.21
What's Changed
- Use
do...endinstead of curly brackets for multi-line blocks by @mamantoha in #28 - cosmetic changes by @mamantoha in #29
- fix Collection#each method by @mamantoha in #30
Full Changelog: v0.8.20...v0.8.21
v0.8.20
What's Changed
- use crystal-pg 0.29.0 by @mamantoha in #26
- Use
::sleep(Time::Span)instead by @mamantoha in #27
Full Changelog: v0.8.19...v0.8.20