activerecord_callback_lens 0.4.0 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +19 -0
- data/lib/activerecord_callback_lens/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: fdca61507b8d4d6d6a15a92622bbb38c90a42c1f95cde0d9660603e96556ce23
|
|
4
|
+
data.tar.gz: 642c585e532bd018e36ebab4471072f387a4423f0ce418153b48d9006ed5153b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: a3d3a39ed781d2f176f621a9d18d86e944da7e08b5da3cf54957f7574fcfe45f4f428156e7c69e3e5b6760e5e28ab2d822a9bddabddb5adcbb8a9cb7b4a2bcd3
|
|
7
|
+
data.tar.gz: 3d15531570d96609a40e6ae0e7f8f3ea02d9860326c01c3a643de542b3e5545fdc6ab77178221208dd195555754e140d0f68ce06f8564947dc279caf8e23d31f
|
data/README.md
CHANGED
|
@@ -148,6 +148,25 @@ graph = ActiverecordCallbackLens::Graph::GraphBuilder.build(definitions)
|
|
|
148
148
|
puts ActiverecordCallbackLens::Renderer::MermaidRenderer.render(graph)
|
|
149
149
|
```
|
|
150
150
|
|
|
151
|
+
## Example app
|
|
152
|
+
|
|
153
|
+
A runnable example Rails app lives in [`examples/blog_app/`](examples/blog_app/).
|
|
154
|
+
It defines a small blog domain (`Article`, `User`, `Comment`) with callbacks
|
|
155
|
+
covering every lifecycle event and condition style, and points its `Gemfile` at
|
|
156
|
+
this repo via `path: "../.."` so it always exercises the current gem code:
|
|
157
|
+
|
|
158
|
+
```bash
|
|
159
|
+
cd examples/blog_app
|
|
160
|
+
bundle install
|
|
161
|
+
bin/rails callback_lens:analyze MODEL=Article # Mermaid diagram
|
|
162
|
+
bin/rails callback_lens:analyze MODEL=Article EXPAND=true # expanded predicates
|
|
163
|
+
bin/rails callback_lens:html MODEL=Article OUT=reports/article.html
|
|
164
|
+
bin/callback_lens_demo # programmatic API demo
|
|
165
|
+
```
|
|
166
|
+
|
|
167
|
+
See [`examples/blog_app/README.md`](examples/blog_app/README.md) for the full
|
|
168
|
+
command matrix and expected output.
|
|
169
|
+
|
|
151
170
|
## How it works
|
|
152
171
|
|
|
153
172
|
| Layer | Class | Responsibility |
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: activerecord_callback_lens
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.4.
|
|
4
|
+
version: 0.4.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Eraxel.Dev
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-06-
|
|
11
|
+
date: 2026-06-06 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activerecord
|