text: var __create = Object.create;
  var __defProp = Object.defineProperty;
  var __defProps = Object.defineProperties;
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
  var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
  var __getOwnPropNames = Object.getOwnPropertyNames;
  var __getOwnPropSymbols = Object.getOwnPropertySymbols;
  var __getProtoOf = Object.getPrototypeOf;
  var __hasOwnProp = Object.prototype.hasOwnProperty;
  var __propIsEnum = Object.prototype.propertyIsEnumerable;
  var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
  var __spreadValues = (a, b) => {
    for (var prop in b || (b = {}))
      if (__hasOwnProp.call(b, prop))
        __defNormalProp(a, prop, b[prop]);
    if (__getOwnPropSymbols)
      for (var prop of __getOwnPropSymbols(b)) {
        if (__propIsEnum.call(b, prop))
          __defNormalProp(a, prop, b[prop]);
      }
    return a;
  };
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
  var __markAsModule = (target) => __defProp(target, "__esModule", { value: true });
  var __commonJS = (cb, mod) => function __require() {
    return mod || (0, cb[Object.keys(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
  };
  var __reExport = (target, module2, desc) => {
    if (module2 && typeof module2 === "object" || typeof module2 === "function") {
      for (let key of __getOwnPropNames(module2))
        if (!__hasOwnProp.call(target, key) && key !== "default")
          __defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable });
    }
    return target;
  };
  var __toModule = (module2) => {
    return __reExport(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", module2 && module2.__esModule && "default" in module2 ? { get: () => module2.default, enumerable: true } : { value: module2, enumerable: true })), module2);
  };
  
  // node_modules/@actions/core/lib/utils.js
  var require_utils = __commonJS({
    "node_modules/@actions/core/lib/utils.js"(exports2) {
      "use strict";
      Object.defineProperty(exports2, "__esModule", { value: true });
      exports2.toCommandProperties = exports2.toCommandValue = void 0;
      function toCommandValue(input) {
        if (input === null || input === void 0) {
          return "";
        } else if (typeof input === "string" || input instanceof String) {
          return input;
        }
        return JSON.stringify(input);
      }
      exports2.toCommandValue = toCommandValue;
      function toCommandProperties(annotationProperties) {
        if (!Object.keys(annotationProperties).length) {
          return {};
        }
        return {
          title: annotationProperties.title,
          file: annotationProperties.file,
          line: annotationProperties.startLine,
          endLine: annotationProperties.endLine,
          col: annotationProperties.startColumn,
          endColumn: annotationProperties.endColumn
        };
      }
      exports2.toCommandProperties = toCommandProperties;
    }
  });
  
  // node_modules/@actions/core/lib/command.js
  var require_command = __commonJS({
    "node_modules/@actions/core/lib/command.js"(exports2) {
      "use strict";
      var __createBinding = exports2 && exports2.__createBinding || (Object.create ? function(o, m, k, k2) {
        if (k2 === void 0)
          k2 = k;
        Object.defineProperty(o, k2, { enumerable: true, get: function() {
          return m[k];
        } });
      } : function(o, m, k, k2) {
        if (k2 === void 0)
          k2 = k;
        o[k2] = m[k];
      });
      var __setModuleDefault = exports2 && exports2.__setModuleDefault || (Object.create ? function(o, v) {
        Object.defineProperty(o, "default", { enumerable: true, value: v });
      } : function(o, v) {
        o["default"] = v;
      });
      var __importStar = exports2 && exports2.__importStar || function(mod) {
        if (mod && mod.__esModule)
          return mod;
        var result = {};
        if (mod != null) {
          for (var k in mod)
            if (k !== "default" && Object.hasOwnProperty.call(mod, k))
              __createBinding(result, mod, k);
        }
        __setModuleDefault(result, mod);
        return result;
      };
      Object.defineProperty(exports2, "__esModule", { value: true });
      exports2.issue = exports2.issueCommand = void 0;
      var os = __importStar(require("os"));
      var utils_1 = require_utils();
      function issueCommand(command, properties, message) {
        const cmd = new Command(command, properties, message);
        process.stdout.write(cmd.toString() + os.EOL);
      }
      exports2.issueCommand = issueCommand;
      function issue(name, message = "") {
        issueCommand(name, {}, message);
      }
      exports2.issue = issue;
      var CMD_STRING = "::";
      var Command = class {
        constructor(command, properties, message) {
          if (!command) {
            command = "missing.command";
          }
          this.command = command;
          this.properties = properties;
          this.message = message;
        }
        toString() {
          let cmdStr = CMD_STRING + this.command;
          if (this.properties && Object.keys(this.properties).length > 0) {
            cmdStr += " ";
            let first = true;
            for (const key in this.properties) {
              if (this.properties.hasOwnProperty(key)) {
                const val = this.properties[key];
                if (val) {
                  if (first) {
                    first = false;
                  } else {
                    cmdStr += ",";
                  }
                  cmdStr += `${key}=${escapeProperty(val)}`;
                }
              }
            }
          }
          cmdStr += `${CMD_STRING}${escapeData(this.message)}`;
          return cmdStr;
        }
      };
      function escapeData(s) {
        return utils_1.toCommandValue(s).replace(/%/g, "%25").replace(/\r/g, "%0D").replace(/\n/g, "%0A");
      }
      function escapeProperty(s) {
        return utils_1.toCommandValue(s).replace(/%/g, "%25").replace(/\r/g, "%0D").replace(/\n/g, "%0A").replace(/:/g, "%3A").replace(/,/g, "%2C");
      }
    }
  });
  
  // node_modules/@actions/core/lib/file-command.js
  var require_file_command = __commonJS({
    "node_modules/@actions/core/lib/file-command.js"(exports2) {
      "use strict";
      var __createBinding = exports2 && exports2.__createBinding || (Object.create ? function(o, m, k, k2) {
        if (k2 === void 0)
          k2 = k;
        Object.defineProperty(o, k2, { enumerable: true, get: function() {
          return m[k];
        } });
      } : function(o, m, k, k2) {
        if (k2 === void 0)
          k2 = k;
        o[k2] = m[k];
      });
      var __setModuleDefault = exports2 && exports2.__setModuleDefault || (Object.create ? function(o, v) {
        Object.defineProperty(o, "default", { enumerable: true, value: v });
      } : function(o, v) {
        o["default"] = v;
      });
      var __importStar = exports2 && exports2.__importStar || function(mod) {
        if (mod && mod.__esModule)
          return mod;
        var result = {};
        if (mod != null) {
          for (var k in mod)
            if (k !== "default" && Object.hasOwnProperty.call(mod, k))
              __createBinding(result, mod, k);
        }
        __setModuleDefault(result, mod);
        return result;
      };
      Object.defineProperty(exports2, "__esModule", { value: true });
      exports2.issueCommand = void 0;
      var fs = __importStar(require("fs"));
      var os = __importStar(require("os"));
      var utils_1 = require_utils();
      function issueCommand(command, message) {
        const filePath = process.env[`GITHUB_${command}`];
        if (!filePath) {
          throw new Error(`Unable to find environment variable for file command ${command}`);
        }
        if (!fs.existsSync(filePath)) {
          throw new Error(`Missing file at path: ${filePath}`);
        }
        fs.appendFileSync(filePath, `${utils_1.toCommandValue(message)}${os.EOL}`, {
          encoding: "utf8"
        });
      }
      exports2.issueCommand = issueCommand;
    }
  });
  
  // node_modules/@actions/http-client/proxy.js
  var require_proxy = __commonJS({
    "node_modules/@actions/http-client/proxy.js"(exports2) {
      "use strict";
      Object.defineProperty(exports2, "__esModule", { value: true });
      function getProxyUrl(reqUrl) {
        let usingSsl = reqUrl.protocol === "https:";
        let proxyUrl;
        if (checkBypass(reqUrl)) {
          return proxyUrl;
        }
        let proxyVar;
        if (usingSsl) {
          proxyVar = process.env["https_proxy"] || process.env["HTTPS_PROXY"];
        } else {
          proxyVar = process.env["http_proxy"] || process.env["HTTP_PROXY"];
        }
        if (proxyVar) {
          proxyUrl = new URL(proxyVar);
        }
        return proxyUrl;
      }
      exports2.getProxyUrl = getProxyUrl;
      function checkBypass(reqUrl) {
        if (!reqUrl.hostname) {
          return false;
        }
        let noProxy = process.env["no_proxy"] || process.env["NO_PROXY"] || "";
        if (!noProxy) {
          return false;
        }
        let reqPort;
        if (reqUrl.port) {
          reqPort = Number(reqUrl.port);
        } else if (reqUrl.protocol === "http:") {
          reqPort = 80;
        } else if (reqUrl.protocol === "https:") {
          reqPort = 443;
        }
        let upperReqHosts = [reqUrl.hostname.toUpperCase()];
        if (typeof reqPort === "number") {
          upperReqHosts.push(`${upperReqHosts[0]}:${reqPort}`);
        }
        for (let upperNoProxyItem of noProxy.split(",").map((x) => x.trim().toUpperCase()).filter((x) => x)) {
          if (upperReqHosts.some((x) => x === upperNoProxyItem)) {
            return true;
          }
        }
        return false;
      }
      exports2.checkBypass = checkBypass;
    }
  });
  
  // node_modules/tunnel/lib/tunnel.js
  var require_tunnel = __commonJS({
    "node_modules/tunnel/lib/tunnel.js"(exports2) {
      "use strict";
      var net = require("net");
      var tls = require("tls");
      var http = require("http");
      var https = require("https");
      var events = require("events");
      var assert = require("assert");
      var util = require("util");
      exports2.httpOverHttp = httpOverHttp;
      exports2.httpsOverHttp = httpsOverHttp;
      exports2.httpOverHttps = httpOverHttps;
      exports2.httpsOverHttps = httpsOverHttps;
      function httpOverHttp(options) {
        var agent = new TunnelingAgent(options);
        agent.request = http.request;
        return agent;
      }
      function httpsOverHttp(options) {
        var agent = new TunnelingAgent(options);
        agent.request = http.request;
        agent.createSocket = createSecureSocket;
        agent.defaultPort = 443;
        return agent;
      }
      function httpOverHttps(options) {
        var agent = new TunnelingAgent(options);
        agent.request = https.request;
        return agent;
      }
      function httpsOverHttps(options) {
        var agent = new TunnelingAgent(options);
        agent.request = https.request;
        agent.createSocket = createSecureSocket;
        agent.defaultPort = 443;
        return agent;
      }
      function TunnelingAgent(options) {
        var self = this;
        self.options = options || {};
        self.proxyOptions = self.options.proxy || {};
        self.maxSockets = self.options.maxSockets || http.Agent.defaultMaxSockets;
        self.requests = [];
        self.sockets = [];
        self.on("free", function onFree(socket, host, port, localAddress) {
          var options2 = toOptions(host, port, localAddress);
          for (var i = 0, len = self.requests.length; i < len; ++i) {
            var pending = self.requests[i];
            if (pending.host === options2.host && pending.port === options2.port) {
              self.requests.splice(i, 1);
              pending.request.onSocket(socket);
              return;
            }
          }
          socket.destroy();
          self.removeSocket(socket);
        });
      }
      util.inherits(TunnelingAgent, events.EventEmitter);
      TunnelingAgent.prototype.addRequest = function addRequest(req, host, port, localAddress) {
        var self = this;
        var options = mergeOptions({ request: req }, self.options, toOptions(host, port, localAddress));
        if (self.sockets.length >= this.maxSockets) {
          self.requests.push(options);
          return;
        }
        self.createSocket(options, function(socket) {
          socket.on("free", onFree);
          socket.on("close", onCloseOrRemove);
          socket.on("agentRemove", onCloseOrRemove);
          req.onSocket(socket);
          function onFree() {
            self.emit("free", socket, options);
          }
          function onCloseOrRemove(err) {
            self.removeSocket(socket);
            socket.removeListener("free", onFree);
            socket.removeListener("close", onCloseOrRemove);
            socket.removeListener("agentRemove", onCloseOrRemove);
          }
        });
      };
      TunnelingAgent.prototype.createSocket = function createSocket(options, cb) {
        var self = this;
        var placeholder = {};
        self.sockets.push(placeholder);
        var connectOptions = mergeOptions({}, self.proxyOptions, {
          method: "CONNECT",
          path: options.host + ":" + options.port,
          agent: false,
          headers: {
            host: options.host + ":" + options.port
          }
        });
        if (options.localAddress) {
          connectOptions.localAddress = options.localAddress;
        }
        if (connectOptions.proxyAuth) {
          connectOptions.headers = connectOptions.headers || {};
          connectOptions.headers["Proxy-Authorization"] = "Basic " + new Buffer(connectOptions.proxyAuth).toString("base64");
        }
        debug("making CONNECT request");
        var connectReq = self.request(connectOptions);
        connectReq.useChunkedEncodingByDefault = false;
        connectReq.once("response", onResponse);
        connectReq.once("upgrade", onUpgrade);
        connectReq.once("connect", onConnect);
        connectReq.once("error", onError);
        connectReq.end();
        function onResponse(res) {
          res.upgrade = true;
        }
        function onUpgrade(res, socket, head) {
          process.nextTick(function() {
            onConnect(res, socket, head);
          });
        }
        function onConnect(res, socket, head) {
          connectReq.removeAllListeners();
          socket.removeAllListeners();
          if (res.statusCode !== 200) {
            debug("tunneling socket could not be established, statusCode=%d", res.statusCode);
            socket.destroy();
            var error = new Error("tunneling socket could not be established, statusCode=" + res.statusCode);
            error.code = "ECONNRESET";
            options.request.emit("error", error);
            self.removeSocket(placeholder);
            return;
          }
          if (head.length > 0) {
            debug("got illegal response body from proxy");
            socket.destroy();
            var error = new Error("got illegal response body from proxy");
            error.code = "ECONNRESET";
            options.request.emit("error", error);
            self.removeSocket(placeholder);
            return;
          }
          debug("tunneling connection has established");
          self.sockets[self.sockets.indexOf(placeholder)] = socket;
          return cb(socket);
        }
        function onError(cause) {
          connectReq.removeAllListeners();
          debug("tunneling socket could not be established, cause=%s\n", cause.message, cause.stack);
          var error = new Error("tunneling socket could not be established, cause=" + cause.message);
          error.code = "ECONNRESET";
          options.request.emit("error", error);
          self.removeSocket(placeholder);
        }
      };
      TunnelingAgent.prototype.removeSocket = function removeSocket(socket) {
        var pos = this.sockets.indexOf(socket);
        if (pos === -1) {
          return;
        }
        this.sockets.splice(pos, 1);
        var pending = this.requests.shift();
        if (pending) {
          this.createSocket(pending, function(socket2) {
            pending.request.onSocket(socket2);
          });
        }
      };
      function createSecureSocket(options, cb) {
        var self = this;
        TunnelingAgent.prototype.createSocket.call(self, options, function(socket) {
          var hostHeader = options.request.getHeader("host");
          var tlsOptions = mergeOptions({}, self.options, {
            socket,
            servername: hostHeader ? hostHeader.replace(/:.*$/, "") : options.host
          });
          var secureSocket = tls.connect(0, tlsOptions);
          self.sockets[self.sockets.indexOf(socket)] = secureSocket;
          cb(secureSocket);
        });
      }
      function toOptions(host, port, localAddress) {
        if (typeof host === "string") {
          return {
            host,
            port,
            localAddress
          };
        }
        return host;
      }
      function mergeOptions(target) {
        for (var i = 1, len = arguments.length; i < len; ++i) {
          var overrides = arguments[i];
          if (typeof overrides === "object") {
            var keys = Object.keys(overrides);
            for (var j = 0, keyLen = keys.length; j < keyLen; ++j) {
              var k = keys[j];
              if (overrides[k] !== void 0) {
                target[k] = overrides[k];
              }
            }
          }
        }
        return target;
      }
      var debug;
      if (process.env.NODE_DEBUG && /\btunnel\b/.test(process.env.NODE_DEBUG)) {
        debug = function() {
          var args = Array.prototype.slice.call(arguments);
          if (typeof args[0] === "string") {
            args[0] = "TUNNEL: " + args[0];
          } else {
            args.unshift("TUNNEL:");
          }
          console.error.apply(console, args);
        };
      } else {
        debug = function() {
        };
      }
      exports2.debug = debug;
    }
  });
  
  // node_modules/tunnel/index.js
  var require_tunnel2 = __commonJS({
    "node_modules/tunnel/index.js"(exports2, module2) {
      module2.exports = require_tunnel();
    }
  });
  
  // node_modules/@actions/http-client/index.js
  var require_http_client = __commonJS({
    "node_modules/@actions/http-client/index.js"(exports2) {
      "use strict";
      Object.defineProperty(exports2, "__esModule", { value: true });
      var http = require("http");
      var https = require("https");
      var pm = require_proxy();
      var tunnel;
      var HttpCodes;
      (function(HttpCodes2) {
        HttpCodes2[HttpCodes2["OK"] = 200] = "OK";
        HttpCodes2[HttpCodes2["MultipleChoices"] = 300] = "MultipleChoices";
        HttpCodes2[HttpCodes2["MovedPermanently"] = 301] = "MovedPermanently";
        HttpCodes2[HttpCodes2["ResourceMoved"] = 302] = "ResourceMoved";
        HttpCodes2[HttpCodes2["SeeOther"] = 303] = "SeeOther";
        HttpCodes2[HttpCodes2["NotModified"] = 304] = "NotModified";
        HttpCodes2[HttpCodes2["UseProxy"] = 305] = "UseProxy";
        HttpCodes2[HttpCodes2["SwitchProxy"] = 306] = "SwitchProxy";
        HttpCodes2[HttpCodes2["TemporaryRedirect"] = 307] = "TemporaryRedirect";
        HttpCodes2[HttpCodes2["PermanentRedirect"] = 308] = "PermanentRedirect";
        HttpCodes2[HttpCodes2["BadRequest"] = 400] = "BadRequest";
        HttpCodes2[HttpCodes2["Unauthorized"] = 401] = "Unauthorized";
        HttpCodes2[HttpCodes2["PaymentRequired"] = 402] = "PaymentRequired";
        HttpCodes2[HttpCodes2["Forbidden"] = 403] = "Forbidden";
        HttpCodes2[HttpCodes2["NotFound"] = 404] = "NotFound";
        HttpCodes2[HttpCodes2["MethodNotAllowed"] = 405] = "MethodNotAllowed";
        HttpCodes2[HttpCodes2["NotAcceptable"] = 406] = "NotAcceptable";
        HttpCodes2[HttpCodes2["ProxyAuthenticationRequired"] = 407] = "ProxyAuthenticationRequired";
        HttpCodes2[HttpCodes2["RequestTimeout"] = 408] = "RequestTimeout";
        HttpCodes2[HttpCodes2["Conflict"] = 409] = "Conflict";
        HttpCodes2[HttpCodes2["Gone"] = 410] = "Gone";
        HttpCodes2[HttpCodes2["TooManyRequests"] = 429] = "TooManyRequests";
        HttpCodes2[HttpCodes2["InternalServerError"] = 500] = "InternalServerError";
        HttpCodes2[HttpCodes2["NotImplemented"] = 501] = "NotImplemented";
        HttpCodes2[HttpCodes2["BadGateway"] = 502] = "BadGateway";
        HttpCodes2[HttpCodes2["ServiceUnavailable"] = 503] = "ServiceUnavailable";
        HttpCodes2[HttpCodes2["GatewayTimeout"] = 504] = "GatewayTimeout";
      })(HttpCodes = exports2.HttpCodes || (exports2.HttpCodes = {}));
      var Headers;
      (function(Headers2) {
        Headers2["Accept"] = "accept";
        Headers2["ContentType"] = "content-type";
      })(Headers = exports2.Headers || (exports2.Headers = {}));
      var MediaTypes;
      (function(MediaTypes2) {
        MediaTypes2["ApplicationJson"] = "application/json";
      })(MediaTypes = exports2.MediaTypes || (exports2.MediaTypes = {}));
      function getProxyUrl(serverUrl) {
        let proxyUrl = pm.getProxyUrl(new URL(serverUrl));
        return proxyUrl ? proxyUrl.href : "";
      }
      exports2.getProxyUrl = getProxyUrl;
      var HttpRedirectCodes = [
        HttpCodes.MovedPermanently,
        HttpCodes.ResourceMoved,
        HttpCodes.SeeOther,
        HttpCodes.TemporaryRedirect,
        HttpCodes.PermanentRedirect
      ];
      var HttpResponseRetryCodes = [
        HttpCodes.BadGateway,
        HttpCodes.ServiceUnavailable,
        HttpCodes.GatewayTimeout
      ];
      var RetryableHttpVerbs = ["OPTIONS", "GET", "DELETE", "HEAD"];
      var ExponentialBackoffCeiling = 10;
      var ExponentialBackoffTimeSlice = 5;
      var HttpClientError = class extends Error {
        constructor(message, statusCode) {
          super(message);
          this.name = "HttpClientError";
          this.statusCode = statusCode;
          Object.setPrototypeOf(this, HttpClientError.prototype);
        }
      };
      exports2.HttpClientError = HttpClientError;
      var HttpClientResponse = class {
        constructor(message) {
          this.message = message;
        }
        readBody() {
          return new Promise(async (resolve, reject) => {
            let output = Buffer.alloc(0);
            this.message.on("data", (chunk) => {
              output = Buffer.concat([output, chunk]);
            });
            this.message.on("end", () => {
              resolve(output.toString());
            });
          });
        }
      };
      exports2.HttpClientResponse = HttpClientResponse;
      function isHttps(requestUrl) {
        let parsedUrl = new URL(requestUrl);
        return parsedUrl.protocol === "https:";
      }
      exports2.isHttps = isHttps;
      var HttpClient = class {
        constructor(userAgent, handlers, requestOptions) {
          this._ignoreSslError = false;
          this._allowRedirects = true;
          this._allowRedirectDowngrade = false;
          this._maxRedirects = 50;
          this._allowRetries = false;
          this._maxRetries = 1;
          this._keepAlive = false;
          this._disposed = false;
          this.userAgent = userAgent;
          this.handlers = handlers || [];
          this.requestOptions = requestOptions;
          if (requestOptions) {
            if (requestOptions.ignoreSslError != null) {
              this._ignoreSslError = requestOptions.ignoreSslError;
            }
            this._socketTimeout = requestOptions.socketTimeout;
            if (requestOptions.allowRedirects != null) {
              this._allowRedirects = requestOptions.allowRedirects;
            }
            if (requestOptions.allowRedirectDowngrade != null) {
              this._allowRedirectDowngrade = requestOptions.allowRedirectDowngrade;
            }
            if (requestOptions.maxRedirects != null) {
              this._maxRedirects = Math.max(requestOptions.maxRedirects, 0);
            }
            if (requestOptions.keepAlive != null) {
              this._keepAlive = requestOptions.keepAlive;
            }
            if (requestOptions.allowRetries != null) {
              this._allowRetries = requestOptions.allowRetries;
            }
            if (requestOptions.maxRetries != null) {
              this._maxRetries = requestOptions.maxRetries;
            }
          }
        }
        options(requestUrl, additionalHeaders) {
          return this.request("OPTIONS", requestUrl, null, additionalHeaders || {});
        }
        get(requestUrl, additionalHeaders) {
          return this.request("GET", requestUrl, null, additionalHeaders || {});
        }
        del(requestUrl, additionalHeaders) {
          return this.request("DELETE", requestUrl, null, additionalHeaders || {});
        }
        post(requestUrl, data, additionalHeaders) {
          return this.request("POST", requestUrl, data, additionalHeaders || {});
        }
        patch(requestUrl, data, additionalHeaders) {
          return this.request("PATCH", requestUrl, data, additionalHeaders || {});
        }
        put(requestUrl, data, additionalHeaders) {
          return this.request("PUT", requestUrl, data, additionalHeaders || {});
        }
        head(requestUrl, additionalHeaders) {
          return this.request("HEAD", requestUrl, null, additionalHeaders || {});
        }
        sendStream(verb, requestUrl, stream, additionalHeaders) {
          return this.request(verb, requestUrl, stream, additionalHeaders);
        }
        async getJson(requestUrl, additionalHeaders = {}) {
          additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson);
          let res = await this.get(requestUrl, additionalHeaders);
          return this._processResponse(res, this.requestOptions);
        }
        async postJson(requestUrl, obj, additionalHeaders = {}) {
          let data = JSON.stringify(obj, null, 2);
          additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson);
          additionalHeaders[Headers.ContentType] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.ContentType, MediaTypes.ApplicationJson);
          let res = await this.post(requestUrl, data, additionalHeaders);
          return this._processResponse(res, this.requestOptions);
        }
        async putJson(requestUrl, obj, additionalHeaders = {}) {
          let data = JSON.stringify(obj, null, 2);
          additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson);
          additionalHeaders[Headers.ContentType] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.ContentType, MediaTypes.ApplicationJson);
          let res = await this.put(requestUrl, data, additionalHeaders);
          return this._processResponse(res, this.requestOptions);
        }
        async patchJson(requestUrl, obj, additionalHeaders = {}) {
          let data = JSON.stringify(obj, null, 2);
          additionalHeaders[Headers.Accept] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.Accept, MediaTypes.ApplicationJson);
          additionalHeaders[Headers.ContentType] = this._getExistingOrDefaultHeader(additionalHeaders, Headers.ContentType, MediaTypes.ApplicationJson);
          let res = await this.patch(requestUrl, data, additionalHeaders);
          return this._processResponse(res, this.requestOptions);
        }
        async request(verb, requestUrl, data, headers) {
          if (this._disposed) {
            throw new Error("Client has already been disposed.");
          }
          let parsedUrl = new URL(requestUrl);
          let info2 = this._prepareRequest(verb, parsedUrl, headers);
          let maxTries = this._allowRetries && RetryableHttpVerbs.indexOf(verb) != -1 ? this._maxRetries + 1 : 1;
          let numTries = 0;
          let response;
          while (numTries < maxTries) {
            response = await this.requestRaw(info2, data);
            if (response && response.message && response.message.statusCode === HttpCodes.Unauthorized) {
              let authenticationHandler;
              for (let i = 0; i < this.handlers.length; i++) {
                if (this.handlers[i].canHandleAuthentication(response)) {
                  authenticationHandler = this.handlers[i];
                  break;
                }
              }
              if (authenticationHandler) {
                return authenticationHandler.handleAuthentication(this, info2, data);
              } else {
                return response;
              }
            }
            let redirectsRemaining = this._maxRedirects;
            while (HttpRedirectCodes.indexOf(response.message.statusCode) != -1 && this._allowRedirects && redirectsRemaining > 0) {
              const redirectUrl = response.message.headers["location"];
              if (!redirectUrl) {
                break;
              }
              let parsedRedirectUrl = new URL(redirectUrl);
              if (parsedUrl.protocol == "https:" && parsedUrl.protocol != parsedRedirectUrl.protocol && !this._allowRedirectDowngrade) {
                throw new Error("Redirect from HTTPS to HTTP protocol. This downgrade is not allowed for security reasons. If you want to allow this behavior, set the allowRedirectDowngrade option to true.");
              }
              await response.readBody();
              if (parsedRedirectUrl.hostname !== parsedUrl.hostname) {
                for (let header in headers) {
                  if (header.toLowerCase() === "authorization") {
                    delete headers[header];
                  }
                }
              }
              info2 = this._prepareRequest(verb, parsedRedirectUrl, headers);
              response = await this.requestRaw(info2, data);
              redirectsRemaining--;
            }
            if (HttpResponseRetryCodes.indexOf(response.message.statusCode) == -1) {
              return response;
            }
            numTries += 1;
            if (numTries < maxTries) {
              await response.readBody();
              await this._performExponentialBackoff(numTries);
            }
          }
          return response;
        }
        dispose() {
          if (this._agent) {
            this._agent.destroy();
          }
          this._disposed = true;
        }
        requestRaw(info2, data) {
          return new Promise((resolve, reject) => {
            let callbackForResult = function(err, res) {
              if (err) {
                reject(err);
              }
              resolve(res);
            };
            this.requestRawWithCallback(info2, data, callbackForResult);
          });
        }
        requestRawWithCallback(info2, data, onResult) {
          let socket;
          if (typeof data === "string") {
            info2.options.headers["Content-Length"] = Buffer.byteLength(data, "utf8");
          }
          let callbackCalled = false;
          let handleResult = (err, res) => {
            if (!callbackCalled) {
              callbackCalled = true;
              onResult(err, res);
            }
          };
          let req = info2.httpModule.request(info2.options, (msg) => {
            let res = new HttpClientResponse(msg);
            handleResult(null, res);
          });
          req.on("socket", (sock) => {
            socket = sock;
          });
          req.setTimeout(this._socketTimeout || 3 * 6e4, () => {
            if (socket) {
              socket.end();
            }
            handleResult(new Error("Request timeout: " + info2.options.path), null);
          });
          req.on("error", function(err) {
            handleResult(err, null);
          });
          if (data && typeof data === "string") {
            req.write(data, "utf8");
          }
          if (data && typeof data !== "string") {
            data.on("close", function() {
              req.end();
            });
            data.pipe(req);
          } else {
            req.end();
          }
        }
        getAgent(serverUrl) {
          let parsedUrl = new URL(serverUrl);
          return this._getAgent(parsedUrl);
        }
        _prepareRequest(method, requestUrl, headers) {
          const info2 = {};
          info2.parsedUrl = requestUrl;
          const usingSsl = info2.parsedUrl.protocol === "https:";
          info2.httpModule = usingSsl ? https : http;
          const defaultPort = usingSsl ? 443 : 80;
          info2.options = {};
          info2.options.host = info2.parsedUrl.hostname;
          info2.options.port = info2.parsedUrl.port ? parseInt(info2.parsedUrl.port) : defaultPort;
          info2.options.path = (info2.parsedUrl.pathname || "") + (info2.parsedUrl.search || "");
          info2.options.method = method;
          info2.options.headers = this._mergeHeaders(headers);
          if (this.userAgent != null) {
            info2.options.headers["user-agent"] = this.userAgent;
          }
          info2.options.agent = this._getAgent(info2.parsedUrl);
          if (this.handlers) {
            this.handlers.forEach((handler) => {
              handler.prepareRequest(info2.options);
            });
          }
          return info2;
        }
        _mergeHeaders(headers) {
          const lowercaseKeys = (obj) => Object.keys(obj).reduce((c, k) => (c[k.toLowerCase()] = obj[k], c), {});
          if (this.requestOptions && this.requestOptions.headers) {
            return Object.assign({}, lowercaseKeys(this.requestOptions.headers), lowercaseKeys(headers));
          }
          return lowercaseKeys(headers || {});
        }
        _getExistingOrDefaultHeader(additionalHeaders, header, _default) {
          const lowercaseKeys = (obj) => Object.keys(obj).reduce((c, k) => (c[k.toLowerCase()] = obj[k], c), {});
          let clientHeader;
          if (this.requestOptions && this.requestOptions.headers) {
            clientHeader = lowercaseKeys(this.requestOptions.headers)[header];
          }
          return additionalHeaders[header] || clientHeader || _default;
        }
        _getAgent(parsedUrl) {
          let agent;
          let proxyUrl = pm.getProxyUrl(parsedUrl);
          let useProxy = proxyUrl && proxyUrl.hostname;
          if (this._keepAlive && useProxy) {
            agent = this._proxyAgent;
          }
          if (this._keepAlive && !useProxy) {
            agent = this._agent;
          }
          if (!!agent) {
            return agent;
          }
          const usingSsl = parsedUrl.protocol === "https:";
          let maxSockets = 100;
          if (!!this.requestOptions) {
            maxSockets = this.requestOptions.maxSockets || http.globalAgent.maxSockets;
          }
          if (useProxy) {
            if (!tunnel) {
              tunnel = require_tunnel2();
            }
            const agentOptions = {
              maxSockets,
              keepAlive: this._keepAlive,
              proxy: __spreadProps(__spreadValues({}, (proxyUrl.username || proxyUrl.password) && {
                proxyAuth: `${proxyUrl.username}:${proxyUrl.password}`
              }), {
                host: proxyUrl.hostname,
                port: proxyUrl.port
              })
            };
            let tunnelAgent;
            const overHttps = proxyUrl.protocol === "https:";
            if (usingSsl) {
              tunnelAgent = overHttps ? tunnel.httpsOverHttps : tunnel.httpsOverHttp;
            } else {
              tunnelAgent = overHttps ? tunnel.httpOverHttps : tunnel.httpOverHttp;
            }
            agent = tunnelAgent(agentOptions);
            this._proxyAgent = agent;
          }
          if (this._keepAlive && !agent) {
            const options = { keepAlive: this._keepAlive, maxSockets };
            agent = usingSsl ? new https.Agent(options) : new http.Agent(options);
            this._agent = agent;
          }
          if (!agent) {
            agent = usingSsl ? https.globalAgent : http.globalAgent;
          }
          if (usingSsl && this._ignoreSslError) {
            agent.options = Object.assign(agent.options || {}, {
              rejectUnauthorized: false
            });
          }
          return agent;
        }
        _performExponentialBackoff(retryNumber) {
          retryNumber = Math.min(ExponentialBackoffCeiling, retryNumber);
          const ms = ExponentialBackoffTimeSlice * Math.pow(2, retryNumber);
          return new Promise((resolve) => setTimeout(() => resolve(), ms));
        }
        static dateTimeDeserializer(key, value) {
          if (typeof value === "string") {
            let a = new Date(value);
            if (!isNaN(a.valueOf())) {
              return a;
            }
          }
          return value;
        }
        async _processResponse(res, options) {
          return new Promise(async (resolve, reject) => {
            const statusCode = res.message.statusCode;
            const response = {
              statusCode,
              result: null,
              headers: {}
            };
            if (statusCode == HttpCodes.NotFound) {
              resolve(response);
            }
            let obj;
            let contents;
            try {
              contents = await res.readBody();
              if (contents && contents.length > 0) {
                if (options && options.deserializeDates) {
                  obj = JSON.parse(contents, HttpClient.dateTimeDeserializer);
                } else {
                  obj = JSON.parse(contents);
                }
                response.result = obj;
              }
              response.headers = res.message.headers;
            } catch (err) {
            }
            if (statusCode > 299) {
              let msg;
              if (obj && obj.message) {
                msg = obj.message;
              } else if (contents && contents.length > 0) {
                msg = contents;
              } else {
                msg = "Failed request: (" + statusCode + ")";
              }
              let err = new HttpClientError(msg, statusCode);
              err.result = response.result;
              reject(err);
            } else {
              resolve(response);
            }
          });
        }
      };
      exports2.HttpClient = HttpClient;
    }
  });
  
  // node_modules/@actions/http-client/auth.js
  var require_auth = __commonJS({
    "node_modules/@actions/http-client/auth.js"(exports2) {
      "use strict";
      Object.defineProperty(exports2, "__esModule", { value: true });
      var BasicCredentialHandler = class {
        constructor(username, password) {
          this.username = username;
          this.password = password;
        }
        prepareRequest(options) {
          options.headers["Authorization"] = "Basic " + Buffer.from(this.username + ":" + this.password).toString("base64");
        }
        canHandleAuthentication(response) {
          return false;
        }
        handleAuthentication(httpClient, requestInfo, objs) {
          return null;
        }
      };
      exports2.BasicCredentialHandler = BasicCredentialHandler;
      var BearerCredentialHandler = class {
        constructor(token) {
          this.token = token;
        }
        prepareRequest(options) {
          options.headers["Authorization"] = "Bearer " + this.token;
        }
        canHandleAuthentication(response) {
          return false;
        }
        handleAuthentication(httpClient, requestInfo, objs) {
          return null;
        }
      };
      exports2.BearerCredentialHandler = BearerCredentialHandler;
      var PersonalAccessTokenCredentialHandler = class {
        constructor(token) {
          this.token = token;
        }
        prepareRequest(options) {
          options.headers["Authorization"] = "Basic " + Buffer.from("PAT:" + this.token).toString("base64");
        }
        canHandleAuthentication(response) {
          return false;
        }
        handleAuthentication(httpClient, requestInfo, objs) {
          return null;
        }
      };
      exports2.PersonalAccessTokenCredentialHandler = PersonalAccessTokenCredentialHandler;
    }
  });
  
  // node_modules/@actions/core/lib/oidc-utils.js
  var require_oidc_utils = __commonJS({
    "node_modules/@actions/core/lib/oidc-utils.js"(exports2) {
      "use strict";
      var __awaiter = exports2 && exports2.__awaiter || function(thisArg, _arguments, P, generator) {
        function adopt(value) {
          return value instanceof P ? value : new P(function(resolve) {
            resolve(value);
          });
        }
        return new (P || (P = Promise))(function(resolve, reject) {
          function fulfilled(value) {
            try {
              step(generator.next(value));
            } catch (e) {
              reject(e);
            }
          }
          function rejected(value) {
            try {
              step(generator["throw"](value));
            } catch (e) {
              reject(e);
            }
          }
          function step(result) {
            result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
          }
          step((generator = generator.apply(thisArg, _arguments || [])).next());
        });
      };
      Object.defineProperty(exports2, "__esModule", { value: true });
      exports2.OidcClient = void 0;
      var http_client_1 = require_http_client();
      var auth_1 = require_auth();
      var core_1 = require_core();
      var OidcClient = class {
        static createHttpClient(allowRetry = true, maxRetry = 10) {
          const requestOptions = {
            allowRetries: allowRetry,
            maxRetries: maxRetry
          };
          return new http_client_1.HttpClient("actions/oidc-client", [new auth_1.BearerCredentialHandler(OidcClient.getRequestToken())], requestOptions);
        }
        static getRequestToken() {
          const token = process.env["ACTIONS_ID_TOKEN_REQUEST_TOKEN"];
          if (!token) {
            throw new Error("Unable to get ACTIONS_ID_TOKEN_REQUEST_TOKEN env variable");
          }
          return token;
        }
        static getIDTokenUrl() {
          const runtimeUrl = process.env["ACTIONS_ID_TOKEN_REQUEST_URL"];
          if (!runtimeUrl) {
            throw new Error("Unable to get ACTIONS_ID_TOKEN_REQUEST_URL env variable");
          }
          return runtimeUrl;
        }
        static getCall(id_token_url) {
          var _a;
          return __awaiter(this, void 0, void 0, function* () {
            const httpclient = OidcClient.createHttpClient();
            const res = yield httpclient.getJson(id_token_url).catch((error) => {
              throw new Error(`Failed to get ID Token. 
   
          Error Code : ${error.statusCode}
   
          Error Message: ${error.result.message}`);
            });
            const id_token = (_a = res.result) === null || _a === void 0 ? void 0 : _a.value;
            if (!id_token) {
              throw new Error("Response json body do not have ID Token field");
            }
            return id_token;
          });
        }
        static getIDToken(audience) {
          return __awaiter(this, void 0, void 0, function* () {
            try {
              let id_token_url = OidcClient.getIDTokenUrl();
              if (audience) {
                const encodedAudience = encodeURIComponent(audience);
                id_token_url = `${id_token_url}&audience=${encodedAudience}`;
              }
              core_1.debug(`ID token url is ${id_token_url}`);
              const id_token = yield OidcClient.getCall(id_token_url);
              core_1.setSecret(id_token);
              return id_token;
            } catch (error) {
              throw new Error(`Error message: ${error.message}`);
            }
          });
        }
      };
      exports2.OidcClient = OidcClient;
    }
  });
  
  // node_modules/@actions/core/lib/core.js
  var require_core = __commonJS({
    "node_modules/@actions/core/lib/core.js"(exports2) {
      "use strict";
      var __createBinding = exports2 && exports2.__createBinding || (Object.create ? function(o, m, k, k2) {
        if (k2 === void 0)
          k2 = k;
        Object.defineProperty(o, k2, { enumerable: true, get: function() {
          return m[k];
        } });
      } : function(o, m, k, k2) {
        if (k2 === void 0)
          k2 = k;
        o[k2] = m[k];
      });
      var __setModuleDefault = exports2 && exports2.__setModuleDefault || (Object.create ? function(o, v) {
        Object.defineProperty(o, "default", { enumerable: true, value: v });
      } : function(o, v) {
        o["default"] = v;
      });
      var __importStar = exports2 && exports2.__importStar || function(mod) {
        if (mod && mod.__esModule)
          return mod;
        var result = {};
        if (mod != null) {
          for (var k in mod)
            if (k !== "default" && Object.hasOwnProperty.call(mod, k))
              __createBinding(result, mod, k);
        }
        __setModuleDefault(result, mod);
        return result;
      };
      var __awaiter = exports2 && exports2.__awaiter || function(thisArg, _arguments, P, generator) {
        function adopt(value) {
          return value instanceof P ? value : new P(function(resolve) {
            resolve(value);
          });
        }
        return new (P || (P = Promise))(function(resolve, reject) {
          function fulfilled(value) {
            try {
              step(generator.next(value));
            } catch (e) {
              reject(e);
            }
          }
          function rejected(value) {
            try {
              step(generator["throw"](value));
            } catch (e) {
              reject(e);
            }
          }
          function step(result) {
            result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
          }
          step((generator = generator.apply(thisArg, _arguments || [])).next());
        });
      };
      Object.defineProperty(exports2, "__esModule", { value: true });
      exports2.getIDToken = exports2.getState = exports2.saveState = exports2.group = exports2.endGroup = exports2.startGroup = exports2.info = exports2.notice = exports2.warning = exports2.error = exports2.debug = exports2.isDebug = exports2.setFailed = exports2.setCommandEcho = exports2.setOutput = exports2.getBooleanInput = exports2.getMultilineInput = exports2.getInput = exports2.addPath = exports2.setSecret = exports2.exportVariable = exports2.ExitCode = void 0;
      var command_1 = require_command();
      var file_command_1 = require_file_command();
      var utils_1 = require_utils();
      var os = __importStar(require("os"));
      var path3 = __importStar(require("path"));
      var oidc_utils_1 = require_oidc_utils();
      var ExitCode;
      (function(ExitCode2) {
        ExitCode2[ExitCode2["Success"] = 0] = "Success";
        ExitCode2[ExitCode2["Failure"] = 1] = "Failure";
      })(ExitCode = exports2.ExitCode || (exports2.ExitCode = {}));
      function exportVariable(name, val) {
        const convertedVal = utils_1.toCommandValue(val);
        process.env[name] = convertedVal;
        const filePath = process.env["GITHUB_ENV"] || "";
        if (filePath) {
          const delimiter = "_GitHubActionsFileCommandDelimeter_";
          const commandValue = `${name}<<${delimiter}${os.EOL}${convertedVal}${os.EOL}${delimiter}`;
          file_command_1.issueCommand("ENV", commandValue);
        } else {
          command_1.issueCommand("set-env", { name }, convertedVal);
        }
      }
      exports2.exportVariable = exportVariable;
      function setSecret(secret) {
        command_1.issueCommand("add-mask", {}, secret);
      }
      exports2.setSecret = setSecret;
      function addPath(inputPath) {
        const filePath = process.env["GITHUB_PATH"] || "";
        if (filePath) {
          file_command_1.issueCommand("PATH", inputPath);
        } else {
          command_1.issueCommand("add-path", {}, inputPath);
        }
        process.env["PATH"] = `${inputPath}${path3.delimiter}${process.env["PATH"]}`;
      }
      exports2.addPath = addPath;
      function getInput3(name, options) {
        const val = process.env[`INPUT_${name.replace(/ /g, "_").toUpperCase()}`] || "";
        if (options && options.required && !val) {
          throw new Error(`Input required and not supplied: ${name}`);
        }
        if (options && options.trimWhitespace === false) {
          return val;
        }
        return val.trim();
      }
      exports2.getInput = getInput3;
      function getMultilineInput(name, options) {
        const inputs = getInput3(name, options).split("\n").filter((x) => x !== "");
        return inputs;
      }
      exports2.getMultilineInput = getMultilineInput;
      function getBooleanInput(name, options) {
        const trueValue = ["true", "True", "TRUE"];
        const falseValue = ["false", "False", "FALSE"];
        const val = getInput3(name, options);
        if (trueValue.includes(val))
          return true;
        if (falseValue.includes(val))
          return false;
        throw new TypeError(`Input does not meet YAML 1.2 "Core Schema" specification: ${name}
  Support boolean input list: \`true | True | TRUE | false | False | FALSE\``);
      }
      exports2.getBooleanInput = getBooleanInput;
      function setOutput(name, value) {
        process.stdout.write(os.EOL);
        command_1.issueCommand("set-output", { name }, value);
      }
      exports2.setOutput = setOutput;
      function setCommandEcho(enabled) {
        command_1.issue("echo", enabled ? "on" : "off");
      }
      exports2.setCommandEcho = setCommandEcho;
      function setFailed2(message) {
        process.exitCode = ExitCode.Failure;
        error(message);
      }
      exports2.setFailed = setFailed2;
      function isDebug() {
        return process.env["RUNNER_DEBUG"] === "1";
      }
      exports2.isDebug = isDebug;
      function debug(message) {
        command_1.issueCommand("debug", {}, message);
      }
      exports2.debug = debug;
      function error(message, properties = {}) {
        command_1.issueCommand("error", utils_1.toCommandProperties(properties), message instanceof Error ? message.toString() : message);
      }
      exports2.error = error;
      function warning(message, properties = {}) {
        command_1.issueCommand("warning", utils_1.toCommandProperties(properties), message instanceof Error ? message.toString() : message);
      }
      exports2.warning = warning;
      function notice(message, properties = {}) {
        command_1.issueCommand("notice", utils_1.toCommandProperties(properties), message instanceof Error ? message.toString() : message);
      }
      exports2.notice = notice;
      function info2(message) {
        process.stdout.write(message + os.EOL);
      }
      exports2.info = info2;
      function startGroup(name) {
        command_1.issue("group", name);
      }
      exports2.startGroup = startGroup;
      function endGroup() {
        command_1.issue("endgroup");
      }
      exports2.endGroup = endGroup;
      function group(name, fn) {
        return __awaiter(this, void 0, void 0, function* () {
          startGroup(name);
          let result;
          try {
            result = yield fn();
          } finally {
            endGroup();
          }
          return result;
        });
      }
      exports2.group = group;
      function saveState(name, value) {
        command_1.issueCommand("save-state", { name }, value);
      }
      exports2.saveState = saveState;
      function getState(name) {
        return process.env[`STATE_${name}`] || "";
      }
      exports2.getState = getState;
      function getIDToken(aud) {
        return __awaiter(this, void 0, void 0, function* () {
          return yield oidc_utils_1.OidcClient.getIDToken(aud);
        });
      }
      exports2.getIDToken = getIDToken;
    }
  });
  
  // node_modules/@actions/io/lib/io-util.js
  var require_io_util = __commonJS({
    "node_modules/@actions/io/lib/io-util.js"(exports2) {
      "use strict";
      var __createBinding = exports2 && exports2.__createBinding || (Object.create ? function(o, m, k, k2) {
        if (k2 === void 0)
          k2 = k;
        Object.defineProperty(o, k2, { enumerable: true, get: function() {
          return m[k];
        } });
      } : function(o, m, k, k2) {
        if (k2 === void 0)
          k2 = k;
        o[k2] = m[k];
      });
      var __setModuleDefault = exports2 && exports2.__setModuleDefault || (Object.create ? function(o, v) {
        Object.defineProperty(o, "default", { enumerable: true, value: v });
      } : function(o, v) {
        o["default"] = v;
      });
      var __importStar = exports2 && exports2.__importStar || function(mod) {
        if (mod && mod.__esModule)
          return mod;
        var result = {};
        if (mod != null) {
          for (var k in mod)
            if (k !== "default" && Object.hasOwnProperty.call(mod, k))
              __createBinding(result, mod, k);
        }
        __setModuleDefault(result, mod);
        return result;
      };
      var __awaiter = exports2 && exports2.__awaiter || function(thisArg, _arguments, P, generator) {
        function adopt(value) {
          return value instanceof P ? value : new P(function(resolve) {
            resolve(value);
          });
        }
        return new (P || (P = Promise))(function(resolve, reject) {
          function fulfilled(value) {
            try {
              step(generator.next(value));
            } catch (e) {
              reject(e);
            }
          }
          function rejected(value) {
            try {
              step(generator["throw"](value));
            } catch (e) {
              reject(e);
            }
          }
          function step(result) {
            result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
          }
          step((generator = generator.apply(thisArg, _arguments || [])).next());
        });
      };
      var _a;
      Object.defineProperty(exports2, "__esModule", { value: true });
      exports2.getCmdPath = exports2.tryGetExecutablePath = exports2.isRooted = exports2.isDirectory = exports2.exists = exports2.IS_WINDOWS = exports2.unlink = exports2.symlink = exports2.stat = exports2.rmdir = exports2.rename = exports2.readlink = exports2.readdir = exports2.mkdir = exports2.lstat = exports2.copyFile = exports2.chmod = void 0;
      var fs = __importStar(require("fs"));
      var path3 = __importStar(require("path"));
      _a = fs.promises, exports2.chmod = _a.chmod, exports2.copyFile = _a.copyFile, exports2.lstat = _a.lstat, exports2.mkdir = _a.mkdir, exports2.readdir = _a.readdir, exports2.readlink = _a.readlink, exports2.rename = _a.rename, exports2.rmdir = _a.rmdir, exports2.stat = _a.stat, exports2.symlink = _a.symlink, exports2.unlink = _a.unlink;
      exports2.IS_WINDOWS = process.platform === "win32";
      function exists(fsPath) {
        return __awaiter(this, void 0, void 0, function* () {
          try {
            yield exports2.stat(fsPath);
          } catch (err) {
            if (err.code === "ENOENT") {
              return false;
            }
            throw err;
          }
          return true;
        });
      }
      exports2.exists = exists;
      function isDirectory(fsPath, useStat = false) {
        return __awaiter(this, void 0, void 0, function* () {
          const stats = useStat ? yield exports2.stat(fsPath) : yield exports2.lstat(fsPath);
          return stats.isDirectory();
        });
      }
      exports2.isDirectory = isDirectory;
      function isRooted(p) {
        p = normalizeSeparators(p);
        if (!p) {
          throw new Error('isRooted() parameter "p" cannot be empty');
        }
        if (exports2.IS_WINDOWS) {
          return p.startsWith("\\") || /^[A-Z]:/i.test(p);
        }
        return p.startsWith("/");
      }
      exports2.isRooted = isRooted;
      function tryGetExecutablePath(filePath, extensions) {
        return __awaiter(this, void 0, void 0, function* () {
          let stats = void 0;
          try {
            stats = yield exports2.stat(filePath);
          } catch (err) {
            if (err.code !== "ENOENT") {
              console.log(`Unexpected error attempting to determine if executable file exists '${filePath}': ${err}`);
            }
          }
          if (stats && stats.isFile()) {
            if (exports2.IS_WINDOWS) {
              const upperExt = path3.extname(filePath).toUpperCase();
              if (extensions.some((validExt) => validExt.toUpperCase() === upperExt)) {
                return filePath;
              }
            } else {
              if (isUnixExecutable(stats)) {
                return filePath;
              }
            }
          }
          const originalFilePath = filePath;
          for (const extension of extensions) {
            filePath = originalFilePath + extension;
            stats = void 0;
            try {
              stats = yield exports2.stat(filePath);
            } catch (err) {
              if (err.code !== "ENOENT") {
                console.log(`Unexpected error attempting to determine if executable file exists '${filePath}': ${err}`);
              }
            }
            if (stats && stats.isFile()) {
              if (exports2.IS_WINDOWS) {
                try {
                  const directory = path3.dirname(filePath);
                  const upperName = path3.basename(filePath).toUpperCase();
                  for (const actualName of yield exports2.readdir(directory)) {
                    if (upperName === actualName.toUpperCase()) {
                      filePath = path3.join(directory, actualName);
                      break;
                    }
                  }
                } catch (err) {
                  console.log(`Unexpected error attempting to determine the actual case of the file '${filePath}': ${err}`);
                }
                return filePath;
              } else {
                if (isUnixExecutable(stats)) {
                  return filePath;
                }
              }
            }
          }
          return "";
        });
      }
      exports2.tryGetExecutablePath = tryGetExecutablePath;
      function normalizeSeparators(p) {
        p = p || "";
        if (exports2.IS_WINDOWS) {
          p = p.replace(/\//g, "\\");
          return p.replace(/\\\\+/g, "\\");
        }
        return p.replace(/\/\/+/g, "/");
      }
      function isUnixExecutable(stats) {
        return (stats.mode & 1) > 0 || (stats.mode & 8) > 0 && stats.gid === process.getgid() || (stats.mode & 64) > 0 && stats.uid === process.getuid();
      }
      function getCmdPath() {
        var _a2;
        return (_a2 = process.env["COMSPEC"]) !== null && _a2 !== void 0 ? _a2 : `cmd.exe`;
      }
      exports2.getCmdPath = getCmdPath;
    }
  });
  
  // node_modules/@actions/io/lib/io.js
  var require_io = __commonJS({
    "node_modules/@actions/io/lib/io.js"(exports2) {
      "use strict";
      var __createBinding = exports2 && exports2.__createBinding || (Object.create ? function(o, m, k, k2) {
        if (k2 === void 0)
          k2 = k;
        Object.defineProperty(o, k2, { enumerable: true, get: function() {
          return m[k];
        } });
      } : function(o, m, k, k2) {
        if (k2 === void 0)
          k2 = k;
        o[k2] = m[k];
      });
      var __setModuleDefault = exports2 && exports2.__setModuleDefault || (Object.create ? function(o, v) {
        Object.defineProperty(o, "default", { enumerable: true, value: v });
      } : function(o, v) {
        o["default"] = v;
      });
      var __importStar = exports2 && exports2.__importStar || function(mod) {
        if (mod && mod.__esModule)
          return mod;
        var result = {};
        if (mod != null) {
          for (var k in mod)
            if (k !== "default" && Object.hasOwnProperty.call(mod, k))
              __createBinding(result, mod, k);
        }
        __setModuleDefault(result, mod);
        return result;
      };
      var __awaiter = exports2 && exports2.__awaiter || function(thisArg, _arguments, P, generator) {
        function adopt(value) {
          return value instanceof P ? value : new P(function(resolve) {
            resolve(value);
          });
        }
        return new (P || (P = Promise))(function(resolve, reject) {
          function fulfilled(value) {
            try {
              step(generator.next(value));
            } catch (e) {
              reject(e);
            }
          }
          function rejected(value) {
            try {
              step(generator["throw"](value));
            } catch (e) {
              reject(e);
            }
          }
          function step(result) {
            result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
          }
          step((generator = generator.apply(thisArg, _arguments || [])).next());
        });
      };
      Object.defineProperty(exports2, "__esModule", { value: true });
      exports2.findInPath = exports2.which = exports2.mkdirP = exports2.rmRF = exports2.mv = exports2.cp = void 0;
      var assert_1 = require("assert");
      var childProcess = __importStar(require("child_process"));
      var path3 = __importStar(require("path"));
      var util_1 = require("util");
      var ioUtil = __importStar(require_io_util());
      var exec3 = util_1.promisify(childProcess.exec);
      var execFile = util_1.promisify(childProcess.execFile);
      function cp(source, dest, options = {}) {
        return __awaiter(this, void 0, void 0, function* () {
          const { force, recursive, copySourceDirectory } = readCopyOptions(options);
          const destStat = (yield ioUtil.exists(dest)) ? yield ioUtil.stat(dest) : null;
          if (destStat && destStat.isFile() && !force) {
            return;
          }
          const newDest = destStat && destStat.isDirectory() && copySourceDirectory ? path3.join(dest, path3.basename(source)) : dest;
          if (!(yield ioUtil.exists(source))) {
            throw new Error(`no such file or directory: ${source}`);
          }
          const sourceStat = yield ioUtil.stat(source);
          if (sourceStat.isDirectory()) {
            if (!recursive) {
              throw new Error(`Failed to copy. ${source} is a directory, but tried to copy without recursive flag.`);
            } else {
              yield cpDirRecursive(source, newDest, 0, force);
            }
          } else {
            if (path3.relative(source, newDest) === "") {
              throw new Error(`'${newDest}' and '${source}' are the same file`);
            }
            yield copyFile(source, newDest, force);
          }
        });
      }
      exports2.cp = cp;
      function mv(source, dest, options = {}) {
        return __awaiter(this, void 0, void 0, function* () {
          if (yield ioUtil.exists(dest)) {
            let destExists = true;
            if (yield ioUtil.isDirectory(dest)) {
              dest = path3.join(dest, path3.basename(source));
              destExists = yield ioUtil.exists(dest);
            }
            if (destExists) {
              if (options.force == null || options.force) {
                yield rmRF(dest);
              } else {
                throw new Error("Destination already exists");
              }
            }
          }
          yield mkdirP(path3.dirname(dest));
          yield ioUtil.rename(source, dest);
        });
      }
      exports2.mv = mv;
      function rmRF(inputPath) {
        return __awaiter(this, void 0, void 0, function* () {
          if (ioUtil.IS_WINDOWS) {
            if (/[*"<>|]/.test(inputPath)) {
              throw new Error('File path must not contain `*`, `"`, `<`, `>` or `|` on Windows');
            }
            try {
              const cmdPath = ioUtil.getCmdPath();
              if (yield ioUtil.isDirectory(inputPath, true)) {
                yield exec3(`${cmdPath} /s /c "rd /s /q "%inputPath%""`, {
                  env: { inputPath }
                });
              } else {
                yield exec3(`${cmdPath} /s /c "del /f /a "%inputPath%""`, {
                  env: { inputPath }
                });
              }
            } catch (err) {
              if (err.code !== "ENOENT")
                throw err;
            }
            try {
              yield ioUtil.unlink(inputPath);
            } catch (err) {
              if (err.code !== "ENOENT")
                throw err;
            }
          } else {
            let isDir = false;
            try {
              isDir = yield ioUtil.isDirectory(inputPath);
            } catch (err) {
              if (err.code !== "ENOENT")
                throw err;
              return;
            }
            if (isDir) {
              yield execFile(`rm`, [`-rf`, `${inputPath}`]);
            } else {
              yield ioUtil.unlink(inputPath);
            }
          }
        });
      }
      exports2.rmRF = rmRF;
      function mkdirP(fsPath) {
        return __awaiter(this, void 0, void 0, function* () {
          assert_1.ok(fsPath, "a path argument must be provided");
          yield ioUtil.mkdir(fsPath, { recursive: true });
        });
      }
      exports2.mkdirP = mkdirP;
      function which(tool, check) {
        return __awaiter(this, void 0, void 0, function* () {
          if (!tool) {
            throw new Error("parameter 'tool' is required");
          }
          if (check) {
            const result = yield which(tool, false);
            if (!result) {
              if (ioUtil.IS_WINDOWS) {
                throw new Error(`Unable to locate executable file: ${tool}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also verify the file has a valid extension for an executable file.`);
              } else {
                throw new Error(`Unable to locate executable file: ${tool}. Please verify either the file path exists or the file can be found within a directory specified by the PATH environment variable. Also check the file mode to verify the file is executable.`);
              }
            }
            return result;
          }
          const matches = yield findInPath(tool);
          if (matches && matches.length > 0) {
            return matches[0];
          }
          return "";
        });
      }
      exports2.which = which;
      function findInPath(tool) {
        return __awaiter(this, void 0, void 0, function* () {
          if (!tool) {
            throw new Error("parameter 'tool' is required");
          }
          const extensions = [];
          if (ioUtil.IS_WINDOWS && process.env["PATHEXT"]) {
            for (const extension of process.env["PATHEXT"].split(path3.delimiter)) {
              if (extension) {
                extensions.push(extension);
              }
            }
          }
          if (ioUtil.isRooted(tool)) {
            const filePath = yield ioUtil.tryGetExecutablePath(tool, extensions);
            if (filePath) {
              return [filePath];
            }
            return [];
          }
          if (tool.includes(path3.sep)) {
            return [];
          }
          const directories = [];
          if (process.env.PATH) {
            for (const p of process.env.PATH.split(path3.delimiter)) {
              if (p) {
                directories.push(p);
              }
            }
          }
          const matches = [];
          for (const directory of directories) {
            const filePath = yield ioUtil.tryGetExecutablePath(path3.join(directory, tool), extensions);
            if (filePath) {
              matches.push(filePath);
            }
          }
          return matches;
        });
      }
      exports2.findInPath = findInPath;
      function readCopyOptions(options) {
        const force = options.force == null ? true : options.force;
        const recursive = Boolean(options.recursive);
        const copySourceDirectory = options.copySourceDirectory == null ? true : Boolean(options.copySourceDirectory);
        return { force, recursive, copySourceDirectory };
      }
      function cpDirRecursive(sourceDir, destDir, currentDepth, force) {
        return __awaiter(this, void 0, void 0, function* () {
          if (currentDepth >= 255)
            return;
          currentDepth++;
          yield mkdirP(destDir);
          const files = yield ioUtil.readdir(sourceDir);
          for (const fileName of files) {
            const srcFile = `${sourceDir}/${fileName}`;
            const destFile = `${destDir}/${fileName}`;
            const srcFileStat = yield ioUtil.lstat(srcFile);
            if (srcFileStat.isDirectory()) {
              yield cpDirRecursive(srcFile, destFile, currentDepth, force);
            } else {
              yield copyFile(srcFile, destFile, force);
            }
          }
          yield ioUtil.chmod(destDir, (yield ioUtil.stat(sourceDir)).mode);
        });
      }
      function copyFile(srcFile, destFile, force) {
        return __awaiter(this, void 0, void 0, function* () {
          if ((yield ioUtil.lstat(srcFile)).isSymbolicLink()) {
            try {
              yield ioUtil.lstat(destFile);
              yield ioUtil.unlink(destFile);
            } catch (e) {
              if (e.code === "EPERM") {
                yield ioUtil.chmod(destFile, "0666");
                yield ioUtil.unlink(destFile);
              }
            }
            const symlinkFull = yield ioUtil.readlink(srcFile);
            yield ioUtil.symlink(symlinkFull, destFile, ioUtil.IS_WINDOWS ? "junction" : null);
          } else if (!(yield ioUtil.exists(destFile)) || force) {
            yield ioUtil.copyFile(srcFile, destFile);
          }
        });
      }
    }
  });
  
  // node_modules/@actions/exec/lib/toolrunner.js
  var require_toolrunner = __commonJS({
    "node_modules/@actions/exec/lib/toolrunner.js"(exports2) {
      "use strict";
      var __createBinding = exports2 && exports2.__createBinding || (Object.create ? function(o, m, k, k2) {
        if (k2 === void 0)
          k2 = k;
        Object.defineProperty(o, k2, { enumerable: true, get: function() {
          return m[k];
        } });
      } : function(o, m, k, k2) {
        if (k2 === void 0)
          k2 = k;
        o[k2] = m[k];
      });
      var __setModuleDefault = exports2 && exports2.__setModuleDefault || (Object.create ? function(o, v) {
        Object.defineProperty(o, "default", { enumerable: true, value: v });
      } : function(o, v) {
        o["default"] = v;
      });
      var __importStar = exports2 && exports2.__importStar || function(mod) {
        if (mod && mod.__esModule)
          return mod;
        var result = {};
        if (mod != null) {
          for (var k in mod)
            if (k !== "default" && Object.hasOwnProperty.call(mod, k))
              __createBinding(result, mod, k);
        }
        __setModuleDefault(result, mod);
        return result;
      };
      var __awaiter = exports2 && exports2.__awaiter || function(thisArg, _arguments, P, generator) {
        function adopt(value) {
          return value instanceof P ? value : new P(function(resolve) {
            resolve(value);
          });
        }
        return new (P || (P = Promise))(function(resolve, reject) {
          function fulfilled(value) {
            try {
              step(generator.next(value));
            } catch (e) {
              reject(e);
            }
          }
          function rejected(value) {
            try {
              step(generator["throw"](value));
            } catch (e) {
              reject(e);
            }
          }
          function step(result) {
            result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
          }
          step((generator = generator.apply(thisArg, _arguments || [])).next());
        });
      };
      Object.defineProperty(exports2, "__esModule", { value: true });
      exports2.argStringToArray = exports2.ToolRunner = void 0;
      var os = __importStar(require("os"));
      var events = __importStar(require("events"));
      var child = __importStar(require("child_process"));
      var path3 = __importStar(require("path"));
      var io = __importStar(require_io());
      var ioUtil = __importStar(require_io_util());
      var timers_1 = require("timers");
      var IS_WINDOWS = process.platform === "win32";
      var ToolRunner = class extends events.EventEmitter {
        constructor(toolPath, args, options) {
          super();
          if (!toolPath) {
            throw new Error("Parameter 'toolPath' cannot be null or empty.");
          }
          this.toolPath = toolPath;
          this.args = args || [];
          this.options = options || {};
        }
        _debug(message) {
          if (this.options.listeners && this.options.listeners.debug) {
            this.options.listeners.debug(message);
          }
        }
        _getCommandString(options, noPrefix) {
          const toolPath = this._getSpawnFileName();
          const args = this._getSpawnArgs(options);
          let cmd = noPrefix ? "" : "[command]";
          if (IS_WINDOWS) {
            if (this._isCmdFile()) {
              cmd += toolPath;
              for (const a of args) {
                cmd += ` ${a}`;
              }
            } else if (options.windowsVerbatimArguments) {
              cmd += `"${toolPath}"`;
              for (const a of args) {
                cmd += ` ${a}`;
              }
            } else {
              cmd += this._windowsQuoteCmdArg(toolPath);
              for (const a of args) {
                cmd += ` ${this._windowsQuoteCmdArg(a)}`;
              }
            }
          } else {
            cmd += toolPath;
            for (const a of args) {
              cmd += ` ${a}`;
            }
          }
          return cmd;
        }
        _processLineBuffer(data, strBuffer, onLine) {
          try {
            let s = strBuffer + data.toString();
            let n = s.indexOf(os.EOL);
            while (n > -1) {
              const line = s.substring(0, n);
              onLine(line);
              s = s.substring(n + os.EOL.length);
              n = s.indexOf(os.EOL);
            }
            return s;
          } catch (err) {
            this._debug(`error processing line. Failed with error ${err}`);
            return "";
          }
        }
        _getSpawnFileName() {
          if (IS_WINDOWS) {
            if (this._isCmdFile()) {
              return process.env["COMSPEC"] || "cmd.exe";
            }
          }
          return this.toolPath;
        }
        _getSpawnArgs(options) {
          if (IS_WINDOWS) {
            if (this._isCmdFile()) {
              let argline = `/D /S /C "${this._windowsQuoteCmdArg(this.toolPath)}`;
              for (const a of this.args) {
                argline += " ";
                argline += options.windowsVerbatimArguments ? a : this._windowsQuoteCmdArg(a);
              }
              argline += '"';
              return [argline];
            }
          }
          return this.args;
        }
        _endsWith(str, end) {
          return str.endsWith(end);
        }
        _isCmdFile() {
          const upperToolPath = this.toolPath.toUpperCase();
          return this._endsWith(upperToolPath, ".CMD") || this._endsWith(upperToolPath, ".BAT");
        }
        _windowsQuoteCmdArg(arg) {
          if (!this._isCmdFile()) {
            return this._uvQuoteCmdArg(arg);
          }
          if (!arg) {
            return '""';
          }
          const cmdSpecialChars = [
            " ",
            "	",
            "&",
            "(",
            ")",
            "[",
            "]",
            "{",
            "}",
            "^",
            "=",
            ";",
            "!",
            "'",
            "+",
            ",",
            "`",
            "~",
            "|",
            "<",
            ">",
            '"'
          ];
          let needsQuotes = false;
          for (const char of arg) {
            if (cmdSpecialChars.some((x) => x === char)) {
              needsQuotes = true;
              break;
            }
          }
          if (!needsQuotes) {
            return arg;
          }
          let reverse = '"';
          let quoteHit = true;
          for (let i = arg.length; i > 0; i--) {
            reverse += arg[i - 1];
            if (quoteHit && arg[i - 1] === "\\") {
              reverse += "\\";
            } else if (arg[i - 1] === '"') {
              quoteHit = true;
              reverse += '"';
            } else {
              quoteHit = false;
            }
          }
          reverse += '"';
          return reverse.split("").reverse().join("");
        }
        _uvQuoteCmdArg(arg) {
          if (!arg) {
            return '""';
          }
          if (!arg.includes(" ") && !arg.includes("	") && !arg.includes('"')) {
            return arg;
          }
          if (!arg.includes('"') && !arg.includes("\\")) {
            return `"${arg}"`;
          }
          let reverse = '"';
          let quoteHit = true;
          for (let i = arg.length; i > 0; i--) {
            reverse += arg[i - 1];
            if (quoteHit && arg[i - 1] === "\\") {
              reverse += "\\";
            } else if (arg[i - 1] === '"') {
              quoteHit = true;
              reverse += "\\";
            } else {
              quoteHit = false;
            }
          }
          reverse += '"';
          return reverse.split("").reverse().join("");
        }
        _cloneExecOptions(options) {
          options = options || {};
          const result = {
            cwd: options.cwd || process.cwd(),
            env: options.env || process.env,
            silent: options.silent || false,
            windowsVerbatimArguments: options.windowsVerbatimArguments || false,
            failOnStdErr: options.failOnStdErr || false,
            ignoreReturnCode: options.ignoreReturnCode || false,
            delay: options.delay || 1e4
          };
          result.outStream = options.outStream || process.stdout;
          result.errStream = options.errStream || process.stderr;
          return result;
        }
        _getSpawnOptions(options, toolPath) {
          options = options || {};
          const result = {};
          result.cwd = options.cwd;
          result.env = options.env;
          result["windowsVerbatimArguments"] = options.windowsVerbatimArguments || this._isCmdFile();
          if (options.windowsVerbatimArguments) {
            result.argv0 = `"${toolPath}"`;
          }
          return result;
        }
        exec() {
          return __awaiter(this, void 0, void 0, function* () {
            if (!ioUtil.isRooted(this.toolPath) && (this.toolPath.includes("/") || IS_WINDOWS && this.toolPath.includes("\\"))) {
              this.toolPath = path3.resolve(process.cwd(), this.options.cwd || process.cwd(), this.toolPath);
            }
            this.toolPath = yield io.which(this.toolPath, true);
            return new Promise((resolve, reject) => __awaiter(this, void 0, void 0, function* () {
              this._debug(`exec tool: ${this.toolPath}`);
              this._debug("arguments:");
              for (const arg of this.args) {
                this._debug(`   ${arg}`);
              }
              const optionsNonNull = this._cloneExecOptions(this.options);
              if (!optionsNonNull.silent && optionsNonNull.outStream) {
                optionsNonNull.outStream.write(this._getCommandString(optionsNonNull) + os.EOL);
              }
              const state = new ExecState(optionsNonNull, this.toolPath);
              state.on("debug", (message) => {
                this._debug(message);
              });
              if (this.options.cwd && !(yield ioUtil.exists(this.options.cwd))) {
                return reject(new Error(`The cwd: ${this.options.cwd} does not exist!`));
              }
              const fileName = this._getSpawnFileName();
              const cp = child.spawn(fileName, this._getSpawnArgs(optionsNonNull), this._getSpawnOptions(this.options, fileName));
              let stdbuffer = "";
              if (cp.stdout) {
                cp.stdout.on("data", (data) => {
                  if (this.options.listeners && this.options.listeners.stdout) {
                    this.options.listeners.stdout(data);
                  }
                  if (!optionsNonNull.silent && optionsNonNull.outStream) {
                    optionsNonNull.outStream.write(data);
                  }
                  stdbuffer = this._processLineBuffer(data, stdbuffer, (line) => {
                    if (this.options.listeners && this.options.listeners.stdline) {
                      this.options.listeners.stdline(line);
                    }
                  });
                });
              }
              let errbuffer = "";
              if (cp.stderr) {
                cp.stderr.on("data", (data) => {
                  state.processStderr = true;
                  if (this.options.listeners && this.options.listeners.stderr) {
                    this.options.listeners.stderr(data);
                  }
                  if (!optionsNonNull.silent && optionsNonNull.errStream && optionsNonNull.outStream) {
                    const s = optionsNonNull.failOnStdErr ? optionsNonNull.errStream : optionsNonNull.outStream;
                    s.write(data);
                  }
                  errbuffer = this._processLineBuffer(data, errbuffer, (line) => {
                    if (this.options.listeners && this.options.listeners.errline) {
                      this.options.listeners.errline(line);
                    }
                  });
                });
              }
              cp.on("error", (err) => {
                state.processError = err.message;
                state.processExited = true;
                state.processClosed = true;
                state.CheckComplete();
              });
              cp.on("exit", (code) => {
                state.processExitCode = code;
                state.processExited = true;
                this._debug(`Exit code ${code} received from tool '${this.toolPath}'`);
                state.CheckComplete();
              });
              cp.on("close", (code) => {
                state.processExitCode = code;
                state.processExited = true;
                state.processClosed = true;
                this._debug(`STDIO streams have closed for tool '${this.toolPath}'`);
                state.CheckComplete();
              });
              state.on("done", (error, exitCode) => {
                if (stdbuffer.length > 0) {
                  this.emit("stdline", stdbuffer);
                }
                if (errbuffer.length > 0) {
                  this.emit("errline", errbuffer);
                }
                cp.removeAllListeners();
                if (error) {
                  reject(error);
                } else {
                  resolve(exitCode);
                }
              });
              if (this.options.input) {
                if (!cp.stdin) {
                  throw new Error("child process missing stdin");
                }
                cp.stdin.end(this.options.input);
              }
            }));
          });
        }
      };
      exports2.ToolRunner = ToolRunner;
      function argStringToArray(argString) {
        const args = [];
        let inQuotes = false;
        let escaped = false;
        let arg = "";
        function append(c) {
          if (escaped && c !== '"') {
            arg += "\\";
          }
          arg += c;
          escaped = false;
        }
        for (let i = 0; i < argString.length; i++) {
          const c = argString.charAt(i);
          if (c === '"') {
            if (!escaped) {
              inQuotes = !inQuotes;
            } else {
              append(c);
            }
            continue;
          }
          if (c === "\\" && escaped) {
            append(c);
            continue;
          }
          if (c === "\\" && inQuotes) {
            escaped = true;
            continue;
          }
          if (c === " " && !inQuotes) {
            if (arg.length > 0) {
              args.push(arg);
              arg = "";
            }
            continue;
          }
          append(c);
        }
        if (arg.length > 0) {
          args.push(arg.trim());
        }
        return args;
      }
      exports2.argStringToArray = argStringToArray;
      var ExecState = class extends events.EventEmitter {
        constructor(options, toolPath) {
          super();
          this.processClosed = false;
          this.processError = "";
          this.processExitCode = 0;
          this.processExited = false;
          this.processStderr = false;
          this.delay = 1e4;
          this.done = false;
          this.timeout = null;
          if (!toolPath) {
            throw new Error("toolPath must not be empty");
          }
          this.options = options;
          this.toolPath = toolPath;
          if (options.delay) {
            this.delay = options.delay;
          }
        }
        CheckComplete() {
          if (this.done) {
            return;
          }
          if (this.processClosed) {
            this._setResult();
          } else if (this.processExited) {
            this.timeout = timers_1.setTimeout(ExecState.HandleTimeout, this.delay, this);
          }
        }
        _debug(message) {
          this.emit("debug", message);
        }
        _setResult() {
          let error;
          if (this.processExited) {
            if (this.processError) {
              error = new Error(`There was an error when attempting to execute the process '${this.toolPath}'. This may indicate the process failed to start. Error: ${this.processError}`);
            } else if (this.processExitCode !== 0 && !this.options.ignoreReturnCode) {
              error = new Error(`The process '${this.toolPath}' failed with exit code ${this.processExitCode}`);
            } else if (this.processStderr && this.options.failOnStdErr) {
              error = new Error(`The process '${this.toolPath}' failed because one or more lines were written to the STDERR stream`);
            }
          }
          if (this.timeout) {
            clearTimeout(this.timeout);
            this.timeout = null;
          }
          this.done = true;
          this.emit("done", error, this.processExitCode);
        }
        static HandleTimeout(state) {
          if (state.done) {
            return;
          }
          if (!state.processClosed && state.processExited) {
            const message = `The STDIO streams did not close within ${state.delay / 1e3} seconds of the exit event from process '${state.toolPath}'. This may indicate a child process inherited the STDIO streams and has not yet exited.`;
            state._debug(message);
          }
          state._setResult();
        }
      };
    }
  });
  
  // node_modules/@actions/exec/lib/exec.js
  var require_exec = __commonJS({
    "node_modules/@actions/exec/lib/exec.js"(exports2) {
      "use strict";
      var __createBinding = exports2 && exports2.__createBinding || (Object.create ? function(o, m, k, k2) {
        if (k2 === void 0)
          k2 = k;
        Object.defineProperty(o, k2, { enumerable: true, get: function() {
          return m[k];
        } });
      } : function(o, m, k, k2) {
        if (k2 === void 0)
          k2 = k;
        o[k2] = m[k];
      });
      var __setModuleDefault = exports2 && exports2.__setModuleDefault || (Object.create ? function(o, v) {
        Object.defineProperty(o, "default", { enumerable: true, value: v });
      } : function(o, v) {
        o["default"] = v;
      });
      var __importStar = exports2 && exports2.__importStar || function(mod) {
        if (mod && mod.__esModule)
          return mod;
        var result = {};
        if (mod != null) {
          for (var k in mod)
            if (k !== "default" && Object.hasOwnProperty.call(mod, k))
              __createBinding(result, mod, k);
        }
        __setModuleDefault(result, mod);
        return result;
      };
      var __awaiter = exports2 && exports2.__awaiter || function(thisArg, _arguments, P, generator) {
        function adopt(value) {
          return value instanceof P ? value : new P(function(resolve) {
            resolve(value);
          });
        }
        return new (P || (P = Promise))(function(resolve, reject) {
          function fulfilled(value) {
            try {
              step(generator.next(value));
            } catch (e) {
              reject(e);
            }
          }
          function rejected(value) {
            try {
              step(generator["throw"](value));
            } catch (e) {
              reject(e);
            }
          }
          function step(result) {
            result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected);
          }
          step((generator = generator.apply(thisArg, _arguments || [])).next());
        });
      };
      Object.defineProperty(exports2, "__esModule", { value: true });
      exports2.getExecOutput = exports2.exec = void 0;
      var string_decoder_1 = require("string_decoder");
      var tr = __importStar(require_toolrunner());
      function exec3(commandLine, args, options) {
        return __awaiter(this, void 0, void 0, function* () {
          const commandArgs = tr.argStringToArray(commandLine);
          if (commandArgs.length === 0) {
            throw new Error(`Parameter 'commandLine' cannot be null or empty.`);
          }
          const toolPath = commandArgs[0];
          args = commandArgs.slice(1).concat(args || []);
          const runner = new tr.ToolRunner(toolPath, args, options);
          return runner.exec();
        });
      }
      exports2.exec = exec3;
      function getExecOutput(commandLine, args, options) {
        var _a, _b;
        return __awaiter(this, void 0, void 0, function* () {
          let stdout = "";
          let stderr = "";
          const stdoutDecoder = new string_decoder_1.StringDecoder("utf8");
          const stderrDecoder = new string_decoder_1.StringDecoder("utf8");
          const originalStdoutListener = (_a = options === null || options === void 0 ? void 0 : options.listeners) === null || _a === void 0 ? void 0 : _a.stdout;
          const originalStdErrListener = (_b = options === null || options === void 0 ? void 0 : options.listeners) === null || _b === void 0 ? void 0 : _b.stderr;
          const stdErrListener = (data) => {
            stderr += stderrDecoder.write(data);
            if (originalStdErrListener) {
              originalStdErrListener(data);
            }
          };
          const stdOutListener = (data) => {
            stdout += stdoutDecoder.write(data);
            if (originalStdoutListener) {
              originalStdoutListener(data);
            }
          };
          const listeners = Object.assign(Object.assign({}, options === null || options === void 0 ? void 0 : options.listeners), { stdout: stdOutListener, stderr: stdErrListener });
          const exitCode = yield exec3(commandLine, args, Object.assign(Object.assign({}, options), { listeners }));
          stdout += stdoutDecoder.end();
          stderr += stderrDecoder.end();
          return {
            exitCode,
            stdout,
            stderr
          };
        });
      }
      exports2.getExecOutput = getExecOutput;
    }
  });
  
  // postgres/src/index.ts
  var import_core2 = __toModule(require_core());
  
  // lib/docker.ts
  var import_core = __toModule(require_core());
  var import_exec = __toModule(require_exec());
  var import_path = __toModule(require("path"));
  
  // lib/string.ts
  var import_crypto = __toModule(require("crypto"));
  function sluggify(str) {
    return str.toString().toLowerCase().replace(/\s+/g, "-").replace(/[^\w-]+/g, "-").replace(/--+/g, "-").replace(/^-+/, "").replace(/-+$/, "");
  }
  
  // lib/docker.ts
  async function startDocker({ defaultVersion: defaultVersion2, image: image2, ports }) {
    const version = (0, import_core.getInput)("version") || defaultVersion2;
    const portsArg = ports.map((port) => `-p ${port}:${port}`).join(" ");
    (0, import_core.info)(`About to start a Docker container from ${image2}:${version}`);
    await (0, import_exec.exec)(`bash docker-start.sh ${portsArg}`, void 0, {
      cwd: import_path.default.resolve(__dirname, "..", "..", "lib"),
      env: __spreadProps(__spreadValues({}, process.env), {
        NAME: sluggify(image2),
        IMAGE: image2,
        TAG: version
      })
    });
  }
  
  // lib/postgres.ts
  var import_exec2 = __toModule(require_exec());
  var import_os = __toModule(require("os"));
  var import_path2 = __toModule(require("path"));
  var image = "exivity/postgres";
  var defaultVersion = "14.0";
  async function startPostgres(password = "postgres") {
    const script = (0, import_os.platform)() === "win32" ? "postgres-start-windows.sh" : "postgres-start-linux.sh";
    await (0, import_exec2.exec)(`bash ${script}`, void 0, {
      cwd: import_path2.default.resolve(__dirname, "..", "..", "lib"),
      env: __spreadProps(__spreadValues({}, process.env), {
        ATTRIBUTES: "SUPERUSER CREATEDB CREATEROLE INHERIT LOGIN",
        PASSWORD: password
      })
    });
  }
  
  // postgres/src/index.ts
  async function run() {
    const mode = (0, import_core2.getInput)("mode") || "host";
    const password = (0, import_core2.getInput)("password") || "postgres";
    if (mode !== "docker" && mode !== "host") {
      throw new Error(`Mode must be 'docker' or 'host'`);
    }
    switch (mode) {
      case "docker":
        await startDocker({
          image,
          defaultVersion,
          ports: [5432]
        });
        break;
      case "host":
        await startPostgres(password);
        break;
    }
  }
  run().catch(import_core2.setFailed);
  