From 66243ade0a90cd53fb2be9cd50bbfc5bb5953181 Mon Sep 17 00:00:00 2001 From: Paulo Lieuthier Date: Tue, 11 May 2021 11:47:45 -0300 Subject: [PATCH] Export main action functions, ease reuse --- dist/cleanup/index.js | 1 + dist/setup/index.js | 1 + src/cleanup-java.ts | 2 +- src/setup-java.ts | 2 +- 4 files changed, 4 insertions(+), 2 deletions(-) diff --git a/dist/cleanup/index.js b/dist/cleanup/index.js index be25b9b2..32347c68 100644 --- a/dist/cleanup/index.js +++ b/dist/cleanup/index.js @@ -2592,6 +2592,7 @@ function run() { } }); } +exports.default = run; run(); diff --git a/dist/setup/index.js b/dist/setup/index.js index fa160ea8..a371e30e 100644 --- a/dist/setup/index.js +++ b/dist/setup/index.js @@ -35713,6 +35713,7 @@ function run() { } }); } +exports.default = run; run(); diff --git a/src/cleanup-java.ts b/src/cleanup-java.ts index bde02bc3..763341e6 100644 --- a/src/cleanup-java.ts +++ b/src/cleanup-java.ts @@ -2,7 +2,7 @@ import * as core from '@actions/core'; import * as gpg from './gpg'; import * as constants from './constants'; -async function run() { +export default async function run() { if (core.getInput(constants.INPUT_GPG_PRIVATE_KEY, { required: false })) { core.info('Removing private key from keychain'); try { diff --git a/src/setup-java.ts b/src/setup-java.ts index 92a86197..0d9fc82d 100644 --- a/src/setup-java.ts +++ b/src/setup-java.ts @@ -6,7 +6,7 @@ import * as path from 'path'; import { getJavaDistribution } from './distributions/distribution-factory'; import { JavaInstallerOptions } from './distributions/base-models'; -async function run() { +export default async function run() { try { const version = core.getInput(constants.INPUT_JAVA_VERSION, { required: true }); const distributionName = core.getInput(constants.INPUT_DISTRIBUTION, { required: true });