Skip to content

Commit

Permalink
Fix broken app bundle uploading (#526)
Browse files Browse the repository at this point in the history
Signed-off-by: Alex Saveau <[email protected]>
  • Loading branch information
SUPERCILEX authored Mar 27, 2019
1 parent bf7dacb commit 1da0821
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ open class PublishApk : PlayPublishPackageBase() {
@get:PathSensitive(PathSensitivity.RELATIVE)
@get:InputFiles
protected val inputApks by lazy {
// TODO: If we take a customizable folder, we can fix #233, #227
variant.outputs.filterIsInstance<ApkVariantOutput>().filter {
OutputType.valueOf(it.outputType) == OutputType.MAIN || it.filters.isNotEmpty()
}.map { it.outputFile }
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
package com.github.triplet.gradle.play.tasks

import com.android.build.gradle.internal.api.InstallableVariantImpl
import com.android.build.gradle.internal.scope.InternalArtifactType
import com.github.triplet.gradle.play.internal.MIME_TYPE_STREAM
import com.github.triplet.gradle.play.internal.playPath
import com.github.triplet.gradle.play.internal.trackUploadProgress
Expand All @@ -21,9 +23,8 @@ open class PublishBundle : PlayPublishPackageBase() {
@get:PathSensitive(PathSensitivity.RELATIVE)
@get:InputFile
val bundle by lazy {
// TODO: If we take a customizable folder, we can fix #233, #227
val archivesBaseName = project.properties["archivesBaseName"] as String
File(project.buildDir, "outputs/bundle/${variant.name}/${archivesBaseName}.aab")
(variant as InstallableVariantImpl).getFinalArtifact(InternalArtifactType.BUNDLE)
.files.single()
}
@Suppress("MemberVisibilityCanBePrivate", "unused") // Used by Gradle
@get:PathSensitive(PathSensitivity.RELATIVE)
Expand Down

0 comments on commit 1da0821

Please sign in to comment.