-
Notifications
You must be signed in to change notification settings - Fork 311
[examples] Migrate examples to composite builds #810
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
Merged
EugeneTheDev
merged 22 commits into
develop
from
eugenethedev/examples-composite-build-demo
Sep 23, 2025
Merged
[examples] Migrate examples to composite builds #810
EugeneTheDev
merged 22 commits into
develop
from
eugenethedev/examples-composite-build-demo
Sep 23, 2025
Conversation
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
Qodana for JVM915 new problems were found
@@ Code coverage @@
+ 68% total lines covered
12138 lines analyzed, 8272 lines covered
# Calculated according to the filters of your coverage tool☁️ View the detailed Qodana report Contact Qodana teamContact us at [email protected]
|
…an be leveraged to make examples more self-sustained while still depending on the actual Koog sources
…te build to root project
3662801 to
2230f20
Compare
b71bc0d to
3c5b193
Compare
kpavlov
approved these changes
Sep 23, 2025
Contributor
kpavlov
left a comment
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.
Thank you, @EugeneTheDev 🎉
15 tasks
karloti
pushed a commit
to karloti/koog
that referenced
this pull request
Sep 25, 2025
I've updated this PR to actually migrate `examples` to a separate `simple-examples` Gradle project in `examples` directory, that depends on the root Koog project via composite build. `examples` is not a module in Koog anymore, just a directory with example projects. After some experiments, I decided not to migrate other example projects, such as Demo Compose App, to composite build approach, at least for now. I believe it's more beneficial to keep these logically uncoupled from the main project, with exact pinned version. Makes it easier to work on, and also doesn't make CI run Demo App checks on every PR. Also, updated READMEs to reflect these changes.
karloti
pushed a commit
to karloti/koog
that referenced
this pull request
Oct 21, 2025
I've updated this PR to actually migrate `examples` to a separate `simple-examples` Gradle project in `examples` directory, that depends on the root Koog project via composite build. `examples` is not a module in Koog anymore, just a directory with example projects. After some experiments, I decided not to migrate other example projects, such as Demo Compose App, to composite build approach, at least for now. I believe it's more beneficial to keep these logically uncoupled from the main project, with exact pinned version. Makes it easier to work on, and also doesn't make CI run Demo App checks on every PR. Also, updated READMEs to reflect these changes.
karloti
pushed a commit
to karloti/koog
that referenced
this pull request
Oct 21, 2025
I've updated this PR to actually migrate `examples` to a separate `simple-examples` Gradle project in `examples` directory, that depends on the root Koog project via composite build. `examples` is not a module in Koog anymore, just a directory with example projects. After some experiments, I decided not to migrate other example projects, such as Demo Compose App, to composite build approach, at least for now. I believe it's more beneficial to keep these logically uncoupled from the main project, with exact pinned version. Makes it easier to work on, and also doesn't make CI run Demo App checks on every PR. Also, updated READMEs to reflect these changes.
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.
UPD
I've updated this PR to actually migrate
examplesto a separatesimple-examplesGradle project inexamplesdirectory, that depends on the root Koog project via composite build.examplesis not a module in Koog anymore, just a directory with example projects.After some experiments, I decided not to migrate other example projects, such as Demo Compose App, to composite build approach, at least for now. I believe it's more beneficial to keep these logically uncoupled from the main project, with exact pinned version. Makes it easier to work on, and also doesn't make CI run Demo App checks on every PR.
Also, updated READMEs to reflect these changes.
Previous description, outdated
This is just a demo PR, not intended to be merged. It demonstrates how examples can be turned into Gradle composite builds, to make them more self-contained and separate them from the main Koog project, while still preserving the flexibility of depending directly on the Koog's source code at the same time.
To check it for yourself:
In the IntelliJ's Gradle tool window click onNo need to link+(Link Gradle Project action) and selectcomposite-build-demodirectorysimple-examplesas additional Gradle Project, it will be linked as a composite build dependency in the root project automatically. When working on root Koog project, it is actually not recommended to link explicitly, IntelliJ then looses proper project context.cd'ing to the composite project's directy and calling./gradlew :runor usingRun anythingaction with the correct contextPromptDSL). You will see and can use these changes in composite demo project immediately and when you rerun it, it automatically rebuilds main Koog project if needed as well. Navigation between demo project and main Koog project works seamlessly too.Note: to make it work properly, we need to modify
rootProject.namein rootsettings.gradle.kts- when producing artifacts, it conflicts with already existing meta-modulekoog-agents.