You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
| targetFramework | default: `net8.0`<br/>vaults: `netstandard2.0`, `netstandard2.1`, `net8.0` |Decide on the right target framework for your generated code, meaning the generated code will be compiled to the specified runtime.<br/>For more information and help deciding on the right value, refer to the [Microsoft .NET Standard documentation](https://learn.microsoft.com/en-us/dotnet/standard/net-standard?tabs=net-standard-1-0). |
39
+
| targetFramework | default: `net8.0`<br/>values: `netstandard2.0`, `netstandard2.1`, `net8.0` |Decide on the right target framework for your generated code, meaning the generated code will be compiled to the specified runtime.<br/>For more information and help deciding on the right value, refer to the [Microsoft .NET Standard documentation](https://learn.microsoft.com/en-us/dotnet/standard/net-standard?tabs=net-standard-1-0). |
40
40
| generateCsproj | default: `true`<br/>values: `false`,`true` | This option is designed to assist you with the integration of SQLC and csharp by generating a `.csproj` file. This converts the generated output to a dynamic link library (DLL), simply a project that you can easily incorporate into your build process. |
41
41
| filePerQuery | default: `false`<br/>values: `false`,`true` | This option allows users control on which `.cs` files to generate, when false it's one file per `.sql` SQLC query file, and when true it's one file per query. |
42
42
@@ -57,33 +57,48 @@ The below examples in here are automatically tested:
57
57
<br/>
58
58
<br/>
59
59
60
-
61
-
# Local plugin development
62
-
## Prerequisites
60
+
# Contributing
61
+
## Local plugin development
62
+
### Prerequisites
63
63
make sure that the following applications are installed and exposed in your path
64
64
65
65
Follow the instructions in each of these:
66
66
* Dotnet CLI - [Dotnet Installation](https://github.com/dotnet/sdk) - use version `.NET 8.0 (latest)`
* WASM related - [WASM libs](https://www.strathweb.com/2023/09/dotnet-wasi-applications-in-net-8-0/)
69
69
70
-
## Protobuf
70
+
### Protobuf
71
71
SQLC protobuf are defined in sqlc-dev/sqlc repository.
72
72
Generating C# code from protocol buffer files:
73
73
```
74
74
make protobuf-generate
75
75
```
76
76
77
-
## Generating code
77
+
### Generating code
78
78
SQLC utilizes our process / WASM plugin to generate code
79
79
```
80
80
make sqlc-generate-process
81
81
make sqlc-generate-wasm
82
82
```
83
83
84
-
## Testing generated code
84
+
### Testing generated code
85
85
Testing the SQLC generated code via a predefined flow:
86
86
```
87
87
make test-process-plugin
88
88
make test-wasm-plugin
89
89
```
90
+
91
+
## Release flow
92
+
The release flow in this repo follows the semver conventions, building tag as `v[major].[minor].[patch]`.
93
+
94
+
* In order to create a release you need to add `[release]` somewhere in your commit message when merging to master
95
+
96
+
### Version bumping (build on tags)
97
+
**By default, the release script will bump the patch version.**, by adding `[release]` to your commit message the release script will create a new tag with `v[major].[minor].[patch]+1`.
98
+
* Bump `minor` version by adding `[minor]` to your commit message resulting in a new tag with `v[major].[minor]+1.0`<br/>
99
+
* Bump `major` version by adding `[major]` to your commit message resulting in a new tag with `v[major]+1.0.0`
100
+
101
+
### Release structure
102
+
The new created tag will create a draft release with it, in the release there will be the wasm plugin embedded in the release.<br/>
103
+
> All we have left to do now is to add the changelog and publish the draft
0 commit comments