Add support for GraalVM Enterprise Edition.

Fixes #5.
This commit is contained in:
Fabio Niephaus
2022-03-03 17:24:24 +01:00
committed by Fabio Niephaus
parent 1a4a7ccb68
commit 2240cb3432
13 changed files with 415 additions and 41 deletions

View File

@@ -1,5 +1,6 @@
import * as c from './constants'
import {downloadExtractAndCacheJDK, getLatestRelease} from './utils'
import {downloadTool} from '@actions/tool-cache'
const MANDREL_REPO = 'mandrel'
const MANDREL_TAG_PREFIX = c.MANDREL_NAMESPACE
@@ -47,7 +48,11 @@ async function setUpMandrelRelease(
const identifier = determineMandrelIdentifier(version, javaVersion)
const downloadUrl = `${MANDREL_DL_BASE}/${MANDREL_TAG_PREFIX}${version}/${identifier}${c.GRAALVM_FILE_EXTENSION}`
const toolName = determineToolName(javaVersion)
return downloadExtractAndCacheJDK(downloadUrl, toolName, version)
return downloadExtractAndCacheJDK(
async () => downloadTool(downloadUrl),
toolName,
version
)
}
function determineMandrelIdentifier(