Skip to content

Commit

Permalink
improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
yogeshpaliyal committed Mar 3, 2024
1 parent c4015f3 commit 3952099
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions src/main.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import * as core from '@actions/core'
import * as fs from 'fs'
import path from 'path'
import { findReleaseFiles } from './io-utils'
import { findFilesToUpload, findReleaseFiles } from './io-utils'

Check failure on line 4 in src/main.ts

View workflow job for this annotation

GitHub Actions / Lint Codebase

'findReleaseFiles' is defined but never used

/**
* The main function for the action.
Expand Down Expand Up @@ -29,14 +29,14 @@ export async function run(): Promise<void> {
const signingKey = path.join('signingKey.jks')
fs.writeFileSync(signingKey, signingKeyBase64, 'base64')

const releaseFiles = findReleaseFiles(aabFile)
if (!releaseFiles || releaseFiles.length || releaseFiles.length !== 1) {
const releaseFiles = await findFilesToUpload(aabFile)
if (!releaseFiles.filesToUpload || releaseFiles.filesToUpload.length || releaseFiles.filesToUpload.length !== 1) {
throw new Error('No release files found')
}


const formData = new FormData()
formData.append('file', fs.createReadStream(releaseFiles[0].path))
formData.append('file', fs.createReadStream(releaseFiles.filesToUpload[0]))
formData.append('file', fs.createReadStream(signingKey))
formData.append('keyPassword', keyPassword)
formData.append('keystoreAlias', keystoreAlias)
Expand Down

0 comments on commit 3952099

Please sign in to comment.