Add some extra log output

This commit is contained in:
Jack Boswell (boswelja)
2020-10-23 15:20:16 +13:00
parent fb873d403d
commit f5c3d22549
2 changed files with 6 additions and 0 deletions

View File

@@ -36,6 +36,7 @@ export async function uploadToPlayStore(options: EditOptions, releaseFiles: stri
releaseFiles.forEach(async releaseFile => {
core.debug(`Uploading ${releaseFile}`)
await uploadRelease(appEdit.data, options, releaseFile).catch(reason => {
core.setFailed(reason)
return Promise.reject(reason)
})
})
@@ -61,9 +62,11 @@ async function uploadRelease(appEdit: AppEdit, options: EditOptions, releaseFile
core.debug("Track is Internal app sharing, switch to special upload api")
if (releaseFile.endsWith('.apk')) {
const res = await internalSharingUploadApk(options, releaseFile)
console.log(`${releaseFile} uploaded to Internal Sharing, download it with ${res.downloadUrl}`)
return Promise.resolve(res.downloadUrl)
} else if (releaseFile.endsWith('.aab')) {
const res = await internalSharingUploadBundle(options, releaseFile)
console.log(`${releaseFile} uploaded to Internal Sharing, download it with ${res.downloadUrl}`)
return Promise.resolve(res.downloadUrl)
} else {
core.setFailed(`${releaseFile} is invalid`)