mirror of
https://github.com/julia-actions/setup-julia.git
synced 2026-02-17 05:26:53 +08:00
Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
0a6460c824 |
12
dist/index.js
vendored
12
dist/index.js
vendored
@@ -3777,20 +3777,8 @@ const installer = __importStar(__webpack_require__(749));
|
|||||||
function run() {
|
function run() {
|
||||||
return __awaiter(this, void 0, void 0, function* () {
|
return __awaiter(this, void 0, void 0, function* () {
|
||||||
try {
|
try {
|
||||||
// Inputs
|
|
||||||
const versionInput = core.getInput('version');
|
const versionInput = core.getInput('version');
|
||||||
const arch = core.getInput('arch');
|
const arch = 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.
|
|
||||||
// We _could_ fall back to the default but that means that builds silently do things differently than they're meant to, which
|
|
||||||
// is worse than failing the build.
|
|
||||||
if (!versionInput) {
|
|
||||||
throw new Error('Version input must not be null');
|
|
||||||
}
|
|
||||||
if (!arch) {
|
|
||||||
throw new Error(`Arch input must not be null`);
|
|
||||||
}
|
|
||||||
const availableReleases = installer.juliaVersions;
|
const availableReleases = installer.juliaVersions;
|
||||||
const version = installer.getJuliaVersion(availableReleases, versionInput);
|
const version = installer.getJuliaVersion(availableReleases, versionInput);
|
||||||
core.debug(`selected Julia version: ${arch}/${version}`);
|
core.debug(`selected Julia version: ${arch}/${version}`);
|
||||||
|
|||||||
12
lib/setup-julia.js
generated
12
lib/setup-julia.js
generated
@@ -23,20 +23,8 @@ const installer = __importStar(require("./installer"));
|
|||||||
function run() {
|
function run() {
|
||||||
return __awaiter(this, void 0, void 0, function* () {
|
return __awaiter(this, void 0, void 0, function* () {
|
||||||
try {
|
try {
|
||||||
// Inputs
|
|
||||||
const versionInput = core.getInput('version');
|
const versionInput = core.getInput('version');
|
||||||
const arch = core.getInput('arch');
|
const arch = 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.
|
|
||||||
// We _could_ fall back to the default but that means that builds silently do things differently than they're meant to, which
|
|
||||||
// is worse than failing the build.
|
|
||||||
if (!versionInput) {
|
|
||||||
throw new Error('Version input must not be null');
|
|
||||||
}
|
|
||||||
if (!arch) {
|
|
||||||
throw new Error(`Arch input must not be null`);
|
|
||||||
}
|
|
||||||
const availableReleases = installer.juliaVersions;
|
const availableReleases = installer.juliaVersions;
|
||||||
const version = installer.getJuliaVersion(availableReleases, versionInput);
|
const version = installer.getJuliaVersion(availableReleases, versionInput);
|
||||||
core.debug(`selected Julia version: ${arch}/${version}`);
|
core.debug(`selected Julia version: ${arch}/${version}`);
|
||||||
|
|||||||
2
package-lock.json
generated
2
package-lock.json
generated
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "setup-julia",
|
"name": "setup-julia",
|
||||||
"version": "1.1.11",
|
"version": "1.1.10",
|
||||||
"lockfileVersion": 1,
|
"lockfileVersion": 1,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "setup-julia",
|
"name": "setup-julia",
|
||||||
"version": "1.1.11",
|
"version": "1.1.10",
|
||||||
"private": true,
|
"private": true,
|
||||||
"description": "setup Julia action",
|
"description": "setup Julia action",
|
||||||
"main": "lib/setup-julia.js",
|
"main": "lib/setup-julia.js",
|
||||||
|
|||||||
@@ -8,22 +8,8 @@ import * as installer from './installer'
|
|||||||
|
|
||||||
async function run() {
|
async function run() {
|
||||||
try {
|
try {
|
||||||
// Inputs
|
|
||||||
const versionInput = core.getInput('version')
|
const versionInput = core.getInput('version')
|
||||||
const arch = core.getInput('arch')
|
const arch = 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.
|
|
||||||
// We _could_ fall back to the default but that means that builds silently do things differently than they're meant to, which
|
|
||||||
// is worse than failing the build.
|
|
||||||
if (!versionInput) {
|
|
||||||
throw new Error('Version input must not be null')
|
|
||||||
}
|
|
||||||
if (!arch) {
|
|
||||||
throw new Error(`Arch input must not be null`)
|
|
||||||
}
|
|
||||||
|
|
||||||
const availableReleases = installer.juliaVersions
|
const availableReleases = installer.juliaVersions
|
||||||
const version = installer.getJuliaVersion(availableReleases, versionInput)
|
const version = installer.getJuliaVersion(availableReleases, versionInput)
|
||||||
core.debug(`selected Julia version: ${arch}/${version}`)
|
core.debug(`selected Julia version: ${arch}/${version}`)
|
||||||
|
|||||||
Reference in New Issue
Block a user