Skip to content

Commit

Permalink
consume latest packages v3.6.2
Browse files Browse the repository at this point in the history
  • Loading branch information
lukka committed Apr 22, 2023
1 parent 1e613c0 commit e6f2e16
Show file tree
Hide file tree
Showing 3 changed files with 95 additions and 70 deletions.
33 changes: 29 additions & 4 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -4969,6 +4969,26 @@ class BaseUtilLib {
this.baseLib.info(`Set the step output variable '${name}' to value '${value}''`);
this.baseLib.setOutput(name, value);
}
/**
* Set a workflow variable if not set already.
* @param name The name of the variable.
* @param value The value.
*/
setVariableIfUndefined(name, value) {
this.baseLib.debug(`setVariableIfUndefined()<<`);
if (!process.env[name]) {
if (!value) {
this.baseLib.warning(`Cannot set '${name}' variable because the provided value is null.`);
}
else {
this.setVariableVerbose(name, value);
}
}
else {
this.baseLib.debug(`${name} is already set to: '${value}'`);
}
this.baseLib.debug(`setVariableIfUndefined()>>`);
}
}
exports.BaseUtilLib = BaseUtilLib;
class Matcher {
Expand Down Expand Up @@ -5585,7 +5605,7 @@ __exportStar(__nccwpck_require__(6188), exports);
// Released under the term specified in file LICENSE.txt
// SPDX short identifier: MIT
Object.defineProperty(exports, "__esModule", ({ value: true }));
exports.VCPKG_BINARY_SOURCES = exports.VCPKG_INSTALLED_DIR = exports.VCPKG_JSON = exports.VCPKGDEFAULTTRIPLET = exports.VCPKGROOT = exports.vcpkgLastBuiltCommitId = exports.RUNVCPKG_VCPKG_DEFAULT_TRIPLET = exports.RUNVCPKG_VCPKG_ROOT = void 0;
exports.ACTIONS_RUNTIME_TOKEN = exports.ACTIONS_CACHE_URL = exports.VCPKG_BINARY_SOURCES = exports.VCPKG_INSTALLED_DIR = exports.VCPKG_JSON = exports.VCPKGDEFAULTTRIPLET = exports.VCPKGROOT = exports.vcpkgLastBuiltCommitId = exports.RUNVCPKG_VCPKG_DEFAULT_TRIPLET = exports.RUNVCPKG_VCPKG_ROOT = void 0;
exports.RUNVCPKG_VCPKG_ROOT = "RUNVCPKG_VCPKG_ROOT";
exports.RUNVCPKG_VCPKG_DEFAULT_TRIPLET = "RUNVCPKG_VCPKG_DEFAULT_TRIPLET";
exports.vcpkgLastBuiltCommitId = 'vcpkgLastBuiltCommitId';
Expand All @@ -5594,6 +5614,8 @@ exports.VCPKGDEFAULTTRIPLET = "VCPKG_DEFAULT_TRIPLET";
exports.VCPKG_JSON = "vcpkg.json";
exports.VCPKG_INSTALLED_DIR = "VCPKG_INSTALLED_DIR";
exports.VCPKG_BINARY_SOURCES = `VCPKG_BINARY_SOURCES`;
exports.ACTIONS_CACHE_URL = `ACTIONS_CACHE_URL`;
exports.ACTIONS_RUNTIME_TOKEN = `ACTIONS_RUNTIME_TOKEN`;
//# sourceMappingURL=vcpkg-globals.js.map

/***/ }),
Expand Down Expand Up @@ -5718,9 +5740,12 @@ class VcpkgRunner {
// If running in a GitHub Runner, enable the GH's cache provider for the vcpkg's binary cache.
if (process.env['GITHUB_ACTIONS'] === 'true') {
yield this.baseUtils.wrapOp(`Setup to run on GitHub Action runners`, () => __awaiter(this, void 0, void 0, function* () {
// Allow users to define the vcpkg's binary source explicitly in the workflow, in that case don't override it.
if (!process.env[globals.VCPKG_BINARY_SOURCES])
this.baseUtils.setVariableVerbose(globals.VCPKG_BINARY_SOURCES, VcpkgRunner.VCPKG_BINARY_SOURCES_GHA);
// Allow users to define the vcpkg's binary source explicitly in the workflow, in that case do not override it.
this.baseUtils.setVariableIfUndefined(globals.VCPKG_BINARY_SOURCES, VcpkgRunner.VCPKG_BINARY_SOURCES_GHA);
if (process.env.ACTIONS_CACHE_URL)
this.baseUtils.setVariableVerbose(globals.ACTIONS_CACHE_URL, process.env.ACTIONS_CACHE_URL);
if (process.env.ACTIONS_RUNTIME_TOKEN)
this.baseUtils.setVariableVerbose(globals.ACTIONS_RUNTIME_TOKEN, process.env.ACTIONS_RUNTIME_TOKEN);
}));
}
// Ensuring `this.vcpkgDestPath` is existent, since is going to be used as current working directory.
Expand Down
122 changes: 61 additions & 61 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,11 @@
"@actions/exec": "^1.0.3",
"@actions/github": "^4.0.0",
"@actions/io": "^1.0.2",
"@lukka/action-lib": "3.6.1",
"@lukka/assets-lib": "3.6.1",
"@lukka/base-lib": "3.6.1",
"@lukka/base-util-lib": "3.6.1",
"@lukka/run-cmake-lib": "3.6.1",
"@lukka/action-lib": "3.6.2",
"@lukka/assets-lib": "3.6.2",
"@lukka/base-lib": "3.6.2",
"@lukka/base-util-lib": "3.6.2",
"@lukka/run-cmake-lib": "3.6.2",
"@types/adm-zip": "^0.4.32",
"@types/follow-redirects": "^1.8.0",
"@types/jest": "^26.0.14",
Expand Down

0 comments on commit e6f2e16

Please sign in to comment.