Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[plugins] allow renaming of the downloaded/introspected schema #956

Merged

Conversation

dariuszkuc
Copy link
Collaborator

📝 Description

Simplifying Maven plugin configuration by allowing customizing the downloaded/introspected schema file name. Current logic did not allow renaming the default file (from target/schema.graphql) and required explicitly specifying the schema file for the client generation mojo. This was confusing as when download-sdl/introspect-schema mojo was used together with generate-client one we had to specify target schema always pointing to the default one. Updated logic so that specifying custom schema file name will now apply to all tasks. generate-client mojo was also updated to use default target/schema.graphql file if schema file is not specified.

In order to keep it consistent, Gradle downloadSDL and introspectSchema tasks were updated to allow specifying custom outputFiles from build.gradle.

🔗 Related Issues

Simplifying Maven plugin configuration by allowing customizing the downloaded/introspected schema file name. Current logic did not allow renaming the default file (from `target/schema.graphql`) and required explicitly specifying the schema file for the client generation mojo. This was confusing as when `download-sdl`/`introspect-schema` mojo was used together with `generate-client` one we had to specify target schema always pointing to the default one. Updated logic so that specifying custom schema file name will now apply to all tasks. `generate-client` mojo was also updated to use default `target/schema.graphql` file if schema file is not specified.

In order to keep it consistent, Gradle `downloadSDL` and `introspectSchema` tasks were updated to allow specifying custom `outputFile`s from `build.gradle`.
@dariuszkuc dariuszkuc added type: enhancement New feature or request changes: patch Changes require a patch version type: documentation Documentation or test changes module: plugin Issue affects the plugins code labels Dec 2, 2020
@smyrick smyrick added changes: minor Changes require a minor version and removed type: documentation Documentation or test changes changes: patch Changes require a patch version labels Dec 3, 2020
@smyrick smyrick merged commit b5027a8 into ExpediaGroup:master Dec 3, 2020
@dariuszkuc dariuszkuc deleted the plugin_custom_graphql_schema_name branch December 3, 2020 03:19
huehnerlady pushed a commit to huehnerlady/graphql-kotlin that referenced this pull request Apr 27, 2021
…iaGroup#956)

Simplifying Maven plugin configuration by allowing customizing the downloaded/introspected schema file name. Current logic did not allow renaming the default file (from `target/schema.graphql`) and required explicitly specifying the schema file for the client generation mojo. This was confusing as when `download-sdl`/`introspect-schema` mojo was used together with `generate-client` one we had to specify target schema always pointing to the default one. Updated logic so that specifying custom schema file name will now apply to all tasks. `generate-client` mojo was also updated to use default `target/schema.graphql` file if schema file is not specified.

In order to keep it consistent, Gradle `downloadSDL` and `introspectSchema` tasks were updated to allow specifying custom `outputFile`s from `build.gradle`.
dariuszkuc added a commit to dariuszkuc/graphql-kotlin that referenced this pull request Aug 5, 2022
…iaGroup#956)

Simplifying Maven plugin configuration by allowing customizing the downloaded/introspected schema file name. Current logic did not allow renaming the default file (from `target/schema.graphql`) and required explicitly specifying the schema file for the client generation mojo. This was confusing as when `download-sdl`/`introspect-schema` mojo was used together with `generate-client` one we had to specify target schema always pointing to the default one. Updated logic so that specifying custom schema file name will now apply to all tasks. `generate-client` mojo was also updated to use default `target/schema.graphql` file if schema file is not specified.

In order to keep it consistent, Gradle `downloadSDL` and `introspectSchema` tasks were updated to allow specifying custom `outputFile`s from `build.gradle`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changes: minor Changes require a minor version module: plugin Issue affects the plugins code type: enhancement New feature or request
Development

Successfully merging this pull request may close these issues.

None yet

2 participants