-
Notifications
You must be signed in to change notification settings - Fork 0
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
chore: update build process #22
Changes from 3 commits
df0def3
c5ff1da
b82e97b
bdb58e5
5f898b6
203bea5
42dd7c0
46fabd4
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -98,13 +98,6 @@ kotlin { | |
} | ||
} | ||
|
||
compose.resources { | ||
customDirectory( | ||
sourceSetName = "commonMain", | ||
directoryProvider = provider { layout.projectDirectory.dir(config.resRoot) }, | ||
) | ||
} | ||
|
||
android { | ||
namespace = "org.ooni.probe" | ||
compileSdk = libs.versions.android.compileSdk.get().toInt() | ||
|
@@ -161,9 +154,9 @@ tasks.register("copyCommonResourcesToFlavor") { | |
doLast { | ||
val projectDir = project.projectDir.absolutePath | ||
|
||
val sourceFile = File(projectDir, "src/commonMain/composeResources") | ||
val destinationFile = File(projectDir, "src/commonMain/composeResources") | ||
|
||
val destinationFile = File(projectDir, config.resRoot) | ||
val sourceFile = File(projectDir, config.resRoot) | ||
|
||
copyRecursive(sourceFile, destinationFile) | ||
} | ||
|
@@ -173,7 +166,7 @@ tasks.register("cleanCopiedCommonResourcesToFlavor") { | |
doLast { | ||
val projectDir = project.projectDir.absolutePath | ||
|
||
val destinationFile = File(projectDir, config.resRoot) | ||
val destinationFile = File(projectDir, "src/commonMain/composeResources") | ||
destinationFile.listFiles()?.forEach { folder -> | ||
folder.listFiles()?.forEach { file -> | ||
if (file.name == ".gitignore") { | ||
|
@@ -279,3 +272,15 @@ fun copyRecursive( | |
} | ||
} | ||
} | ||
|
||
tasks.register("runDebug", Exec::class) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why do we need this task? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This enables us to set up custom gradle tasks with There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I haven't tried any option that works |
||
dependsOn("clean", "uninstallDebug", "installDebug") | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I feel like instead of relying so much on the Because running There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The pre build works locally but for some reason it fails on the ci There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If I run There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. but you can launch the |
||
commandLine( | ||
"adb", | ||
"shell", | ||
"am", | ||
"start", | ||
"-n", | ||
"${config.appId}.debug/org.ooni.probe.MainActivity", | ||
) | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
|
||
logo.xml |
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
|
||
strings-organization.xml |
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,7 @@ android-compileSdk = "34" | |
android-minSdk = "24" | ||
android-targetSdk = "34" | ||
|
||
compose-plugin = "1.7.0-alpha02" | ||
compose-plugin = "1.6.11" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We can go back to the stable version? Nice! |
||
kotlin = "2.0.0" | ||
|
||
[plugins] | ||
|
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.
It's a shame if we clean every time, because that clears the work we cached and slows things down. Can we run a specific gradle task do clean what we need?
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.
Yes we can run
copyCommonResourcesToFlavor
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'm also thinking, maybe it can go into the
actions/setup
?