Skip to content

v0.6.0

Choose a tag to compare

@j4k4 j4k4 released this 24 Mar 11:08
· 14 commits to main since this release

Highlights

  • Split repository metadata into dedicated sqlr struct tags, making entity definitions clearer and keeping column mapping in db tags.
  • Added schema-level association sync defaults and aligned sync: tag syntax with sqlh, including support for nested sync:delete defaults.
  • Added Create support for omitting all associations in a single call, and made owned-association cleanup cascade by default during deletes.

Improvements

  • Made many-to-many updates link-only by default to avoid unintended row mutations in related tables.
  • Fixed has-one updates so cleared relations are persisted correctly.
  • Updated prepared statement handling to work with sqlc v0.3.0 and the newer client API.
  • Tightened schema parsing by rejecting unexported fields with sqlr metadata.

API cleanup

  • sqlr metadata is now expected in sqlr tags instead of being mixed into db tags.
  • sqlr tag options must now be separated with semicolons.
  • Association sync behavior has been normalized around the sync: option model, which may require tag updates in existing entities.

Internal changes

  • Simplified schema parsing helpers and cleaned up lint issues.
  • Expanded repository and schema coverage around association lifecycle, delete behavior, preload handling, and prepared statements.
  • Updated the bundled sqlc dependency to v0.3.0.