You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#795 highlighted some issues with template resolution. The fix in #796 addresses the issue sufficiently for adding changes to multiple engines at once, but only if not using a custom template. The current design limits custom templates to a single engine -- a limitation dating from when add supported only one engine at a time (changed in way back in 0c7237c).
So do some re-thinking and re-organization of templates in order to better support both multiple engines and custom templates for multiple engines.
Which is fine for a single template for each engine. Say we wanted to add a custom change, named create_table, with separate templates for the pg and sqlite engines. Currently it requires a structure like this:
But what engine does it apply to? In order to support the same template for multiple engines, add support for engine-specific subdirectories, so we can do this, instead:
The defaults for each engine remain as they are, as do custom templates that can be the same across engines (or are only ever used for one). But adding this level allows for more customization.
The text was updated successfully, but these errors were encountered:
#795 highlighted some issues with template resolution. The fix in #796 addresses the issue sufficiently for adding changes to multiple engines at once, but only if not using a custom template. The current design limits custom templates to a single engine -- a limitation dating from when
add
supported only one engine at a time (changed in way back in 0c7237c).So do some re-thinking and re-organization of templates in order to better support both multiple engines and custom templates for multiple engines.
Here's what it looks like today:
Which is fine for a single template for each engine. Say we wanted to add a custom change, named
create_table
, with separate templates for thepg
andsqlite
engines. Currently it requires a structure like this:But what engine does it apply to? In order to support the same template for multiple engines, add support for engine-specific subdirectories, so we can do this, instead:
The defaults for each engine remain as they are, as do custom templates that can be the same across engines (or are only ever used for one). But adding this level allows for more customization.
The text was updated successfully, but these errors were encountered: