mirror of
https://github.com/erlef/setup-beam.git
synced 2026-07-23 07:06:07 +00:00
Add experimental-otp input opt-in flag
This commit is contained in:
Vendored
+6
-2
@@ -3321,13 +3321,17 @@ async function main() {
|
|||||||
elixirSpec,
|
elixirSpec,
|
||||||
otpVersion
|
otpVersion
|
||||||
)
|
)
|
||||||
const osVersion = getOSVersion()
|
|
||||||
|
|
||||||
let installHex = core.getInput('install-hex')
|
let installHex = core.getInput('install-hex')
|
||||||
installHex = installHex == null ? 'true' : installHex
|
installHex = installHex == null ? 'true' : installHex
|
||||||
|
|
||||||
let installRebar = core.getInput('install-rebar')
|
let installRebar = core.getInput('install-rebar')
|
||||||
installRebar = installRebar == null ? 'true' : installRebar
|
installRebar = installRebar == null ? 'true' : installRebar
|
||||||
|
|
||||||
|
const experimentalOTP = core.getInput('experimental-otp')
|
||||||
|
const osVersion =
|
||||||
|
experimentalOTP === 'true' ? getRunnerOSVersion() : 'ubuntu-14.04'
|
||||||
|
|
||||||
console.log(`##[group]Installing OTP ${otpVersion} - built on ${osVersion}`)
|
console.log(`##[group]Installing OTP ${otpVersion} - built on ${osVersion}`)
|
||||||
await installOTP(otpVersion, osVersion)
|
await installOTP(otpVersion, osVersion)
|
||||||
console.log(`##[endgroup]`)
|
console.log(`##[endgroup]`)
|
||||||
@@ -3359,7 +3363,7 @@ async function getOtpVersion(spec) {
|
|||||||
return getVersionFromSpec(spec, await getOtpVersions()) || spec
|
return getVersionFromSpec(spec, await getOtpVersions()) || spec
|
||||||
}
|
}
|
||||||
|
|
||||||
function getOSVersion() {
|
function getRunnerOSVersion(experimentalOTP) {
|
||||||
const mapToUbuntuVersion = {
|
const mapToUbuntuVersion = {
|
||||||
ubuntu16: 'ubuntu-16.04',
|
ubuntu16: 'ubuntu-16.04',
|
||||||
ubuntu18: 'ubuntu-18.04',
|
ubuntu18: 'ubuntu-18.04',
|
||||||
|
|||||||
+6
-2
@@ -23,13 +23,17 @@ async function main() {
|
|||||||
elixirSpec,
|
elixirSpec,
|
||||||
otpVersion
|
otpVersion
|
||||||
)
|
)
|
||||||
const osVersion = getOSVersion()
|
|
||||||
|
|
||||||
let installHex = core.getInput('install-hex')
|
let installHex = core.getInput('install-hex')
|
||||||
installHex = installHex == null ? 'true' : installHex
|
installHex = installHex == null ? 'true' : installHex
|
||||||
|
|
||||||
let installRebar = core.getInput('install-rebar')
|
let installRebar = core.getInput('install-rebar')
|
||||||
installRebar = installRebar == null ? 'true' : installRebar
|
installRebar = installRebar == null ? 'true' : installRebar
|
||||||
|
|
||||||
|
const experimentalOTP = core.getInput('experimental-otp')
|
||||||
|
const osVersion =
|
||||||
|
experimentalOTP === 'true' ? getRunnerOSVersion() : 'ubuntu-14.04'
|
||||||
|
|
||||||
console.log(`##[group]Installing OTP ${otpVersion} - built on ${osVersion}`)
|
console.log(`##[group]Installing OTP ${otpVersion} - built on ${osVersion}`)
|
||||||
await installOTP(otpVersion, osVersion)
|
await installOTP(otpVersion, osVersion)
|
||||||
console.log(`##[endgroup]`)
|
console.log(`##[endgroup]`)
|
||||||
@@ -61,7 +65,7 @@ async function getOtpVersion(spec) {
|
|||||||
return getVersionFromSpec(spec, await getOtpVersions()) || spec
|
return getVersionFromSpec(spec, await getOtpVersions()) || spec
|
||||||
}
|
}
|
||||||
|
|
||||||
function getOSVersion() {
|
function getRunnerOSVersion(experimentalOTP) {
|
||||||
const mapToUbuntuVersion = {
|
const mapToUbuntuVersion = {
|
||||||
ubuntu16: 'ubuntu-16.04',
|
ubuntu16: 'ubuntu-16.04',
|
||||||
ubuntu18: 'ubuntu-18.04',
|
ubuntu18: 'ubuntu-18.04',
|
||||||
|
|||||||
Reference in New Issue
Block a user