{"id":29195974,"url":"https://github.com/nomisrev/exposed-compiler-plugin","last_synced_at":"2025-07-02T05:30:33.967Z","repository":{"id":301224300,"uuid":"1003084030","full_name":"nomisRev/exposed-compiler-plugin","owner":"nomisRev","description":null,"archived":false,"fork":false,"pushed_at":"2025-06-25T18:52:48.000Z","size":398,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-25T19:37:11.393Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nomisRev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-06-16T15:42:34.000Z","updated_at":"2025-06-25T18:57:17.000Z","dependencies_parsed_at":"2025-06-25T19:48:59.538Z","dependency_job_id":null,"html_url":"https://github.com/nomisRev/exposed-compiler-plugin","commit_stats":null,"previous_names":["nomisrev/exposed-resultrow-transformer"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/nomisRev/exposed-compiler-plugin","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nomisRev%2Fexposed-compiler-plugin","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nomisRev%2Fexposed-compiler-plugin/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nomisRev%2Fexposed-compiler-plugin/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nomisRev%2Fexposed-compiler-plugin/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nomisRev","download_url":"https://codeload.github.com/nomisRev/exposed-compiler-plugin/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nomisRev%2Fexposed-compiler-plugin/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263080920,"owners_count":23410779,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-07-02T05:30:33.032Z","updated_at":"2025-07-02T05:30:33.950Z","avatar_url":"https://github.com/nomisRev.png","language":"Kotlin","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Kotlin Compiler Plugin for Exposed SQL\n\nThis is a compiler plugin for the Kotlin compiler that generates extension functions for the [Exposed SQL library](https://github.com/JetBrains/Exposed) to convert database rows to data classes.\n\n## Features\n\n- Automatically generates extension functions to convert `ResultRow` objects to data classes\n- Generates extension functions to convert `Iterable\u003cResultRow\u003e` to `Iterable\u003cYourDataClass\u003e`\n- Performs compile-time validation to ensure:\n  - Annotated classes are data classes\n  - Data class properties match table columns\n  - Table classes extend the Exposed `Table` class\n\n## Details\n\nThis project has three modules:\n- The [`:compiler-plugin`](compiler-plugin/src) module contains the compiler plugin itself.\n- The [`:plugin-annotations`](plugin-annotations/src/main/kotlin) module contains annotations which can be used in\nuser code for interacting with the compiler plugin.\n- The [`:gradle-plugin`](gradle-plugin/src) module contains a simple Gradle plugin to add the compiler plugin and\nannotation dependency to a Kotlin project. \n\nExtension point registration:\n- K2 Frontend (FIR) extensions can be registered in `SimplePluginRegistrar`.\n- All other extensions (including K1 frontend and backend) can be registered in `SimplePluginComponentRegistrar`.\n\n## Usage\n\n1. Apply the Gradle plugin to your project\n2. Annotate your data classes with `@Transformer(YourTable::class)`\n3. Use the generated extension functions: `resultRow.toYourDataClass()` and `resultRows.toYourDataClasss()`\n\n## Tests\n\nThe [Kotlin compiler test framework][test-framework] is set up for this project.\nTo create a new test, add a new `.kt` file in a [compiler-plugin/testData](compiler-plugin/testData) sub-directory:\n`testData/box` for codegen tests and `testData/diagnostics` for diagnostics tests.\nThe generated JUnit 5 test classes will be updated automatically when tests are next run.\nThey can be manually updated with the `generateTests` Gradle task as well.\nTo aid in running tests, it is recommended to install the [Kotlin Compiler DevKit][test-plugin] IntelliJ plugin,\nwhich is pre-configured in this repository.\n\n[//]: # (Links)\n\n[test-framework]: https://github.com/JetBrains/kotlin/blob/2.1.20/compiler/test-infrastructure/ReadMe.md\n[test-plugin]: https://github.com/JetBrains/kotlin-compiler-devkit\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnomisrev%2Fexposed-compiler-plugin","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnomisrev%2Fexposed-compiler-plugin","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnomisrev%2Fexposed-compiler-plugin/lists"}