Skip to content

Comments

Examples separate projects#1677

Draft
Jolanrensen wants to merge 20 commits intomasterfrom
examples-separate-projects
Draft

Examples separate projects#1677
Jolanrensen wants to merge 20 commits intomasterfrom
examples-separate-projects

Conversation

@Jolanrensen
Copy link
Collaborator

@Jolanrensen Jolanrensen commented Feb 6, 2026

Fixes #1614
Step 3 of #1661

  • Introduces example structure like:

    • /examples/projects/1,2,3: release versions of examples
    • /examples/projects/dev/1,2,3: dev versions of examples
      Dev versions of the examples are built using the sources of the project, while release examples use the latest release versions.
      Since any example is a completely separate project, you can attach them to the IDE separately only if you need it :).
      And most importantly, each example could be extracted to a ZIP and runnable by a user without any additional setup (TODO test this)
  • Running :promoteExamples copies all /dev examples upwards, making them the new "release" versions. :syncExampleFolders is run afterwards.

  • Running :syncExampleFolders (run automatically every :assemble) overwrites all relevant versions and properties in the examples from our main libs.versions.toml, gradle-wrapper.properties, .editorconfig, etc. This also works for any maven examples (see build-logic/src/.../buildExampleProjects for the specific implementaiton)

  • Running the Test task :buildExampleFolders (run automatically every :test in debug mode, so on TC) builds all example projects using TestBuildingExampleProjects.

    • Thanks to the :syncExampleFolders task, all dev Gradle Example projects get includeBuild("../../../..") in settings.gradle.kts, which substitutes any DataFrame dependeny with our actual sources. This also makes working inside them from the IDE as easy as if it were a subproject :).
    • The Android examples are ignored if the Gradle property android.sdk.dir is unset. I modified TeamCity to provide -Pandroid.sdk.dir=%env.ANDROID_SDK_HOME% and it seems to work :) This gradle property is passed down to any example containing "android" (in any form) in its name. (This logic can change if needed)
    • The Maven dev project requires a published version of DataFrame. We cannot substitute a Gradle build into Maven in the same way (AFAIK). So for that we use :publishLocal to publish the artifacts to /build/maven before running the tests.

…uild that can build the projects in /example/projects
@Jolanrensen Jolanrensen force-pushed the examples-separate-projects branch from 2ec6075 to a20f5a7 Compare February 6, 2026 13:52
@Jolanrensen Jolanrensen force-pushed the examples-separate-projects branch 2 times, most recently from 253d408 to bc241e6 Compare February 16, 2026 19:08
@Jolanrensen Jolanrensen force-pushed the examples-separate-projects branch from bc241e6 to 96714c6 Compare February 16, 2026 19:20
@Jolanrensen Jolanrensen force-pushed the examples-separate-projects branch from 461e286 to 31256ad Compare February 17, 2026 14:26
@Jolanrensen Jolanrensen force-pushed the examples-separate-projects branch from 31256ad to bd9bd74 Compare February 17, 2026 14:28
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.

Make :examples be separate projects and use the compiler plugin

1 participant