Releases: esassoc/SqlCodeGen
Releases · esassoc/SqlCodeGen
v1.0.8: Fix duplicate enum member names by appending parenthetical content
"Word (DOCX)" now becomes "WordDOCX" instead of "Word" to preserve uniqueness when multiple entries have the same base name. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v1.0.7: Fix: Sanitize enum names with spaces, parentheses, and hyphens
TypeScript identifiers must be valid. Now handles: - Parentheses and contents removed: "Word (DOCX)" -> "Word" - Spaces removed: "Land Bank Acquisition" -> "LandBankAcquisition" - Hyphens replaced with underscores: "X-PNG" -> "X_PNG" - Leading digits prefixed with underscore: "1a" -> "_1a" Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v1.0.6: Fix: Prefix enum names starting with digits with underscore
TypeScript identifiers cannot start with a digit. Names like '1a' or '2' are now transformed to '_1a' and '_2' to be valid enum members. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v1.0.5: Fix: Strip N prefix from SQL Unicode string literals (N'string')
SQL Server uses N'string' syntax for Unicode string literals. The parser was including the N as part of the string value. Now when we see a quote preceded by N, we strip the N before capturing the string content. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v1.0.4
Fix: Rename $input parameter to $text in ConvertTo-KebabCase $input is a reserved automatic variable in PowerShell that represents pipeline input. Using it as a parameter name shadows the actual argument, causing the function to always receive an empty string. This fix renames the parameter to $text to avoid the conflict. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v1.0.3: Fix trailing backslash causing PowerShell escape issues
When MSBuild passes paths like `"C:\path\"` to PowerShell, the
trailing backslash before the quote is interpreted as an escape,
breaking parameter parsing.
Fixed by using TrimEnd('\') on the directory paths.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v1.0.2: Fix PowerShell parser for parentheses inside quoted strings
The regex-based row extraction pattern `\(([^)]+)\)` failed when VALUES contained strings with parentheses like `'Word (DOCX)'`. Replaced with character-by-character parsing that tracks: - Whether we're inside a quoted string - Parenthesis depth for balanced matching Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v1.0.1: Fix TypeScript generation MSBuild target batching issue
The previous target used %(ItemName.Metadata) for two different item types in the same Exec command, which caused MSBuild batching issues and resulted in empty paths. Fixed by capturing item paths into properties using the transform syntax @(ItemName->'%(FullPath)') before using them in the Exec. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
v1.0.0: Initial commit: SqlCodeGen Source Generator
A Roslyn Source Generator that generates C# EF Core binding classes and TypeScript enums from SQL schema files. Features: - No database connection required - reads SQL files directly - C# generation: Entity bindings, PrimaryKey wrappers, navigation properties - TypeScript generation: Enums, lookup arrays, dropdown options - Incremental generation - only regenerates when SQL files change - Git history preservation - writes to disk with same filenames Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>