Browse Source

Remove compose.with.web flag (#1697)

pull/1703/head
Alexey Tsvetkov 3 years ago committed by GitHub
parent
commit
47214264ba
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      compose/scripts/publishGradlePluginToMavenLocal
  2. 2
      gradle-plugins/buildSrc/src/main/kotlin/BuildProperties.kt
  3. 1
      gradle-plugins/compose/build.gradle.kts
  4. 8
      gradle-plugins/compose/src/main/kotlin/org/jetbrains/compose/ComposePlugin.kt
  5. 1
      gradle-plugins/gradle.properties

2
compose/scripts/publishGradlePluginToMavenLocal

@ -8,5 +8,5 @@ if [[ -z "$COMPOSE_CUSTOM_VERSION" ]]; then
fi
pushd ../../gradle-plugins
./gradlew publishToMavenLocal -Pcompose.version="$COMPOSE_CUSTOM_VERSION" -Pdeploy.version="$COMPOSE_CUSTOM_VERSION" -Pcompose.with.web=true || exit 1
./gradlew publishToMavenLocal -Pcompose.version="$COMPOSE_CUSTOM_VERSION" -Pdeploy.version="$COMPOSE_CUSTOM_VERSION" || exit 1
popd

2
gradle-plugins/buildSrc/src/main/kotlin/BuildProperties.kt

@ -17,8 +17,6 @@ object BuildProperties {
fun deployVersion(project: Project): String =
System.getenv("COMPOSE_GRADLE_PLUGIN_VERSION")
?: project.findProperty("deploy.version") as String
fun isComposeWithWeb(project: Project): Boolean =
project.findProperty("compose.with.web") == "true"
fun experimentalOELPublication(project: Project): Boolean =
project.findProperty("oel.publication") == "true"
fun oelAndroidXVersion(project: Project): String? =

1
gradle-plugins/compose/build.gradle.kts

@ -28,7 +28,6 @@ val buildConfig = tasks.register("buildConfig", GenerateBuildConfig::class.java)
classFqName.set("org.jetbrains.compose.ComposeBuildConfig")
generatedOutputDir.set(buildConfigDir)
fieldsToGenerate.put("composeVersion", BuildProperties.composeVersion(project))
fieldsToGenerate.put("isComposeWithWeb", BuildProperties.isComposeWithWeb(project))
fieldsToGenerate.put("experimentalOELPublication", BuildProperties.experimentalOELPublication(project))
fieldsToGenerate.put("oelAndroidXVersion", BuildProperties.oelAndroidXVersion(project).orEmpty())
}

8
gradle-plugins/compose/src/main/kotlin/org/jetbrains/compose/ComposePlugin.kt

@ -43,9 +43,7 @@ class ComposePlugin : Plugin<Project> {
}
project.initializePreview()
if (ComposeBuildConfig.isComposeWithWeb) {
composeExtension.extensions.create("web", WebExtension::class.java)
}
composeExtension.extensions.create("web", WebExtension::class.java)
project.plugins.apply(ComposeCompilerKotlinSupportPlugin::class.java)
@ -179,9 +177,7 @@ class ComposePlugin : Plugin<Project> {
val uiTooling get() = composeDependency("org.jetbrains.compose.ui:ui-tooling")
val preview get() = composeDependency("org.jetbrains.compose.ui:ui-tooling-preview")
val materialIconsExtended get() = composeDependency("org.jetbrains.compose.material:material-icons-extended")
val web: WebDependencies get() =
if (ComposeBuildConfig.isComposeWithWeb) WebDependencies
else error("This version of Compose plugin does not support 'compose.web.*' dependencies")
val web: WebDependencies get() = WebDependencies
}
object DesktopDependencies {

1
gradle-plugins/gradle.properties

@ -7,7 +7,6 @@ kotlin.code.style=official
#
# __LATEST_COMPOSE_RELEASE_VERSION__
compose.version=0.0.0-mpp-dev553
compose.with.web=false
# A version of Gradle plugin, that will be published,
# unless overridden by COMPOSE_GRADLE_PLUGIN_VERSION env var.

Loading…
Cancel
Save