Open brandondrew opened 1 month ago
@brandondrew hi there -- thanks for using the gem and adding an issue!
The things you're asking for make sense, although I'm not if it's currently possible to make it configurable as you'd want it. We'd need to add additional options, see [1] for an example, or add templating-esque functionality so we don't break the current existing behavior used by many. If you have any ideas there that would be great, or if you want to start on a PR, I'd be more than happy to assist there.
For the 3rd ask about separate foreign keys, just to clarify, is the first output (has , foreign key
) taken from your Rails app?
@drwl
Yes, this was output from a real Rails app that I have access to and was using AnnotateRB in, as a way to help me learn my way around:
# Foreign Keys
#
# app_gem_id (app_gem_id => app_gems.id)
# app_id (app_id => apps.id)
I'm not sure if that answers your question. I may not have understood what you were asking.
Yes, I'd be open to considering opening a PR.
For starters I'm hacking the results I want by monkey-patching in my app with an initializer. Hopefully (if I find the time) that will work its way into my fork, and result in a PR. I've added the first two features so far through monkey-patching.
I would love to be able to customize a few more things about the annotations.
# Schema version: 20240510213625
, what if it could be displayed as below?So instead of this:
it would be possible to have this:
If any of these things are already possible, I wasn't able to figure out how to do them.