From 5184a22826d340ad17ab67bf52a2da94d65675e4 Mon Sep 17 00:00:00 2001 From: Volodymyr Zotov Date: Wed, 30 Jul 2025 12:56:39 -0500 Subject: [PATCH] Fix lint errors --- configure/dist/index.js | 34 +++++++++------------------------- configure/index.js | 34 +++++++++------------------------- 2 files changed, 18 insertions(+), 50 deletions(-) diff --git a/configure/dist/index.js b/configure/dist/index.js index b0c0dad..5f9eb06 100644 --- a/configure/dist/index.js +++ b/configure/dist/index.js @@ -27555,17 +27555,18 @@ module.exports = parseParams /******/ /************************************************************************/ var __webpack_exports__ = {}; -// const fs = require("fs"); -// const os = require("os"); const core = __nccwpck_require__(7484); -// configure manually appends env vars to GITHUB_ENV variable -// We cannot use `core.exportVariable` because it will set env var for the current process -// therefore those env vars will not be available for the next steps in the workflow const configure = () => { - const OP_CONNECT_HOST = core.getInput("connect-host", { required: false }) || process.env.OP_CONNECT_HOST; - const OP_CONNECT_TOKEN = core.getInput("connect-token", { required: false }) || process.env.OP_CONNECT_TOKEN; - const OP_SERVICE_ACCOUNT_TOKEN = core.getInput("service-account-token", { required: false }) || process.env.OP_SERVICE_ACCOUNT_TOKEN; + const OP_CONNECT_HOST = + core.getInput("connect-host", { required: false }) || + process.env.OP_CONNECT_HOST; + const OP_CONNECT_TOKEN = + core.getInput("connect-token", { required: false }) || + process.env.OP_CONNECT_TOKEN; + const OP_SERVICE_ACCOUNT_TOKEN = + core.getInput("service-account-token", { required: false }) || + process.env.OP_SERVICE_ACCOUNT_TOKEN; if (OP_CONNECT_HOST) { core.exportVariable("OP_CONNECT_HOST", OP_CONNECT_HOST); @@ -27578,23 +27579,6 @@ const configure = () => { if (OP_SERVICE_ACCOUNT_TOKEN) { core.exportVariable("OP_SERVICE_ACCOUNT_TOKEN", OP_SERVICE_ACCOUNT_TOKEN); } - // const githubEnvPath = process.env["GITHUB_ENV"]; - // if (!githubEnvPath) { - // core.setFailed("GITHUB_ENV is not defined"); - // return; - // } - // - // const setEnv = (key, value) => { - // if (value) { - // fs.appendFileSync(githubEnvPath, `${key}=${value}${os.EOL}`, { - // encoding: "utf8", - // }); - // } - // }; - // - // setEnv("OP_CONNECT_HOST", OP_CONNECT_HOST); - // setEnv("OP_CONNECT_TOKEN", OP_CONNECT_TOKEN); - // setEnv("OP_SERVICE_ACCOUNT_TOKEN", OP_SERVICE_ACCOUNT_TOKEN); }; configure(); diff --git a/configure/index.js b/configure/index.js index 0c6009f..5f3485d 100644 --- a/configure/index.js +++ b/configure/index.js @@ -1,14 +1,15 @@ -// const fs = require("fs"); -// const os = require("os"); const core = require("@actions/core"); -// configure manually appends env vars to GITHUB_ENV variable -// We cannot use `core.exportVariable` because it will set env var for the current process -// therefore those env vars will not be available for the next steps in the workflow const configure = () => { - const OP_CONNECT_HOST = core.getInput("connect-host", { required: false }) || process.env.OP_CONNECT_HOST; - const OP_CONNECT_TOKEN = core.getInput("connect-token", { required: false }) || process.env.OP_CONNECT_TOKEN; - const OP_SERVICE_ACCOUNT_TOKEN = core.getInput("service-account-token", { required: false }) || process.env.OP_SERVICE_ACCOUNT_TOKEN; + const OP_CONNECT_HOST = + core.getInput("connect-host", { required: false }) || + process.env.OP_CONNECT_HOST; + const OP_CONNECT_TOKEN = + core.getInput("connect-token", { required: false }) || + process.env.OP_CONNECT_TOKEN; + const OP_SERVICE_ACCOUNT_TOKEN = + core.getInput("service-account-token", { required: false }) || + process.env.OP_SERVICE_ACCOUNT_TOKEN; if (OP_CONNECT_HOST) { core.exportVariable("OP_CONNECT_HOST", OP_CONNECT_HOST); @@ -21,23 +22,6 @@ const configure = () => { if (OP_SERVICE_ACCOUNT_TOKEN) { core.exportVariable("OP_SERVICE_ACCOUNT_TOKEN", OP_SERVICE_ACCOUNT_TOKEN); } - // const githubEnvPath = process.env["GITHUB_ENV"]; - // if (!githubEnvPath) { - // core.setFailed("GITHUB_ENV is not defined"); - // return; - // } - // - // const setEnv = (key, value) => { - // if (value) { - // fs.appendFileSync(githubEnvPath, `${key}=${value}${os.EOL}`, { - // encoding: "utf8", - // }); - // } - // }; - // - // setEnv("OP_CONNECT_HOST", OP_CONNECT_HOST); - // setEnv("OP_CONNECT_TOKEN", OP_CONNECT_TOKEN); - // setEnv("OP_SERVICE_ACCOUNT_TOKEN", OP_SERVICE_ACCOUNT_TOKEN); }; configure();