Skip to content

Commit 0667d4c

Browse files
committed
feat(typescript): ✨ switch to sqlc-gen-typescript-native
Point the language links to the native plugin and mark SQLite support as beta. Remove the old plugin name from historical changelog entries while keeping their original meaning. Enable TypeScript CI against v0.3.0, pinned by commit. Build sqlc from the current checkout and run the plugin's generation, type and runtime tests, then check the generated Deno SQLite example with sqlc diff.
1 parent 23e357a commit 0667d4c

4 files changed

Lines changed: 36 additions & 12 deletions

File tree

‎.github/workflows/ci-typescript.yml‎

Lines changed: 32 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,21 +10,45 @@ on:
1010
- 'docs/**'
1111
jobs:
1212
build:
13-
if: false
1413
name: test
1514
runs-on: ubuntu-latest
15+
timeout-minutes: 25
1616
steps:
1717
- uses: actions/checkout@v7
1818
- uses: actions/setup-go@v7
1919
with:
2020
go-version: '1.26.5'
21-
- name: install ./...
22-
run: go install ./...
21+
- name: Build sqlc from this checkout
22+
run: |
23+
go build -o "$RUNNER_TEMP/sqlc" ./cmd/sqlc
24+
echo "SQLC=$RUNNER_TEMP/sqlc" >> "$GITHUB_ENV"
2325
- uses: actions/checkout@v7
2426
with:
25-
repository: sqlc-dev/sqlc-gen-typescript
27+
repository: bonakodo/sqlc-gen-typescript-native
2628
path: typescript
27-
# v0.1.3
28-
ref: daaf539092421adc15f6c3164279a3470716b560
29-
- run: sqlc diff
30-
working-directory: typescript/examples
29+
# v0.3.0
30+
ref: 8eac5960f4ccffac60cccdf73d4a884998e77acf
31+
persist-credentials: false
32+
- uses: denoland/setup-deno@v2
33+
with:
34+
deno-version: "v2.9.6"
35+
- uses: actions/setup-node@v7
36+
with:
37+
node-version: "26.8.1"
38+
cache: npm
39+
cache-dependency-path: typescript/tests/integration/package-lock.json
40+
- name: Install SQLite shared library
41+
run: |
42+
sudo apt-get update
43+
sudo apt-get install -y libsqlite3-0
44+
sqlite_library=$(dpkg -L libsqlite3-0 | sed -n '/\/libsqlite3\.so\.0$/p')
45+
test -f "$sqlite_library"
46+
echo "DENO_SQLITE_PATH=$sqlite_library" >> "$GITHUB_ENV"
47+
- run: deno task tools
48+
working-directory: typescript
49+
- name: Test generation and driver runtimes
50+
run: deno task integration
51+
working-directory: typescript
52+
- name: Check generated example
53+
run: '"$SQLC" diff'
54+
working-directory: typescript/examples/deno-sqlite

‎README.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ Check out [an interactive example](https://play.sqlc.dev/) to see it in action,
2525
- [sqlc-gen-go](https://github.com/sqlc-dev/sqlc-gen-go)
2626
- [sqlc-gen-kotlin](https://github.com/sqlc-dev/sqlc-gen-kotlin)
2727
- [sqlc-gen-python](https://github.com/sqlc-dev/sqlc-gen-python)
28-
- [sqlc-gen-typescript](https://github.com/sqlc-dev/sqlc-gen-typescript)
28+
- [sqlc-gen-typescript-native](https://github.com/bonakodo/sqlc-gen-typescript-native)
2929

3030
Additional languages can be added via [plugins](https://docs.sqlc.dev/en/latest/reference/language-support.html#community-language-support).
3131

‎docs/reference/changelog.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -417,7 +417,7 @@ If you run into any issues with the updated dependencies, please [open an issue]
417417

418418
- Add name to query set configuration (#3011)
419419
- Add a sidebar link for `push`, add Go plugin link (#3023)
420-
- Update banner for sqlc-gen-typescript (#3036)
420+
- Update banner for the TypeScript plugin (#3036)
421421
- Add strict_order_by in doc (#3044)
422422
- Re-order the migration tools list (#3064)
423423

@@ -434,7 +434,7 @@ If you run into any issues with the updated dependencies, please [open an issue]
434434

435435
- (endtoend) Enable for more build targets (#3041)
436436
- (endtoend) Run MySQL and PostgreSQL locally on the runner (#3095)
437-
- (typescript) Test against sqlc-gen-typescript (#3046)
437+
- (typescript) Test against the TypeScript plugin (#3046)
438438
- Add tests for omit_sqlc_version (#3020)
439439
- Split schema and query for test (#3094)
440440

‎docs/reference/language-support.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
| Go | [sqlc-gen-go](https://github.com/sqlc-dev/sqlc-gen-go) | Stable | Stable | Beta |
77
| Kotlin | [sqlc-gen-kotlin](https://github.com/sqlc-dev/sqlc-gen-kotlin) | Beta | Beta | Not implemented |
88
| Python | [sqlc-gen-python](https://github.com/sqlc-dev/sqlc-gen-python) | Beta | Beta | Not implemented |
9-
| TypeScript | [sqlc-gen-typescript](https://github.com/sqlc-dev/sqlc-gen-typescript) | Beta | Beta | Not implemented |
9+
| TypeScript | [sqlc-gen-typescript-native](https://github.com/bonakodo/sqlc-gen-typescript-native) | Beta | Beta | Beta |
1010

1111
## Community language support
1212

0 commit comments

Comments
 (0)