Skip to content

Commit

Permalink
Use Version 2 config for sqlc.yaml (#3861)
Browse files Browse the repository at this point in the history
This makes it easier to reuse examples from the documentation.
  • Loading branch information
dmjb authored Jul 11, 2024
1 parent a441c32 commit b80f3aa
Showing 1 changed file with 16 additions and 14 deletions.
30 changes: 16 additions & 14 deletions sqlc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,19 +13,21 @@
# See the License for the specific language governing permissions and
# limitations under the License.

version: "1"
packages:
- name: "db"
path: "./internal/db/"
version: "2"
sql:
- schema: "./database/migrations/"
queries: "./database/query/"
schema: "./database/migrations/"
engine: "postgresql"
emit_json_tags: true
emit_prepared_queries: false
emit_interface: true
emit_exact_table_names: false
emit_empty_slices: true
overrides:
- db_type: profile_selector
go_type:
type: "ProfileSelector"
gen:
go:
out: "./internal/db/"
package: "db"
emit_json_tags: true
emit_prepared_queries: false
emit_interface: true
emit_exact_table_names: false
emit_empty_slices: true
overrides:
- db_type: profile_selector
go_type:
type: "ProfileSelector"

0 comments on commit b80f3aa

Please sign in to comment.