Skip to content

chore: use more reasonable folders for generated managed Scala files#610

Merged
johanandren merged 2 commits intolightbend:mainfrom
jrudolph:fix-generation-folders
Oct 12, 2021
Merged

chore: use more reasonable folders for generated managed Scala files#610
johanandren merged 2 commits intolightbend:mainfrom
jrudolph:fix-generation-folders

Conversation

@jrudolph
Copy link
Copy Markdown
Contributor

No description provided.

@jrudolph jrudolph requested a review from raboof October 12, 2021 14:19
@jrudolph jrudolph force-pushed the fix-generation-folders branch from ee6d77f to 737347a Compare October 12, 2021 14:20
"com.akkaserverless" %% "akkaserverless-scala-sdk-testkit" % AkkaServerlessSdkVersion % Test),
Compile / PB.targets +=
gen(
akkaGrpcCodeGeneratorSettings.value :+ AkkaserverlessGenerator.enableDebug) -> (Compile / sourceManaged).value / "akkaserverless",
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sourceManaged is already target/scala-2.13/src_managed/main/ so if we add another directory it will show as a package in IDEs.

Compile / temporaryUnmanagedDirectory := (Compile / baseDirectory).value / "target" / "akkaserverless-unmanaged",
Test / temporaryUnmanagedDirectory := (Test / baseDirectory).value / "target" / "akkaserverless-unmanaged-test",
akkaGrpcCodeGeneratorSettings.value :+ AkkaserverlessGenerator.enableDebug) -> (Compile / sourceManaged).value,
Compile / temporaryUnmanagedDirectory := (Compile / crossTarget).value / "akkaserverless-unmanaged",
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Avoids hardcoding target in cases target has been redefined (which I use often to create more specific targets for different branches or JVM versions etc).

Copy link
Copy Markdown
Contributor

@raboof raboof left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good, the scripted test still checks for them in the old location though

@jrudolph
Copy link
Copy Markdown
Contributor Author

Good, the scripted test still checks for them in the old location though

Yes, just fixed that as well.

@johanandren johanandren merged commit 4db171b into lightbend:main Oct 12, 2021
@jrudolph jrudolph deleted the fix-generation-folders branch October 12, 2021 15:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants