Skip to content

Commit 4bf521e

Browse files
* validate Dockerfile is up to date in github action (#45)
* rename SqlcGenCsharpWasm & SqlcGenCsharpProcess projects
1 parent e614884 commit 4bf521e

File tree

14 files changed

+24
-17
lines changed

14 files changed

+24
-17
lines changed

.env

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
SOURCE_WASM_FILE_UBUNTU="SqlcGenCsharpWasm/obj/release/net8.0/wasi-wasm/wasm/for-publish/SqlcGenCsharpWasm.wasm"
2-
SOURCE_WASM_FILE="SqlcGenCsharpWasm/bin/Release/net8.0/wasi-wasm/AppBundle/SqlcGenCsharpWasm.wasm"
1+
SOURCE_WASM_FILE_UBUNTU="WasmRunner/obj/release/net8.0/wasi-wasm/wasm/for-publish/WasmRunner.wasm"
2+
SOURCE_WASM_FILE="WasmRunner/bin/Release/net8.0/wasi-wasm/AppBundle/WasmRunner.wasm"
33
TESTS_CONTAINER_NAME="plugin-tests"
44
MYSQL_CONNECTION_STRING="server=mysqldb;database=tests;user=root"
55
POSTGRES_CONNECTION_STRING="host=postgresdb;database=tests;username=user;password=pass"

.github/workflows/main.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,17 +77,22 @@ jobs:
7777

7878
- name: Dotnet Wasm Publish
7979
run: |
80-
WASI_SDK_PATH="$(pwd)/wasi-sdk-22.0" dotnet publish SqlcGenCsharpWasm -c release
80+
WASI_SDK_PATH="$(pwd)/wasi-sdk-22.0" dotnet publish WasmRunner -c release
8181
./scripts/wasm/copy_to_dist.sh
8282
./scripts/wasm/update_sha.sh
8383
8484
- uses: sqlc-dev/setup-sqlc@v4
8585
with:
8686
sqlc-version: '1.25.0'
8787

88-
- name: Verify pushed generated code is up to date
88+
- name: Verify pushed generated code is synced
8989
run: sqlc -f sqlc.wasm.yaml diff
9090

91+
- name: Verify pushed Dockerfile is synced
92+
run: |
93+
./scripts/generate_dockerfile.sh /tmp/Dockerfile
94+
diff /tmp/Dockerfile Dockerfile
95+
9196
- name: Sqlc generate using Wasm plugin
9297
run: sqlc -f sqlc.wasm.yaml generate
9398

Dockerfile

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ COPY GeneratedProtobuf/*.csproj ./GeneratedProtobuf/
1111
COPY MySqlConnectorExample/*.csproj ./MySqlConnectorExample/
1212
COPY NpgsqlExample/*.csproj ./NpgsqlExample/
1313
COPY PluginOptions/*.csproj ./PluginOptions/
14+
COPY ProcessRunner/*.csproj ./ProcessRunner/
1415
COPY SqlcGenCsharp/*.csproj ./SqlcGenCsharp/
15-
COPY SqlcGenCsharpProcess/*.csproj ./SqlcGenCsharpProcess/
1616
COPY SqlcGenCsharpTests/*.csproj ./SqlcGenCsharpTests/
17-
COPY SqlcGenCsharpWasm/*.csproj ./SqlcGenCsharpWasm/
17+
COPY WasmRunner/*.csproj ./WasmRunner/
1818

1919
COPY CodeGenerator/ ./CodeGenerator/
2020
COPY Drivers/ ./Drivers/
@@ -23,9 +23,9 @@ COPY GeneratedProtobuf/ ./GeneratedProtobuf/
2323
COPY MySqlConnectorExample/ ./MySqlConnectorExample/
2424
COPY NpgsqlExample/ ./NpgsqlExample/
2525
COPY PluginOptions/ ./PluginOptions/
26+
COPY ProcessRunner/ ./ProcessRunner/
2627
COPY SqlcGenCsharp/ ./SqlcGenCsharp/
27-
COPY SqlcGenCsharpProcess/ ./SqlcGenCsharpProcess/
2828
COPY SqlcGenCsharpTests/ ./SqlcGenCsharpTests/
29-
COPY SqlcGenCsharpWasm/ ./SqlcGenCsharpWasm/
29+
COPY WasmRunner/ ./WasmRunner/
3030

3131
RUN dotnet restore

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ dotnet-format:
88
--exclude NpgsqlExample
99

1010
dockerfile-generate:
11-
./scripts/generate_dockerfile.sh
11+
./scripts/generate_dockerfile.sh Dockerfile
1212

1313
protobuf-generate:
1414
./scripts/generate_protobuf.sh
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)