Skip to content

Commit

Permalink
Make examples a separated project
Browse files Browse the repository at this point in the history
  • Loading branch information
JSMonk committed Sep 6, 2024
1 parent c1df017 commit e70f200
Show file tree
Hide file tree
Showing 8 changed files with 2,853 additions and 7 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@ jobs:
run: ./gradlew publishToMavenLocal

- name: Run Gradle Tasks
run: ./gradlew :examples:wasmJsBrowserStoriesProductionExecutableDistribution
run:
cd examples
../gradlew :examples:wasmJsBrowserStoriesProductionExecutableDistribution

- name: Fix permissions
run: |
Expand Down
4 changes: 0 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -110,12 +110,8 @@ If you can't find all Gradle tasks containing `Storytale` after syncing, check i

## Building and Contributing

For your first build of Storytale, you need to comment out `alias(libs.plugins.storytale)` in both the root-level `build.gradle.kts` file as well as `build.gradle.kts` under the `examples` module (if they are not already commented). Then, sync Gradle.

Once the sync is successful, run `./gradlew publishToMavenLocal`.

After publishing, uncomment the previous `build.gradle.kts` lines and sync again.

At this point, if you see these Storytale `Gradle tasks`, it means you’ve successfully set up the project and can start contributing! :)

<img width="453" alt="image" src="https://github.com/user-attachments/assets/e9cfa634-27f2-4613-9579-194c3e6c09a4">
Expand Down
1 change: 0 additions & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
plugins {
alias(libs.plugins.storytale) apply false
// this is necessary to avoid the plugins to be loaded multiple times
// in each subproject's classloader
alias(libs.plugins.androidApplication) apply false
Expand Down
1 change: 1 addition & 0 deletions examples/gradle
1 change: 1 addition & 0 deletions examples/gradle.properties
2,815 changes: 2,815 additions & 0 deletions examples/kotlin-js-store/yarn.lock

Large diffs are not rendered by default.

33 changes: 33 additions & 0 deletions examples/settings.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
rootProject.name = "StorytaleUsageExamples"
enableFeaturePreview("TYPESAFE_PROJECT_ACCESSORS")

pluginManagement {
repositories {
maven("https://maven.pkg.jetbrains.space/kotlin/p/kotlin/dev")
google {
mavenContent {
includeGroupAndSubgroups("androidx")
includeGroupAndSubgroups("com.android")
includeGroupAndSubgroups("com.google")
}
}
mavenCentral()
gradlePluginPortal()
mavenLocal()
}
}

dependencyResolutionManagement {
repositories {
google {
mavenContent {
includeGroupAndSubgroups("androidx")
includeGroupAndSubgroups("com.android")
includeGroupAndSubgroups("com.google")
}
}
maven("https://maven.pkg.jetbrains.space/kotlin/p/kotlin/dev")
mavenCentral()
mavenLocal()
}
}
1 change: 0 additions & 1 deletion settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,3 @@ include(":modules:gallery")
include(":modules:gradle-plugin")
include(":modules:compiler-plugin")
include(":modules:runtime-api")
include(":examples")

0 comments on commit e70f200

Please sign in to comment.