hershel-theodore-layton/sql-queryf-codegen

Customize your queryf DSL to your heart's content

Installs: 5

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 0

Forks: 0

Open Issues: 0

Language:Hack

pkg:composer/hershel-theodore-layton/sql-queryf-codegen

v0.2.0 2025-10-11 13:33 UTC

This package is auto-updated.

Last update: 2025-10-11 14:17:43 UTC


README

Customize your queryf DSL to your heart's content.

This package contains some presets for you own sql-queryf engines. The basic HH\\Lib\\SQL\\Query-like engine can be generated with vendor/bin/sql-queryf --vanilla. If you want to see what's possible, use --extended instead of --vanilla. If you want to customize, see HTL\\SqlQueryfCodegen\\Presets. A usage example can be found in vendor/hershel-theodore-layton/sql-queryf-codegen/bin/sql-queryf.hack.

$your_engine = PrintfStateMachine\Factory::create(
  PrintfStateMachine\hack_type('Sql'),
  SqlQueryfCodegen\StaticTypeAssertionGenerator::create(dict[]),
)
  |> $$->apply(SqlQueryfCodegen\Presets::vanilla<>)
  |> SqlQueryfCodegen\codegen($$, PrintfStateMachine\ENGINE_TEMPLATE);