mirror of
https://github.com/erlef/setup-beam.git
synced 2026-07-28 18:50:49 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
11d59b146c | ||
|
|
e332dc64ad |
@@ -20,13 +20,13 @@ jobs:
|
|||||||
node-version: '12'
|
node-version: '12'
|
||||||
- run: npm install -g npm
|
- run: npm install -g npm
|
||||||
- run: npm install
|
- run: npm install
|
||||||
- run: npm run format
|
- run: npm run build
|
||||||
- run: npm install -g markdownlint-cli
|
- run: npm install -g markdownlint-cli
|
||||||
- run: npm run markdownlint
|
- run: npm run markdownlint
|
||||||
- run: npm run shellcheck
|
- run: npm run shellcheck
|
||||||
- run: npm run yamllint
|
- run: npm run yamllint
|
||||||
- run: npm run jslint
|
- run: npm run jslint
|
||||||
- run: npm run licenses
|
- run: npm run licenses
|
||||||
- run: npm run build
|
- run: npm run format
|
||||||
- name: Check if build left artifacts
|
- name: Check if build left artifacts
|
||||||
run: git diff --exit-code
|
run: git diff --exit-code
|
||||||
|
|||||||
@@ -56,7 +56,7 @@ jobs:
|
|||||||
os: 'ubuntu-16.04'
|
os: 'ubuntu-16.04'
|
||||||
- elixir-version: 'v1.4'
|
- elixir-version: 'v1.4'
|
||||||
otp-version: '20'
|
otp-version: '20'
|
||||||
rebar3-version: '3.11'
|
rebar3-version: '3.6.0'
|
||||||
os: 'ubuntu-18.04'
|
os: 'ubuntu-18.04'
|
||||||
- elixir-version: 'v1.4'
|
- elixir-version: 'v1.4'
|
||||||
otp-version: '20'
|
otp-version: '20'
|
||||||
|
|||||||
@@ -154,18 +154,18 @@ async function testRebar3Versions() {
|
|||||||
let expected
|
let expected
|
||||||
let spec
|
let spec
|
||||||
|
|
||||||
spec = '3.13.x'
|
spec = '3.10.x'
|
||||||
expected = '3.13.2'
|
expected = '3.10.0'
|
||||||
got = await setupElixir.getRebar3Version(spec)
|
got = await setupElixir.getRebar3Version(spec)
|
||||||
assert.deepStrictEqual(got, expected)
|
assert.deepStrictEqual(got, expected)
|
||||||
|
|
||||||
spec = '3.13.2'
|
spec = '3.10.0'
|
||||||
expected = '3.13.2'
|
expected = '3.10.0'
|
||||||
got = await setupElixir.getRebar3Version(spec)
|
got = await setupElixir.getRebar3Version(spec)
|
||||||
assert.deepStrictEqual(got, expected)
|
assert.deepStrictEqual(got, expected)
|
||||||
|
|
||||||
spec = '3.13'
|
spec = '3.10'
|
||||||
expected = '3.13.2'
|
expected = '3.10.0'
|
||||||
got = await setupElixir.getRebar3Version(spec)
|
got = await setupElixir.getRebar3Version(spec)
|
||||||
assert.deepStrictEqual(got, expected)
|
assert.deepStrictEqual(got, expected)
|
||||||
}
|
}
|
||||||
|
|||||||
Vendored
+5
-3
@@ -4780,11 +4780,13 @@ async function getElixirVersion(exSpec0, otpVersion) {
|
|||||||
if (elixirVersions.get(elixirVersion).includes(otpMatch[1])) {
|
if (elixirVersions.get(elixirVersion).includes(otpMatch[1])) {
|
||||||
// ... and it's available: use it!
|
// ... and it's available: use it!
|
||||||
elixirVersionWithOTP = `${elixirVersion}-otp-${otpVersionMajor}`
|
elixirVersionWithOTP = `${elixirVersion}-otp-${otpVersionMajor}`
|
||||||
core.info(`Using Elixir / -otp- version ${elixirVersionWithOTP}`)
|
core.info(
|
||||||
|
`Using Elixir ${elixirVersion} (built for OTP ${otpVersionMajor})`,
|
||||||
|
)
|
||||||
} else {
|
} else {
|
||||||
// ... and it's not available: fallback to the "generic" version (v1.4.5 only).
|
// ... and it's not available: fallback to the "generic" version (v1.4.5 only).
|
||||||
elixirVersionWithOTP = elixirVersion
|
elixirVersionWithOTP = elixirVersion
|
||||||
core.info(`Using Elixir ${elixirVersionWithOTP}`)
|
core.info(`Using Elixir ${elixirVersion}`)
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
throw new Error(
|
throw new Error(
|
||||||
@@ -4857,7 +4859,7 @@ async function getElixirVersions() {
|
|||||||
|
|
||||||
async function getRebar3Versions() {
|
async function getRebar3Versions() {
|
||||||
const resultJSON = await get(
|
const resultJSON = await get(
|
||||||
'https://api.github.com/repos/erlang/rebar3/releases',
|
'https://api.github.com/repos/erlang/rebar3/releases?per_page=100',
|
||||||
)
|
)
|
||||||
const rebar3VersionsListing = JSON.parse(resultJSON)
|
const rebar3VersionsListing = JSON.parse(resultJSON)
|
||||||
.map((x) => x.tag_name)
|
.map((x) => x.tag_name)
|
||||||
|
|||||||
+5
-3
@@ -144,11 +144,13 @@ async function getElixirVersion(exSpec0, otpVersion) {
|
|||||||
if (elixirVersions.get(elixirVersion).includes(otpMatch[1])) {
|
if (elixirVersions.get(elixirVersion).includes(otpMatch[1])) {
|
||||||
// ... and it's available: use it!
|
// ... and it's available: use it!
|
||||||
elixirVersionWithOTP = `${elixirVersion}-otp-${otpVersionMajor}`
|
elixirVersionWithOTP = `${elixirVersion}-otp-${otpVersionMajor}`
|
||||||
core.info(`Using Elixir / -otp- version ${elixirVersionWithOTP}`)
|
core.info(
|
||||||
|
`Using Elixir ${elixirVersion} (built for OTP ${otpVersionMajor})`,
|
||||||
|
)
|
||||||
} else {
|
} else {
|
||||||
// ... and it's not available: fallback to the "generic" version (v1.4.5 only).
|
// ... and it's not available: fallback to the "generic" version (v1.4.5 only).
|
||||||
elixirVersionWithOTP = elixirVersion
|
elixirVersionWithOTP = elixirVersion
|
||||||
core.info(`Using Elixir ${elixirVersionWithOTP}`)
|
core.info(`Using Elixir ${elixirVersion}`)
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
throw new Error(
|
throw new Error(
|
||||||
@@ -221,7 +223,7 @@ async function getElixirVersions() {
|
|||||||
|
|
||||||
async function getRebar3Versions() {
|
async function getRebar3Versions() {
|
||||||
const resultJSON = await get(
|
const resultJSON = await get(
|
||||||
'https://api.github.com/repos/erlang/rebar3/releases',
|
'https://api.github.com/repos/erlang/rebar3/releases?per_page=100',
|
||||||
)
|
)
|
||||||
const rebar3VersionsListing = JSON.parse(resultJSON)
|
const rebar3VersionsListing = JSON.parse(resultJSON)
|
||||||
.map((x) => x.tag_name)
|
.map((x) => x.tag_name)
|
||||||
|
|||||||
Reference in New Issue
Block a user