-
-
Notifications
You must be signed in to change notification settings - Fork 246
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
split codegen plugin into library and sbt modules #327
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think some code can be moved out of CodegenPlugin
into an object that will live in caliban-codegen
and is not specific to the sbt part: namely getSchema
and generate
methods.
build.sbt
Outdated
@@ -102,15 +103,28 @@ lazy val codegen = project | |||
.settings(name := "caliban-codegen") | |||
.settings(commonSettings) | |||
.settings( | |||
sbtPlugin := true, | |||
crossScalaVersions := Seq("2.12.10"), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line can be removed (only needed for the plugin).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You missed this one (I meant crossScalaVersions
should be removed, this was to force the sbt plugin to be built on 2.12 only but a regular module can be cross-published.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I missed that one. Updated
I moved the two methods into a new object in the codegen module. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Thanks!
Closes #326