feat: Add comprehensive documentation for @pgsql/transform package#197
Merged
Conversation
Contributor
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
- Add transform package to main README packages table - Document core use case: single source of truth deparser - Explain multi-version AST transformation (PG13→PG17) - Highlight key limitation: only PG17-parseable SQL supported - Add comprehensive usage examples and architecture overview - Fix packages/transform/README.md with correct package documentation - Include installation, quick start, and integration examples Co-Authored-By: Dan Lynch <pyramation@gmail.com>
- Remove detailed transform documentation from main README - Keep only the packages table entry for @pgsql/transform - Detailed documentation remains in packages/transform/README.md - Main README now has concise highlight as requested Co-Authored-By: Dan Lynch <pyramation@gmail.com>
e2ecdf5 to
35aa7c9
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
feat: Add comprehensive documentation for @pgsql/transform package
Summary
This PR adds comprehensive documentation for the
@pgsql/transformpackage, which enables transformation of PostgreSQL ASTs between different PostgreSQL versions (13→17). The package serves as a crucial component for building a single source of truth deparser that maintains backward compatibility with legacy SQL code.Key changes:
packages/transform/README.md(was incorrectly describing @pgsql/types instead of transform functionality)Note: Initially added extensive documentation to main README, but per feedback, moved detailed content to package README and kept only brief highlight in main README.
Review & Testing Checklist for Human
🔴 Critical (4 items)
npm install @pgsql/transformworks or determine the correct installation methodASTTransformer,PG13ToPG17Transformeractually exist and have the documented methods🟡 Important (2 items)
Recommended test plan:
Diagram
%%{ init : { "theme" : "default" }}%% graph TD MainREADME["README.md"]:::minor-edit TransformREADME["packages/transform/README.md"]:::major-edit TransformSrc["packages/transform/src/"]:::context MultiVersionTransformer["src/multi-version-transformer.ts"]:::context DirectTransformers["src/transformers-direct/"]:::context V13ToV14["src/transformers/v13-to-v14.ts"]:::context MainREADME --> |"Added packages table entry"| TransformPackage["@pgsql/transform package"] TransformREADME --> |"Complete rewrite with correct docs"| TransformPackage TransformSrc --> MultiVersionTransformer TransformSrc --> DirectTransformers TransformSrc --> V13ToV14 TransformPackage --> |"Documents"| MultiVersionTransformer TransformPackage --> |"Documents"| DirectTransformers subgraph Legend L1["Major Edit"]:::major-edit L2["Minor Edit"]:::minor-edit L3["Context/No Edit"]:::context end classDef major-edit fill:#90EE90 classDef minor-edit fill:#87CEEB classDef context fill:#FFFFFFNotes