mirror of
https://github.com/julia-actions/setup-julia.git
synced 2026-02-12 19:16:54 +08:00
Compare commits
5 Commits
releases/v
...
releases/v
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
19bd4db8c4 | ||
|
|
87fafcc1ec | ||
|
|
57ce80e73c | ||
|
|
ffea8bb089 | ||
|
|
3a89763b86 |
1
.github/workflows/backup.yml
vendored
1
.github/workflows/backup.yml
vendored
@@ -9,6 +9,7 @@ on:
|
||||
jobs:
|
||||
backup:
|
||||
runs-on: ubuntu-20.04
|
||||
timeout-minutes: 60
|
||||
|
||||
steps:
|
||||
- name: Configure cache
|
||||
|
||||
7
.github/workflows/checkin.yml
vendored
7
.github/workflows/checkin.yml
vendored
@@ -1,9 +1,16 @@
|
||||
name: "PR Checks"
|
||||
on: [pull_request, push]
|
||||
|
||||
concurrency:
|
||||
# Skip intermediate builds: all builds except for builds on the `master`, `main`, or `release-*` branches
|
||||
# Cancel intermediate builds: only pull request builds
|
||||
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.ref != 'refs/heads/master' || github.ref != 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-') || github.run_number }}
|
||||
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
|
||||
|
||||
jobs:
|
||||
check_pr:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 60
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
|
||||
|
||||
7
.github/workflows/codeql-analysis.yml
vendored
7
.github/workflows/codeql-analysis.yml
vendored
@@ -11,6 +11,12 @@
|
||||
#
|
||||
name: "CodeQL"
|
||||
|
||||
concurrency:
|
||||
# Skip intermediate builds: all builds except for builds on the `master`, `main`, or `release-*` branches
|
||||
# Cancel intermediate builds: only pull request builds
|
||||
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.ref != 'refs/heads/master' || github.ref != 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-') || github.run_number }}
|
||||
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ master, releases/* ]
|
||||
@@ -24,6 +30,7 @@ jobs:
|
||||
analyze:
|
||||
name: Analyze
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 60
|
||||
|
||||
strategy:
|
||||
fail-fast: false
|
||||
|
||||
@@ -1,5 +1,11 @@
|
||||
name: Example builds (default arch)
|
||||
|
||||
concurrency:
|
||||
# Skip intermediate builds: all builds except for builds on the `master`, `main`, or `release-*` branches
|
||||
# Cancel intermediate builds: only pull request builds
|
||||
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.ref != 'refs/heads/master' || github.ref != 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-') || github.run_number }}
|
||||
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: ['main', 'master', 'releases/*']
|
||||
@@ -9,6 +15,7 @@ on:
|
||||
jobs:
|
||||
test:
|
||||
runs-on: ${{ matrix.os }}
|
||||
timeout-minutes: 60
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
|
||||
38
.github/workflows/example-builds-nightly-defaultarch.yml
vendored
Normal file
38
.github/workflows/example-builds-nightly-defaultarch.yml
vendored
Normal file
@@ -0,0 +1,38 @@
|
||||
name: Example builds (nightly, default arch)
|
||||
|
||||
concurrency:
|
||||
# Skip intermediate builds: all builds except for builds on the `master`, `main`, or `release-*` branches
|
||||
# Cancel intermediate builds: only pull request builds
|
||||
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.ref != 'refs/heads/master' || github.ref != 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-') || github.run_number }}
|
||||
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: ['main', 'master', 'releases/*']
|
||||
pull_request:
|
||||
|
||||
jobs:
|
||||
test:
|
||||
runs-on: ${{ matrix.os }}
|
||||
timeout-minutes: 60
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
julia-version: [nightly, 1.8-nightly]
|
||||
os: [ubuntu-latest, macOS-latest, windows-latest]
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v1.0.0
|
||||
|
||||
- name: "Install dependencies"
|
||||
run: |
|
||||
npm install --legacy-peer-deps
|
||||
npm run build
|
||||
npm run pack
|
||||
|
||||
- name: "Set up Julia (${{ matrix.julia-version }})"
|
||||
uses: ./
|
||||
with:
|
||||
version: ${{ matrix.julia-version }}
|
||||
- run: julia --version
|
||||
- run: julia --compile=min -O0 -e 'import InteractiveUtils; InteractiveUtils.versioninfo()'
|
||||
11
.github/workflows/example-builds-nightly.yml
vendored
11
.github/workflows/example-builds-nightly.yml
vendored
@@ -1,5 +1,11 @@
|
||||
name: Example builds (nightly)
|
||||
|
||||
concurrency:
|
||||
# Skip intermediate builds: all builds except for builds on the `master`, `main`, or `release-*` branches
|
||||
# Cancel intermediate builds: only pull request builds
|
||||
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.ref != 'refs/heads/master' || github.ref != 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-') || github.run_number }}
|
||||
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: ['main', 'master', 'releases/*']
|
||||
@@ -10,6 +16,7 @@ on:
|
||||
jobs:
|
||||
test:
|
||||
runs-on: ${{ matrix.os }}
|
||||
timeout-minutes: 60
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
@@ -20,10 +27,10 @@ jobs:
|
||||
exclude:
|
||||
- os: macOS-latest
|
||||
julia-arch: x86
|
||||
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v1.0.0
|
||||
|
||||
|
||||
- name: "Install dependencies"
|
||||
run: |
|
||||
npm install --legacy-peer-deps
|
||||
|
||||
11
.github/workflows/example-builds.yml
vendored
11
.github/workflows/example-builds.yml
vendored
@@ -1,5 +1,11 @@
|
||||
name: Example builds
|
||||
|
||||
concurrency:
|
||||
# Skip intermediate builds: all builds except for builds on the `master`, `main`, or `release-*` branches
|
||||
# Cancel intermediate builds: only pull request builds
|
||||
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.ref != 'refs/heads/master' || github.ref != 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release-') || github.run_number }}
|
||||
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: ['main', 'master', 'releases/*']
|
||||
@@ -9,17 +15,18 @@ on:
|
||||
jobs:
|
||||
test:
|
||||
runs-on: ${{ matrix.os }}
|
||||
timeout-minutes: 60
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
julia-version: ['1.0.5', '1', '^1.5.0-beta1']
|
||||
julia-version: ['1.0.5', '1.2', '^1.5.0-beta1', '1']
|
||||
julia-arch: [x64, x86]
|
||||
os: [ubuntu-latest, macOS-latest, windows-latest]
|
||||
# 32-bit Julia binaries are not available on macOS
|
||||
exclude:
|
||||
- os: macOS-latest
|
||||
julia-arch: x86
|
||||
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v1.0.0
|
||||
|
||||
|
||||
2
.gitignore
vendored
2
.gitignore
vendored
@@ -1,3 +1,3 @@
|
||||
node_modules/
|
||||
__tests__/runner/*
|
||||
dist/
|
||||
!dist/
|
||||
|
||||
5260
dist/index.js
vendored
Normal file
5260
dist/index.js
vendored
Normal file
File diff suppressed because it is too large
Load Diff
BIN
dist/unzip
vendored
Normal file
BIN
dist/unzip
vendored
Normal file
Binary file not shown.
70
lib/installer.js
generated
70
lib/installer.js
generated
@@ -32,11 +32,8 @@ const osMap = {
|
||||
};
|
||||
const archMap = {
|
||||
'x86': 'i686',
|
||||
'X86': 'i686',
|
||||
'x64': 'x86_64',
|
||||
'X64': 'x86_64',
|
||||
'aarch64': 'aarch64',
|
||||
'ARM64': 'aarch64'
|
||||
'aarch64': 'aarch64'
|
||||
};
|
||||
// Store information about the environment
|
||||
const osPlat = os.platform(); // possible values: win32 (Windows), linux (Linux), darwin (macOS)
|
||||
@@ -105,30 +102,57 @@ function getJuliaVersion(availableReleases, versionInput) {
|
||||
return version;
|
||||
}
|
||||
exports.getJuliaVersion = getJuliaVersion;
|
||||
function getDesiredFileExts() {
|
||||
let fileExt1;
|
||||
let hasFileExt2;
|
||||
let fileExt2;
|
||||
if (osPlat == 'win32') {
|
||||
fileExt1 = 'exe';
|
||||
hasFileExt2 = false;
|
||||
fileExt2 = '';
|
||||
}
|
||||
else if (osPlat == 'darwin') {
|
||||
fileExt1 = 'tar.gz';
|
||||
hasFileExt2 = true;
|
||||
fileExt2 = 'dmg';
|
||||
}
|
||||
else if (osPlat === 'linux') {
|
||||
fileExt1 = 'tar.gz';
|
||||
hasFileExt2 = false;
|
||||
fileExt2 = '';
|
||||
}
|
||||
else {
|
||||
throw new Error(`Platform ${osPlat} is not supported`);
|
||||
}
|
||||
return [fileExt1, hasFileExt2, fileExt2];
|
||||
}
|
||||
function getNightlyFileName(arch) {
|
||||
let versionExt, ext;
|
||||
let versionExt;
|
||||
let fileExt1;
|
||||
[fileExt1, ,] = getDesiredFileExts();
|
||||
if (osPlat == 'win32') {
|
||||
versionExt = arch == 'x64' ? '-win64' : '-win32';
|
||||
ext = 'exe';
|
||||
}
|
||||
else if (osPlat == 'darwin') {
|
||||
if (arch == 'x86') {
|
||||
throw new Error('32-bit Julia is not available on macOS');
|
||||
}
|
||||
versionExt = '-mac64';
|
||||
ext = 'dmg';
|
||||
}
|
||||
else if (osPlat === 'linux') {
|
||||
versionExt = arch == 'x64' ? '-linux64' : '-linux32';
|
||||
ext = 'tar.gz';
|
||||
}
|
||||
else {
|
||||
throw new Error(`Platform ${osPlat} is not supported`);
|
||||
}
|
||||
return `julia-latest${versionExt}.${ext}`;
|
||||
return `julia-latest${versionExt}.${fileExt1}`;
|
||||
}
|
||||
function getFileInfo(versionInfo, version, arch) {
|
||||
const err = `Could not find ${archMap[arch]}/${version} binaries`;
|
||||
let fileExt1;
|
||||
let hasFileExt2;
|
||||
let fileExt2;
|
||||
[fileExt1, hasFileExt2, fileExt2] = getDesiredFileExts();
|
||||
if (version.endsWith('nightly')) {
|
||||
return null;
|
||||
}
|
||||
@@ -137,7 +161,19 @@ function getFileInfo(versionInfo, version, arch) {
|
||||
}
|
||||
for (let file of versionInfo[version].files) {
|
||||
if (file.os == osMap[osPlat] && file.arch == archMap[arch]) {
|
||||
return file;
|
||||
if (file.extension == fileExt1) {
|
||||
return file;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (hasFileExt2) {
|
||||
core.debug(`Could not find ${fileExt1}; trying to find ${fileExt2} instead`);
|
||||
for (let file of versionInfo[version].files) {
|
||||
if (file.os == osMap[osPlat] && file.arch == archMap[arch]) {
|
||||
if (file.extension == fileExt2) {
|
||||
return file;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
throw err;
|
||||
@@ -204,9 +240,17 @@ function installJulia(versionInfo, version, arch) {
|
||||
}
|
||||
return tempInstallDir;
|
||||
case 'darwin':
|
||||
yield exec.exec('hdiutil', ['attach', juliaDownloadPath]);
|
||||
yield exec.exec('/bin/bash', ['-c', `cp -a /Volumes/Julia-*/Julia-*.app/Contents/Resources/julia ${tempInstallDir}`]);
|
||||
return path.join(tempInstallDir, 'julia');
|
||||
if (fileInfo !== null && fileInfo.extension == 'dmg') {
|
||||
core.debug(`Support for .dmg files is deprecated and may be removed in a future release`);
|
||||
yield exec.exec('hdiutil', ['attach', juliaDownloadPath]);
|
||||
yield exec.exec('/bin/bash', ['-c', `cp -a /Volumes/Julia-*/Julia-*.app/Contents/Resources/julia ${tempInstallDir}`]);
|
||||
return path.join(tempInstallDir, 'julia');
|
||||
}
|
||||
else {
|
||||
// tc.extractTar doesn't support stripping components, so we have to call tar manually
|
||||
yield exec.exec('tar', ['xf', juliaDownloadPath, '--strip-components=1', '-C', tempInstallDir]);
|
||||
return tempInstallDir;
|
||||
}
|
||||
default:
|
||||
throw new Error(`Platform ${osPlat} is not supported`);
|
||||
}
|
||||
|
||||
13
lib/setup-julia.js
generated
13
lib/setup-julia.js
generated
@@ -21,6 +21,14 @@ const fs = __importStar(require("fs"));
|
||||
const https = __importStar(require("https"));
|
||||
const path = __importStar(require("path"));
|
||||
const installer = __importStar(require("./installer"));
|
||||
const archSynonyms = {
|
||||
'x86': 'x86',
|
||||
'X86': 'x86',
|
||||
'x64': 'x64',
|
||||
'X64': 'x64',
|
||||
'aarch64': 'aarch64',
|
||||
'ARM64': 'aarch64'
|
||||
};
|
||||
function run() {
|
||||
return __awaiter(this, void 0, void 0, function* () {
|
||||
try {
|
||||
@@ -41,7 +49,7 @@ function run() {
|
||||
}
|
||||
// Inputs
|
||||
const versionInput = core.getInput('version');
|
||||
const arch = core.getInput('arch');
|
||||
const originalArchInput = core.getInput('arch');
|
||||
// It can easily happen that, for example, a workflow file contains an input `version: ${{ matrix.julia-version }}`
|
||||
// while the strategy matrix only contains a key `${{ matrix.version }}`.
|
||||
// In that case, we want the action to fail, rather than trying to download julia from an URL that's missing parts and 404ing.
|
||||
@@ -50,9 +58,10 @@ function run() {
|
||||
if (!versionInput) {
|
||||
throw new Error('Version input must not be null');
|
||||
}
|
||||
if (!arch) {
|
||||
if (!originalArchInput) {
|
||||
throw new Error(`Arch input must not be null`);
|
||||
}
|
||||
const arch = archSynonyms[originalArchInput];
|
||||
const versionInfo = yield installer.getJuliaVersionInfo();
|
||||
const availableReleases = yield installer.getJuliaVersions(versionInfo);
|
||||
const version = installer.getJuliaVersion(availableReleases, versionInput);
|
||||
|
||||
7
package-lock.json
generated
7
package-lock.json
generated
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "setup-julia",
|
||||
"version": "1.8.0",
|
||||
"version": "1.8.2",
|
||||
"lockfileVersion": 2,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "setup-julia",
|
||||
"version": "1.6.1",
|
||||
"version": "1.8.2",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@actions/core": "^1.2.6",
|
||||
@@ -12927,8 +12927,7 @@
|
||||
"version": "1.2.1",
|
||||
"resolved": "https://registry.npmjs.org/jest-pnp-resolver/-/jest-pnp-resolver-1.2.1.tgz",
|
||||
"integrity": "sha512-pgFw2tm54fzgYvc/OHrnysABEObZCUNFnhjoRjaVOCN8NYc032/gVjPaHD4Aq6ApkSieWtfKAFQtmDKAmhupnQ==",
|
||||
"dev": true,
|
||||
"requires": {}
|
||||
"dev": true
|
||||
},
|
||||
"jest-regex-util": {
|
||||
"version": "24.3.0",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "setup-julia",
|
||||
"version": "1.8.0",
|
||||
"version": "1.8.2",
|
||||
"private": true,
|
||||
"description": "setup Julia action",
|
||||
"main": "lib/setup-julia.js",
|
||||
|
||||
@@ -18,11 +18,8 @@ const osMap = {
|
||||
}
|
||||
const archMap = {
|
||||
'x86': 'i686',
|
||||
'X86': 'i686',
|
||||
'x64': 'x86_64',
|
||||
'X64': 'x86_64',
|
||||
'aarch64': 'aarch64',
|
||||
'ARM64': 'aarch64'
|
||||
'aarch64': 'aarch64'
|
||||
}
|
||||
|
||||
// Store information about the environment
|
||||
@@ -96,31 +93,59 @@ export function getJuliaVersion(availableReleases: string[], versionInput: strin
|
||||
return version
|
||||
}
|
||||
|
||||
function getDesiredFileExts(): [string, boolean, string] {
|
||||
let fileExt1: string
|
||||
let hasFileExt2: boolean
|
||||
let fileExt2: string
|
||||
|
||||
if (osPlat == 'win32') {
|
||||
fileExt1 = 'exe'
|
||||
hasFileExt2 = false
|
||||
fileExt2 = ''
|
||||
} else if (osPlat == 'darwin') {
|
||||
fileExt1 = 'tar.gz'
|
||||
hasFileExt2 = true
|
||||
fileExt2 = 'dmg'
|
||||
} else if (osPlat === 'linux') {
|
||||
fileExt1 = 'tar.gz'
|
||||
hasFileExt2 = false
|
||||
fileExt2 = ''
|
||||
} else {
|
||||
throw new Error(`Platform ${osPlat} is not supported`)
|
||||
}
|
||||
|
||||
return [fileExt1, hasFileExt2, fileExt2]
|
||||
}
|
||||
|
||||
function getNightlyFileName(arch: string): string {
|
||||
let versionExt: string, ext: string
|
||||
let versionExt: string
|
||||
let fileExt1: string
|
||||
[fileExt1, , ] = getDesiredFileExts()
|
||||
|
||||
if (osPlat == 'win32') {
|
||||
versionExt = arch == 'x64' ? '-win64' : '-win32'
|
||||
ext = 'exe'
|
||||
} else if (osPlat == 'darwin') {
|
||||
if (arch == 'x86') {
|
||||
throw new Error('32-bit Julia is not available on macOS')
|
||||
}
|
||||
versionExt = '-mac64'
|
||||
ext = 'dmg'
|
||||
} else if (osPlat === 'linux') {
|
||||
versionExt = arch == 'x64' ? '-linux64' : '-linux32'
|
||||
ext = 'tar.gz'
|
||||
} else {
|
||||
throw new Error(`Platform ${osPlat} is not supported`)
|
||||
}
|
||||
|
||||
return `julia-latest${versionExt}.${ext}`
|
||||
return `julia-latest${versionExt}.${fileExt1}`
|
||||
}
|
||||
|
||||
export function getFileInfo(versionInfo, version: string, arch: string) {
|
||||
const err = `Could not find ${archMap[arch]}/${version} binaries`
|
||||
|
||||
let fileExt1: string
|
||||
let hasFileExt2: boolean
|
||||
let fileExt2: string
|
||||
[fileExt1, hasFileExt2, fileExt2] = getDesiredFileExts()
|
||||
|
||||
if (version.endsWith('nightly')) {
|
||||
return null
|
||||
}
|
||||
@@ -131,7 +156,20 @@ export function getFileInfo(versionInfo, version: string, arch: string) {
|
||||
|
||||
for (let file of versionInfo[version].files) {
|
||||
if (file.os == osMap[osPlat] && file.arch == archMap[arch]) {
|
||||
return file
|
||||
if (file.extension == fileExt1) {
|
||||
return file
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (hasFileExt2) {
|
||||
core.debug(`Could not find ${fileExt1}; trying to find ${fileExt2} instead`)
|
||||
for (let file of versionInfo[version].files) {
|
||||
if (file.os == osMap[osPlat] && file.arch == archMap[arch]) {
|
||||
if (file.extension == fileExt2) {
|
||||
return file
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -175,7 +213,6 @@ export async function installJulia(versionInfo, version: string, arch: string):
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
// Verify checksum
|
||||
if (!version.endsWith('nightly')) {
|
||||
const checkSum = await calculateChecksum(juliaDownloadPath)
|
||||
@@ -204,9 +241,16 @@ export async function installJulia(versionInfo, version: string, arch: string):
|
||||
}
|
||||
return tempInstallDir
|
||||
case 'darwin':
|
||||
await exec.exec('hdiutil', ['attach', juliaDownloadPath])
|
||||
await exec.exec('/bin/bash', ['-c', `cp -a /Volumes/Julia-*/Julia-*.app/Contents/Resources/julia ${tempInstallDir}`])
|
||||
return path.join(tempInstallDir, 'julia')
|
||||
if (fileInfo !== null && fileInfo.extension == 'dmg') {
|
||||
core.debug(`Support for .dmg files is deprecated and may be removed in a future release`)
|
||||
await exec.exec('hdiutil', ['attach', juliaDownloadPath])
|
||||
await exec.exec('/bin/bash', ['-c', `cp -a /Volumes/Julia-*/Julia-*.app/Contents/Resources/julia ${tempInstallDir}`])
|
||||
return path.join(tempInstallDir, 'julia')
|
||||
} else {
|
||||
// tc.extractTar doesn't support stripping components, so we have to call tar manually
|
||||
await exec.exec('tar', ['xf', juliaDownloadPath, '--strip-components=1', '-C', tempInstallDir])
|
||||
return tempInstallDir
|
||||
}
|
||||
default:
|
||||
throw new Error(`Platform ${osPlat} is not supported`)
|
||||
}
|
||||
|
||||
@@ -8,6 +8,15 @@ import * as path from 'path'
|
||||
|
||||
import * as installer from './installer'
|
||||
|
||||
const archSynonyms = {
|
||||
'x86': 'x86',
|
||||
'X86': 'x86',
|
||||
'x64': 'x64',
|
||||
'X64': 'x64',
|
||||
'aarch64': 'aarch64',
|
||||
'ARM64': 'aarch64'
|
||||
}
|
||||
|
||||
async function run() {
|
||||
try {
|
||||
// Debugging info
|
||||
@@ -30,7 +39,7 @@ async function run() {
|
||||
|
||||
// Inputs
|
||||
const versionInput = core.getInput('version')
|
||||
const arch = core.getInput('arch')
|
||||
const originalArchInput = core.getInput('arch')
|
||||
|
||||
// It can easily happen that, for example, a workflow file contains an input `version: ${{ matrix.julia-version }}`
|
||||
// while the strategy matrix only contains a key `${{ matrix.version }}`.
|
||||
@@ -40,10 +49,12 @@ async function run() {
|
||||
if (!versionInput) {
|
||||
throw new Error('Version input must not be null')
|
||||
}
|
||||
if (!arch) {
|
||||
if (!originalArchInput) {
|
||||
throw new Error(`Arch input must not be null`)
|
||||
}
|
||||
|
||||
const arch = archSynonyms[originalArchInput]
|
||||
|
||||
const versionInfo = await installer.getJuliaVersionInfo()
|
||||
const availableReleases = await installer.getJuliaVersions(versionInfo)
|
||||
const version = installer.getJuliaVersion(availableReleases, versionInput)
|
||||
|
||||
Reference in New Issue
Block a user