@catladder/cli 5.3.0 → 5.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. package/dist/apps/cli/src/release/changesetCheckJob.js +17 -10
  2. package/dist/apps/cli/src/release/changesetCheckJob.js.map +1 -1
  3. package/dist/bundles/catci/index.js +1 -1
  4. package/dist/bundles/catenv/index.js +42 -7
  5. package/dist/bundles/cli/index.js +42 -7
  6. package/dist/bundles/skills/catladder-deploys/SKILL.md +8 -1
  7. package/dist/bundles/skills/catladder-deploys/references/deploy-types.md +1 -1
  8. package/dist/bundles/skills/catladder-migrate-release-method/SKILL.md +4 -3
  9. package/dist/bundles/skills/catladder-releases/SKILL.md +12 -7
  10. package/dist/packages/pipeline/src/backends/gitlab/createGitlabJobs.js +7 -2
  11. package/dist/packages/pipeline/src/backends/gitlab/createGitlabJobs.js.map +1 -1
  12. package/dist/packages/pipeline/src/backends/gitlab/gitlabReleaseJobs.js +5 -3
  13. package/dist/packages/pipeline/src/backends/gitlab/gitlabReleaseJobs.js.map +1 -1
  14. package/dist/packages/pipeline/src/backends/types.d.ts +6 -2
  15. package/dist/packages/pipeline/src/customImages/hash.d.ts +4 -0
  16. package/dist/packages/pipeline/src/customImages/hash.js +3 -0
  17. package/dist/packages/pipeline/src/customImages/hash.js.map +1 -1
  18. package/dist/packages/pipeline/src/customImages/jobImagesPlan.d.ts +2 -1
  19. package/dist/packages/pipeline/src/customImages/jobImagesPlan.js +21 -1
  20. package/dist/packages/pipeline/src/customImages/jobImagesPlan.js.map +1 -1
  21. package/dist/packages/pipeline/src/pipeline/generatePipelineFiles.js +1 -1
  22. package/dist/packages/pipeline/src/pipeline/generatePipelineFiles.js.map +1 -1
  23. package/dist/packages/pipeline/src/utils/writeFiles.d.ts +2 -1
  24. package/dist/packages/pipeline/src/utils/writeFiles.js +5 -0
  25. package/dist/packages/pipeline/src/utils/writeFiles.js.map +1 -1
  26. package/dist/skills/catladder-deploys/SKILL.md +8 -1
  27. package/dist/skills/catladder-deploys/references/deploy-types.md +1 -1
  28. package/dist/skills/catladder-migrate-release-method/SKILL.md +4 -3
  29. package/dist/skills/catladder-releases/SKILL.md +12 -7
  30. package/dist/tsconfig.tsbuildinfo +1 -1
  31. package/package.json +1 -1
  32. package/src/release/__tests__/changesetCheckJob.test.ts +68 -0
  33. package/src/release/changesetCheckJob.ts +18 -10
@@ -1,4 +1,4 @@
1
- (()=>{var __webpack_modules__={403:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.gitConfigSet=t.gitConfigGet=void 0;const n=r(1542);const argsJoin=e=>e.filter(Boolean).join(" ");async function gitConfigGet(e,{location:t}={}){const{stdout:r}=await(0,n.exec)(`git config --get ${argsJoin([t?`--${t}`:undefined])} ${e}`);return r.trim()}t.gitConfigGet=gitConfigGet;const gitConfigSet=(e,t,{location:r,comment:s}={})=>(0,n.exec)(`git config --set ${argsJoin([r?`--${r}`:undefined,s?`--comment=${s}`:undefined])} ${e} ${t}`);t.gitConfigSet=gitConfigSet},6884:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.gitProjectInformation=t.getGitRemoteHostAndPath=t.getProjectRootPath=void 0;const n=r(403);const s=r(1542);const getProjectRootPath=async()=>{const{stdout:e}=await(0,s.exec)(`git rev-parse --show-toplevel`);return e.trim()};t.getProjectRootPath=getProjectRootPath;const getGitRemoteHostAndPath=async(e="origin")=>{var t;const r=await(0,n.gitConfigGet)(`remote.${e}.url`);const s=/(https:\/\/|git@)([^:/]+)[:/]([^.]*)(\.git)?/;const o=(t=r.match(s))!==null&&t!==void 0?t:[];const[,,i,a]=o;if(!(i===null||i===void 0?void 0:i.length)||!(a===null||a===void 0?void 0:a.length)){throw new Error(`Failed to parse git remote hostname and path from git configs remote.${e}.url! ${r}`)}return{gitRemoteHost:i,gitRemotePath:a}};t.getGitRemoteHostAndPath=getGitRemoteHostAndPath;const gitProjectInformation=async()=>{const[{gitRemoteHost:e,gitRemotePath:r},n]=await Promise.all([(0,t.getGitRemoteHostAndPath)(),(0,t.getProjectRootPath)()]);return{gitRemoteHost:e,gitRemotePath:r,projectRootPath:n}};t.gitProjectInformation=gitProjectInformation},3961:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.parseNpmPublishArgs=t.npmPublishJob=t.DEFAULT_NPM_REGISTRY=void 0;const n=r(5317);const s=r(1943);const o=r(6928);const i=r(1535);t.DEFAULT_NPM_REGISTRY="https://registry.npmjs.org/";const readCiContext=e=>{var t,r,n,s;const o=process.env;if(o.GITLAB_CI==="true"){return{ciTag:o.CI_COMMIT_TAG||null,refSlug:(t=o.CI_COMMIT_REF_SLUG)!==null&&t!==void 0?t:"",shortSha:(r=o.CI_COMMIT_SHORT_SHA)!==null&&r!==void 0?r:""}}if(o.GITHUB_ACTIONS==="true"){return{ciTag:o.GITHUB_REF_TYPE==="tag"?(n=o.GITHUB_REF_NAME)!==null&&n!==void 0?n:null:null,refSlug:(0,i.slugifyRef)(o.GITHUB_HEAD_REF||o.GITHUB_REF_NAME||""),shortSha:((s=o.GITHUB_SHA)!==null&&s!==void 0?s:"").slice(0,8)}}throw new Error(`publish npm for "${e.dir}" must run in a gitlab or github CI job (no CI provider detected)`)};const setPackageVersion=async(e,t)=>{const r=(0,o.join)(e,"package.json");const n=JSON.parse(await(0,s.readFile)(r,"utf-8"));n.version=t;await(0,s.writeFile)(r,JSON.stringify(n,null,2)+"\n");return n.name};const writeNpmrc=async(e,t)=>{const r=t.replace(/^https?:/,"").replace(/\/?$/,"/");const n=(0,o.resolve)(e,".npmrc");await(0,s.writeFile)(n,`${r}:_authToken=\${NPM_TOKEN}\n`);return n};const hasOidcCredentials=()=>!!process.env.ACTIONS_ID_TOKEN_REQUEST_URL&&!!process.env.ACTIONS_ID_TOKEN_REQUEST_TOKEN;const npmPublish=(e,t,r)=>new Promise(((s,o)=>{const i=(0,n.spawn)("npm",["publish",...r],{cwd:e,stdio:"inherit",env:{...process.env,...t?{NPM_CONFIG_USERCONFIG:t}:{}}});i.on("error",o);i.on("exit",(e=>e===0?s():o(new Error(`npm publish exited with ${e}`))))}));const npmPublishJob=async e=>{var r,n;const s=hasOidcCredentials();if(!s&&!process.env.NPM_TOKEN){throw new Error("NPM_TOKEN is not set — configure it as a catladder secret for this component, or publish from a workflow registered as a trusted publisher on npm")}const o=(r=e.registry)!==null&&r!==void 0?r:t.DEFAULT_NPM_REGISTRY;const a=(0,i.computeNpmPublishPlan)({envType:e.envType,distTagOverride:e.distTag,...readCiContext(e)});const c=await setPackageVersion(e.dir,a.version);const u=s&&!process.env.NPM_TOKEN?undefined:await writeNpmrc(e.dir,o);console.log(`publishing ${c}@${a.version} (dist-tag ${a.distTag}) to ${o}${u?"":" via trusted publishing (OIDC)"}`);await npmPublish(e.dir,u,["--tag",a.distTag,"--access",(n=e.access)!==null&&n!==void 0?n:"public","--registry",o,"--workspaces=false"]);console.log(`published ${c}@${a.version} 🚀`)};t.npmPublishJob=npmPublishJob;const parseNpmPublishArgs=e=>{const t={};for(let r=0;r<e.length;r+=2){const n=e[r];const s=e[r+1];if(!(n===null||n===void 0?void 0:n.startsWith("--"))||s===undefined)return null;t[n.slice(2)]=s}const{dir:r,access:n,registry:s}=t;const o=t["env-type"];const i=t["dist-tag"];if(!r||!o)return null;return{dir:r,envType:o,access:n,registry:s,distTag:i}};t.parseNpmPublishArgs=parseNpmPublishArgs},1535:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.slugifyRef=t.computeNpmPublishPlan=t.BRANCH_DIST_TAGS=void 0;t.BRANCH_DIST_TAGS=["next","beta"];const computeNpmPublishPlan=e=>{var r,n;if(e.envType==="prod"||e.envType==="stage"){if(!e.ciTag){throw new Error(`npm publish for env type "${e.envType}" expects a tagged-release pipeline, but no git tag is set`)}return{version:e.ciTag.replace(/^v/,""),distTag:(r=e.distTagOverride)!==null&&r!==void 0?r:"latest"}}return{version:`0.0.0-${e.refSlug}-${e.shortSha}`,distTag:(n=e.distTagOverride)!==null&&n!==void 0?n:t.BRANCH_DIST_TAGS.includes(e.refSlug)?e.refSlug:"canary"}};t.computeNpmPublishPlan=computeNpmPublishPlan;const slugifyRef=e=>e.toLowerCase().replace(/[^0-9a-z]/g,"-").slice(0,63).replace(/^-+|-+$/g,"");t.slugifyRef=slugifyRef},118:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.runChangesetCheck=t.CHANGESET_CHECK_MARKER=void 0;const n=r(4423);t.CHANGESET_CHECK_MARKER="\x3c!-- catladder-changeset-check --\x3e";const runChangesetCheck=({addedFiles:e,pending:r,lastTag:s,requestLabel:o,packageManager:i})=>{const a=e.length>0;const c=[t.CHANGESET_CHECK_MARKER,"## đŸĻ‹ Changeset check",""];if(a){c.push(`✅ This ${o} adds ${e.length} changeset${e.length===1?"":"s"}: ${e.map((e=>`\`${e}\``)).join(", ")}`)}else{c.push(`âš ī¸ **This ${o} adds no changeset.** If the change is user-facing it will be missing from the next release's changelog — add \`.changeset/<name>.md\` (or run \`${i} changeset\`). For docs/chore changes this warning can be ignored.`)}c.push("");if(r.length===0){c.push("No changesets are pending — merging will **not** trigger a release.")}else{const e=(0,n.getNextVersion)(s,(0,n.maxBump)(r.map((e=>e.bump))));c.push(`${r.length} changeset${r.length===1?" is":"s are"} pending after merge — the next release will be **v${e}**${s?` (from ${s})`:" (first release)"}:`,"","<details><summary>Changelog preview</summary>","",(0,n.renderChangelogEntries)(r),"","</details>")}return{addsChangeset:a,markdown:c.join("\n")}};t.runChangesetCheck=runChangesetCheck},291:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.changesetCheckJob=t.CHANGESET_REPORT_FILE=void 0;const n=r(9896);const s=r(1943);const o=r(118);const i=r(7307);const a=r(1177);const c=r(4074);t.CHANGESET_REPORT_FILE="changeset-report.md";const onGithub=()=>process.env.GITHUB_ACTIONS==="true";const detectPackageManager=()=>(0,n.existsSync)("pnpm-lock.yaml")?"pnpm":"yarn";const getAddedChangesetFiles=async()=>{const e=onGithub()?process.env.GITHUB_BASE_REF:process.env.CI_MERGE_REQUEST_TARGET_BRANCH_NAME;if(!e){return null}await(0,a.git)("fetch","--quiet","origin",e);const t=await(0,a.git)("merge-base","HEAD","FETCH_HEAD");const r=await(0,a.git)("diff","--name-only","--diff-filter=A",t,"HEAD");return r.split("\n").filter((e=>e.startsWith(".changeset/")&&e.endsWith(".md")&&!e.toLowerCase().endsWith("readme.md"))).map((e=>e.slice(".changeset/".length)))};const findSticky=e=>e.find((e=>{var t;return(t=e.body)===null||t===void 0?void 0:t.includes(o.CHANGESET_CHECK_MARKER)}));const request=async(e,t)=>{var r;const n=await fetch(e,t);if(!n.ok){throw new Error(`${(r=t.method)!==null&&r!==void 0?r:"GET"} ${e} failed: ${n.status} ${await n.text()}`)}return n};const upsertGithubComment=async e=>{var t,r;const n=process.env.GITHUB_TOKEN;const s=(t=process.env.GITHUB_API_URL)!==null&&t!==void 0?t:"https://api.github.com";const o=process.env.GITHUB_REPOSITORY;const i=parseInt((r=process.env.GITHUB_REF_NAME)!==null&&r!==void 0?r:"");if(!n||!o||!i){console.log("no PR context/token — skipping the PR comment");return}const a={authorization:`Bearer ${n}`,accept:"application/vnd.github+json","content-type":"application/json"};const c=await(await request(`${s}/repos/${o}/issues/${i}/comments?per_page=100`,{headers:a})).json();const u=findSticky(c);if(u){await request(`${s}/repos/${o}/issues/comments/${u.id}`,{method:"PATCH",headers:a,body:JSON.stringify({body:e})})}else{await request(`${s}/repos/${o}/issues/${i}/comments`,{method:"POST",headers:a,body:JSON.stringify({body:e})})}console.log("updated the sticky PR comment")};const upsertGitlabComment=async e=>{const t=process.env.GL_TOKEN;if(!t){console.log("GL_TOKEN is not available in this pipeline — skipping the MR comment (report available in the job log and the exposed artifact)");return}const r=process.env.CI_API_V4_URL;const n=process.env.CI_PROJECT_ID;const s=process.env.CI_MERGE_REQUEST_IID;if(!r||!n||!s){console.log("no MR context — skipping the MR comment");return}const o={"PRIVATE-TOKEN":t,"content-type":"application/json"};const i=`${r}/projects/${n}/merge_requests/${s}/notes`;const a=await(await request(`${i}?per_page=100`,{headers:o})).json();const c=findSticky(a);if(c){await request(`${i}/${c.id}`,{method:"PUT",headers:o,body:JSON.stringify({body:e})})}else{await request(i,{method:"POST",headers:o,body:JSON.stringify({body:e})})}console.log("updated the sticky MR comment")};const changesetCheckJob=async()=>{await(0,a.ensureReleaseHistory)();const e=await(0,i.readPendingChangesets)();const r=await(0,a.getLastReleaseTag)();const n=await getAddedChangesetFiles();const u=(0,o.runChangesetCheck)({addedFiles:n!==null&&n!==void 0?n:[],pending:e,lastTag:r,requestLabel:onGithub()?"pull request":"merge request",packageManager:detectPackageManager()});console.log(u.markdown.replace(`${o.CHANGESET_CHECK_MARKER}\n`,""));await(0,s.writeFile)(t.CHANGESET_REPORT_FILE,u.markdown);try{if(onGithub()){await upsertGithubComment(u.markdown)}else{await upsertGitlabComment(u.markdown)}}catch(e){console.warn(`could not update the sticky comment: ${e}`)}if(n===null){console.log("not running against a merge request — check skipped");return}if(!u.addsChangeset){if(onGithub()){console.log("::warning title=No changeset::this pull request adds no changeset — "+"if the change is user-facing, add one so it appears in the next release's changelog");(0,c.appendStepSummary)(u.markdown.replace(`${o.CHANGESET_CHECK_MARKER}\n`,""));return}process.exitCode=1}};t.changesetCheckJob=changesetCheckJob},4423:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.prependToChangelog=t.renderChangelogEntries=t.getNextVersion=t.maxBump=t.parseChangesetFile=t.BUMPS=void 0;const s=n(r(492));t.BUMPS=["patch","minor","major"];const isBump=e=>t.BUMPS.includes(e);const parseChangesetFile=(e,r)=>{let n;try{n=(0,s.default)(r)}catch(t){throw new Error(`${e}: not a valid changeset (${t instanceof Error?t.message:t})`)}const o=n.releases.map((e=>e.type)).filter(isBump);if(o.length===0){throw new Error(`${e}: changeset declares no effective version bump (major|minor|patch)`)}const i=n.summary.trim();if(i===""){throw new Error(`${e}: changeset has no summary`)}return{fileName:e,bump:(0,t.maxBump)(o),summary:i}};t.parseChangesetFile=parseChangesetFile;const maxBump=e=>e.reduce(((e,r)=>t.BUMPS.indexOf(r)>t.BUMPS.indexOf(e)?r:e));t.maxBump=maxBump;const getNextVersion=(e,t)=>{if(e===null){return"1.0.0"}const r=e.match(/^v(\d+)\.(\d+)\.(\d+)$/);if(!r){throw new Error(`last release tag "${e}" is not of the form vX.Y.Z — cannot derive the next version`)}const[n,s,o]=r.slice(1).map(Number);switch(t){case"major":return`${n+1}.0.0`;case"minor":return`${n}.${s+1}.0`;case"patch":return`${n}.${s}.${o+1}`}};t.getNextVersion=getNextVersion;const o={major:"Major Changes",minor:"Minor Changes",patch:"Patch Changes"};const renderChangelogEntries=e=>[...t.BUMPS].reverse().map((t=>{const r=e.filter((e=>e.bump===t));if(r.length===0)return null;return[`### ${o[t]}`,"",...r.map((e=>`- ${e.summary.replace(/\r?\n/g,"\n ")}`))].join("\n")})).filter((e=>e!==null)).join("\n\n");t.renderChangelogEntries=renderChangelogEntries;const i="# Changelog";const prependToChangelog=(e,t,r,n)=>{const s=`## ${t} (${r})\n\n${n}\n`;const o=(e!==null&&e!==void 0?e:"").replace(new RegExp(`^${i}\\s*\\n`),"").trim();return[i,"",s+(o?"\n"+o+"\n":"")].join("\n")};t.prependToChangelog=prependToChangelog},7307:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.changesetsReleaseJob=t.dispatchTaggedReleaseWorkflow=t.readPendingChangesets=void 0;const n=r(9896);const s=r(1943);const o=r(6928);const i=r(4423);const a=r(4023);const c=r(1177);const u=r(881);const l=r(4074);const p=".changeset";const d="CHANGELOG.md";const f="catladder-release.yml";const readPendingChangesets=async()=>{const e=await(0,s.readdir)(p).catch((()=>[]));const t=e.filter((e=>e.endsWith(".md")&&e.toLowerCase()!=="readme.md"));return Promise.all(t.map((async e=>(0,i.parseChangesetFile)(e,await(0,s.readFile)((0,o.join)(p,e),"utf-8")))))};t.readPendingChangesets=readPendingChangesets;const ensureGitIdentity=async()=>{const e=await(0,c.git)("config","user.email").catch((()=>""));if(e!=="")return;const t=process.env.GITHUB_ACTIONS==="true";await(0,c.git)("config","user.name",t?"github-actions[bot]":"catladder");await(0,c.git)("config","user.email",t?"41898282+github-actions[bot]@users.noreply.github.com":"catladder-release@panter.ch")};const requireEnv=e=>{const t=process.env[e];if(!t){throw new Error(`${e} is not set — cannot push the release`)}return t};const pushCommitAndTag=async e=>{var t;if(process.env.GITHUB_ACTIONS==="true"){const r=requireEnv("GITHUB_REF_NAME");const n=[`HEAD:refs/heads/${r}`,e];const s=(0,a.getReleaseDeployKey)();if(s){await(0,a.pushWithDeployKey)(s,n);return}try{await(0,c.git)("push","--atomic","origin",...n)}catch(e){if(/GH006|GH013|protected branch|rule violations/i.test(`${(t=e===null||e===void 0?void 0:e.message)!==null&&t!==void 0?t:e}`)){throw new Error(`pushing the release to '${r}' was rejected by its branch protection:\n`+`${e.message}\n`+`The workflow token cannot bypass a required status check on '${r}'. `+`Run \`catladder project setup\` to provision the release deploy key `+`(${a.RELEASE_DEPLOY_KEY_ENV} secret + ruleset bypass), then rerun this job.`)}throw e}return}const r=requireEnv("GL_TOKEN");const n=requireEnv("CI_SERVER_HOST");const s=requireEnv("CI_PROJECT_PATH");const o=requireEnv("CI_COMMIT_BRANCH");const i=`https://oauth2:${r}@${n}/${s}.git`;await(0,c.git)("push","--atomic",i,`HEAD:refs/heads/${o}`,e)};const dispatchTaggedReleaseWorkflow=async e=>{var t;const r=(t=process.env.GITHUB_API_URL)!==null&&t!==void 0?t:"https://api.github.com";const n=requireEnv("GITHUB_REPOSITORY");const s=requireEnv("GITHUB_TOKEN");const o=await fetch(`${r}/repos/${n}/actions/workflows/${f}/dispatches`,{method:"POST",headers:{authorization:`Bearer ${s}`,accept:"application/vnd.github+json"},body:JSON.stringify({ref:e})});if(!o.ok){throw new Error(`dispatching ${f} for ${e} failed: ${o.status} ${await o.text()}`)}console.log(`dispatched ${f} for ${e}`)};t.dispatchTaggedReleaseWorkflow=dispatchTaggedReleaseWorkflow;const h={fileName:"",bump:"patch",summary:"Forced release without pending changesets."};const changesetsReleaseJob=async()=>{const e=await(0,t.readPendingChangesets)();const r=e.length===0&&process.env.CATLADDER_FORCE_RELEASE==="true";if(e.length===0&&!r){console.log(`no changesets found in ${p}/ — nothing to release`);console.log(`add one with \`${(0,n.existsSync)("pnpm-lock.yaml")?"pnpm":"yarn"} changeset\` (or write .changeset/<name>.md by hand) and merge it to release`);console.log("to release anyway (patch bump), run the force release job instead");(0,l.appendStepSummary)(`â„šī¸ **Nothing released** — no pending changesets in \`${p}/\`. `+"Merge a changeset and release again, or force the release for a patch bump.");return}const a=r?[h]:e;if(r){console.log("no changesets pending — forced release, bumping a patch")}await(0,c.ensureReleaseHistory)();const f=await(0,c.getLastReleaseTag)();const g=(0,i.getNextVersion)(f,(0,i.maxBump)(a.map((e=>e.bump))));const m=`v${g}`;console.log(`releasing ${m} (${f!==null&&f!==void 0?f:"first release"} + ${a.length} changeset(s))`);const y=(0,i.renderChangelogEntries)(a);const v=await(0,s.readFile)(d,"utf-8").catch((()=>null));const $=(new Date).toISOString().slice(0,10);await(0,s.writeFile)(d,(0,i.prependToChangelog)(v,g,$,y));await Promise.all(e.map((e=>(0,s.rm)((0,o.join)(p,e.fileName)))));await ensureGitIdentity();if(r){await(0,c.git)("add",d)}else{await(0,c.git)("add",d,p)}const b=process.env.GITHUB_ACTIONS==="true";const w=`chore(release): ${g}${b?" [skip ci]":""}`;await(0,c.git)("commit","-m",`${w}\n\n${y}`);await(0,c.git)("tag",m);await pushCommitAndTag(m);console.log(`released ${m}`);(0,l.appendStepSummary)(`🚀 **Released ${m}**\n\n${y}`);await(0,u.createReleaseEntry)(m,y);if(process.env.GITHUB_ACTIONS==="true"){await(0,t.dispatchTaggedReleaseWorkflow)(m)}};t.changesetsReleaseJob=changesetsReleaseJob},4023:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.githubDeployKeyRemoteJob=t.configureDeployKeyRemote=t.pushWithDeployKey=t.writeDeployKeyFile=t.deployKeySshCommand=t.deployKeyRemoteUrl=t.getReleaseDeployKey=t.RELEASE_DEPLOY_KEY_ENV=void 0;const n=r(1943);const s=r(857);const o=r(6928);const i=r(1177);t.RELEASE_DEPLOY_KEY_ENV="CATLADDER_RELEASE_KEY";const a="catladder release";const requireEnv=e=>{const t=process.env[e];if(!t){throw new Error(`${e} is not set — cannot push the release`)}return t};const getReleaseDeployKey=()=>process.env[t.RELEASE_DEPLOY_KEY_ENV]||null;t.getReleaseDeployKey=getReleaseDeployKey;const deployKeyRemoteUrl=()=>{var e;const t=(e=process.env.GITHUB_SERVER_URL)!==null&&e!==void 0?e:"https://github.com";const r=new URL(t).host;const n=requireEnv("GITHUB_REPOSITORY");return`git@${r}:${n}.git`};t.deployKeyRemoteUrl=deployKeyRemoteUrl;const deployKeySshCommand=e=>`ssh -i ${e} -o IdentitiesOnly=yes -o StrictHostKeyChecking=accept-new`;t.deployKeySshCommand=deployKeySshCommand;const writeDeployKeyFile=async e=>{const t=await(0,n.mkdtemp)((0,o.join)((0,s.tmpdir)(),"release-key-"));const r=(0,o.join)(t,"id_ed25519");await(0,n.writeFile)(r,e.endsWith("\n")?e:`${e}\n`,{mode:384});return{dir:t,keyFile:r}};t.writeDeployKeyFile=writeDeployKeyFile;const pushWithDeployKey=async(e,r)=>{const{dir:s,keyFile:o}=await(0,t.writeDeployKeyFile)(e);try{await(0,i.gitWithEnv)({GIT_SSH_COMMAND:(0,t.deployKeySshCommand)(o)},"push","--atomic",(0,t.deployKeyRemoteUrl)(),...r)}finally{await(0,n.rm)(s,{recursive:true,force:true})}};t.pushWithDeployKey=pushWithDeployKey;const configureDeployKeyRemote=async e=>{var r;const n=(0,t.deployKeyRemoteUrl)();const{keyFile:s}=await(0,t.writeDeployKeyFile)(e);await(0,i.git)("config","core.sshCommand",(0,t.deployKeySshCommand)(s));try{await(0,i.git)("ls-remote","--exit-code",n,"HEAD")}catch(e){throw new Error(`the release deploy key cannot reach ${n}: ${(r=e===null||e===void 0?void 0:e.message)!==null&&r!==void 0?r:e}\n`+`The ${t.RELEASE_DEPLOY_KEY_ENV} secret does not match the '${a}' deploy key of the repository `+`(or the key was removed). Run \`catladder project setup\` to provision both again, then rerun this job.`)}return n};t.configureDeployKeyRemote=configureDeployKeyRemote;const githubDeployKeyRemoteJob=async()=>{const e=(0,t.getReleaseDeployKey)();if(!e){throw new Error(`${t.RELEASE_DEPLOY_KEY_ENV} is not set — the release push cannot use the deploy key `+`(without merge gating the workflow token push works: run semantic-release without --repository-url)`)}const r=await(0,t.configureDeployKeyRemote)(e);console.error(`release push: ${r} over ssh with the release deploy key (bypasses the merge-gating ruleset)`);process.stdout.write(`${r}\n`)};t.githubDeployKeyRemoteJob=githubDeployKeyRemoteJob},7695:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.githubQueuedGuardJob=t.githubQueueCheckJob=void 0;const n=r(9896);const s=r(1177);const o=r(4074);const i="catladder-main.yml";const a="catladder-release-on-green.yml";const c="refs/catladder/release-queued";const ensureGitSafeDirectory=async()=>{await(0,s.git)("config","--global","--add","safe.directory",process.cwd())};const requireEnv=e=>{const t=process.env[e];if(!t){throw new Error(`${e} is not set`)}return t};const fail=e=>{console.error(e);process.exit(1)};const setStepOutput=(e,t)=>{const r=process.env.GITHUB_OUTPUT;if(!r){return}(0,n.appendFileSync)(r,`${e}=${t}\n`)};const getMainWorkflowRun=async e=>{var t,r,n;const s=(t=process.env.GITHUB_API_URL)!==null&&t!==void 0?t:"https://api.github.com";const o=requireEnv("GITHUB_REPOSITORY");const a=requireEnv("GITHUB_TOKEN");const c=await fetch(`${s}/repos/${o}/actions/workflows/${i}/runs?head_sha=${e}&per_page=5`,{headers:{authorization:`Bearer ${a}`,accept:"application/vnd.github+json"}});if(!c.ok){throw new Error(`listing ${i} runs failed: ${c.status} ${await c.text()}`)}const u=await c.json();return(n=(r=u.workflow_runs)===null||r===void 0?void 0:r[0])!==null&&n!==void 0?n:null};const githubQueueCheckJob=async()=>{await ensureGitSafeDirectory();const e=await(0,s.git)("rev-parse","HEAD");const t=await getMainWorkflowRun(e);if(!t){console.log(`no main workflow run found for ${e} — releasing right away`);(0,o.appendStepSummary)(`â„šī¸ No main workflow run found for \`${e}\` — releasing right away.`);setStepOutput("queued","false");return}if(t.status==="completed"){if(t.conclusion==="success"){console.log(`main workflow for ${e} succeeded — releasing right away`);(0,o.appendStepSummary)(`✅ The main workflow for \`${e}\` succeeded — releasing right away.`);setStepOutput("queued","false");return}(0,o.appendStepSummary)(`❌ Not releasing: the ${(0,o.workflowLink)(i,"main workflow")} run for \`${e}\` concluded **${t.conclusion}**. `+`Fix the pipeline, or re-run with the force checkbox to release anyway.`);fail(`the main workflow for ${e} concluded '${t.conclusion}' — `+`fix the pipeline, or force the release to release anyway`)}await(0,s.git)("push","origin",`+${e}:${c}`);const r=t.status.replace(/_/g," ");console.log(`main workflow for ${e} is ${r} — release queued: `+`the 'release on green' workflow creates the release as soon as the run succeeds`);(0,o.appendStepSummary)(`âŗ **Release queued** for \`${e}\` — the ${(0,o.workflowLink)(i,"main workflow")} run is still ${r}. `+`${(0,o.workflowLink)(a,"release on green")} creates the release as soon as it succeeds.`);setStepOutput("queued","true")};t.githubQueueCheckJob=githubQueueCheckJob;const githubQueuedGuardJob=async(e,t)=>{var r;await ensureGitSafeDirectory();const n=await(0,s.git)("ls-remote","origin",c);const i=(r=n.split(/\s+/)[0])!==null&&r!==void 0?r:"";if(!i){console.log("no release queued — nothing to do");(0,o.appendStepSummary)("No release queued — nothing to do.");setStepOutput("release","false");return}if(i!==e){console.log(`queued release is for ${i}, this run is for ${e} — leaving the queue untouched`);(0,o.appendStepSummary)(`Queued release is for \`${i}\`, this run is for \`${e}\` — leaving the queue untouched.`);setStepOutput("release","false");return}await(0,s.git)("push","origin",`:${c}`);if(t!=="success"){(0,o.appendStepSummary)(`❌ Queued release for \`${e}\` **not executed**: the main workflow concluded **${t}**. `+`Fix the pipeline and queue again via the 🚀 create release workflow.`);fail(`queued release not executed: the main workflow concluded '${t}' — `+`fix the pipeline and queue the release again`)}console.log(`main workflow for ${e} succeeded — releasing`);(0,o.appendStepSummary)(`✅ Main workflow for \`${e}\` succeeded — running the queued release.`);setStepOutput("release","true")};t.githubQueuedGuardJob=githubQueuedGuardJob},881:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createReleaseEntry=void 0;const post=async(e,t,r)=>{const n=await fetch(e,{method:"POST",headers:{"content-type":"application/json",...t},body:JSON.stringify(r)});if(!n.ok){throw new Error(`POST ${e} failed: ${n.status} ${await n.text()}`)}};const createGitlabReleaseEntry=async(e,t)=>{const r=process.env.GL_TOKEN;const n=process.env.CI_API_V4_URL;const s=process.env.CI_PROJECT_ID;if(!r||!n||!s){console.warn("no GL_TOKEN / gitlab api context — skipping the release entry (the tag is pushed)");return}await post(`${n}/projects/${s}/releases`,{"PRIVATE-TOKEN":r},{tag_name:e,description:t});console.log(`created the gitlab release entry for ${e}`)};const createGithubReleaseEntry=async(e,t)=>{var r;const n=process.env.GITHUB_TOKEN;const s=(r=process.env.GITHUB_API_URL)!==null&&r!==void 0?r:"https://api.github.com";const o=process.env.GITHUB_REPOSITORY;if(!n||!o){console.warn("no GITHUB_TOKEN / repository context — skipping the release entry (the tag is pushed)");return}await post(`${s}/repos/${o}/releases`,{authorization:`Bearer ${n}`,accept:"application/vnd.github+json"},{tag_name:e,name:e,body:t});console.log(`created the github release entry for ${e}`)};const createReleaseEntry=async(e,t)=>{try{if(process.env.GITHUB_ACTIONS==="true"){await createGithubReleaseEntry(e,t)}else{await createGitlabReleaseEntry(e,t)}}catch(t){console.warn(`âš ī¸ could not create the release entry for ${e}: ${t}\n`+"the release itself is done (commit, tag and changelog are pushed) — "+"create the entry by hand if you need it")}};t.createReleaseEntry=createReleaseEntry},1177:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.getLastReleaseTag=t.ensureReleaseHistory=t.gitWithEnv=t.git=void 0;const n=r(5317);const s=r(9023);const o=(0,s.promisify)(n.execFile);const git=async(...e)=>{const{stdout:t}=await o("git",e);return t.trim()};t.git=git;const gitWithEnv=async(e,...t)=>{const{stdout:r}=await o("git",t,{env:{...process.env,...e}});return r.trim()};t.gitWithEnv=gitWithEnv;const ensureReleaseHistory=async()=>{const e=await(0,t.git)("rev-parse","--is-shallow-repository").catch((()=>"false"));try{if(e==="true"){await(0,t.git)("fetch","--quiet","--unshallow","--tags","origin")}else{await(0,t.git)("fetch","--quiet","--tags","origin")}}catch(e){console.warn(`could not fetch tags from origin (${e}) — version derivation may be wrong on a shallow clone`)}};t.ensureReleaseHistory=ensureReleaseHistory;const getLastReleaseTag=async()=>{try{return await(0,t.git)("describe","--tags","--abbrev=0","--match","v[0-9]*")}catch(e){return null}};t.getLastReleaseTag=getLastReleaseTag},4074:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.workflowLink=t.appendStepSummary=void 0;const n=r(9896);const appendStepSummary=e=>{const t=process.env.GITHUB_STEP_SUMMARY;if(!t){return}(0,n.appendFileSync)(t,e+"\n")};t.appendStepSummary=appendStepSummary;const workflowLink=(e,t)=>{var r;const n=(r=process.env.GITHUB_SERVER_URL)!==null&&r!==void 0?r:"https://github.com";const s=process.env.GITHUB_REPOSITORY;if(!s){return t}return`[${t}](${n}/${s}/actions/workflows/${e})`};t.workflowLink=workflowLink},2759:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.evaluateDocument=t.makeTemplate=void 0;const s=n(r(6743));const o=s.default;const i="✅";const a="❌";const c=`${i}/${a}`;const u="@...";const l=[["Responsible",c,"Description","Note","More Information"]].concat(o.map((e=>[Array(e.responsibles).fill(u).join(", "),c,e.description,"",e.more])));function makeTable(e){const t=calculateColumnWidths(e);return`\n${makeRow(e[0],t," ")}\n${makeRow(e[0].map((()=>"")),t,"-")}\n${e.slice(1).map((e=>makeRow(e,t," "))).join("\n")}\n`}function calculateColumnWidths(e){const t=e[0].length;return Array.from({length:t},((e,t)=>t)).map((t=>Math.max(...e.map((e=>e[t].length)))))}function makeRow(e,t,r){return`| ${e.map(((e,n)=>e.padEnd(t[n],r))).join(" | ")} |`}function makeTemplate(){return`\n# Security Audit Report\n\nA security audit report document is a comprehensive assessment of an application's security posture, containing security topics that auditors can mark to indicate the state of various security aspects.\n\nIt serves as a structured guide for security team to evaluate different security factors such as authentication, authorization, data encryption, input validation, and more.\n\n## General Information\n\n- Project Owner is @...\n- Dev team:\n - @...\n - @...\n - @...\n\n## Project Security\n\n${makeTable(l)}\n\n`}t.makeTemplate=makeTemplate;function evaluateDocument(e){var t,r;const n=(r=(t=e.match(/^\s*\|.*?\|\s*$/gm))===null||t===void 0?void 0:t.map((e=>e.trim())))!==null&&r!==void 0?r:[];const s=n.map((e=>e.split("|").map((e=>e.trim())))).slice(2);const a=new Set(o.map((e=>e.description)));const l=s.map((e=>{const t=e[1].split(", ");const r=e[2];const n=e[3];const s=e[4];const o=!a.has(n);const l=!o&&!r.includes(c)&&!t.some((e=>e.includes(u)));const p=!o&&l&&r.includes(i);return{responsibles:t,answer:r,description:n,note:s,isUnknown:o,isAnswered:l,isSecured:p}}));const p=o.length;const d=l.filter((e=>e.isAnswered)).length;const f=l.filter((e=>e.isSecured)).length;const h=l.filter((e=>e.isUnknown)).length;const g=Math.round(f/p*100);return{topics:l,score:{rating:g,totalTopics:p,answeredTopics:d,securedTopics:f,unknownTopics:h}}}t.evaluateDocument=evaluateDocument},6289:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createSecurityAuditMergeRequest=t.SECURITY_AUDIT_FILE_NAME=void 0;const n=r(9226);const s=r(2759);function makeDatedBranchName(e){const t=(new Date).toISOString().slice(0,-5).replaceAll(/[:.T]/g,"-");return`${e}-${t}`}const o="Draft: chore(security): add security audit document";t.SECURITY_AUDIT_FILE_NAME="SECURITY.md";async function createSecurityAuditMergeRequest({projectId:e,mainBranch:r,userId:i,api:a}){const c=(await n.Result.wrapAsync((()=>a.MergeRequests.all({state:"opened",wip:"yes",labels:"security-audit"})))).mapErr((()=>`could not search for existing merge requests`));if(c.isErr())return c;const u=c.value[0];if(u)return(0,n.Err)(`open merge request with security audit already exists: ${u.web_url}`);const l=n.Result.wrap((()=>(0,s.makeTemplate)())).mapErr((()=>"could not make security audit template document"));if(l.isErr())return l;const p=(await n.Result.wrapAsync((()=>a.Branches.create(e,makeDatedBranchName("chore/security-audit"),r)))).mapErr((e=>{console.log(e);return"could not create branch"}));if(p.isErr())return p;const d=(await n.Result.wrapAsync((()=>a.Commits.create(e,p.value.name,"chore(security): add empty security audit document template",[{action:"create",filePath:t.SECURITY_AUDIT_FILE_NAME,content:l.value,encoding:"text"}])))).mapErr((()=>"could not create commit"));if(d.isErr())return d;const f=(await n.Result.wrapAsync((()=>a.MergeRequests.create(e,p.value.name,r,o,{description:`Please follow and update security audit document in \`${t.SECURITY_AUDIT_FILE_NAME}\`.`,assigneeId:i,squash:true,labels:"security-audit",removeSourceBranch:true})))).mapErr((()=>"could not create merge request"));return f}t.createSecurityAuditMergeRequest=createSecurityAuditMergeRequest},8725:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.makeSecurityAuditOverview=t.evaluateSecurityAudit=void 0;const n=r(9226);const s=r(6928);const o=r(1943);const i=r(6289);const a=r(2759);async function evaluateSecurityAudit({path:e}){return(await n.Result.wrapAsync((async()=>{const t=(0,s.join)(e,i.SECURITY_AUDIT_FILE_NAME);const r=await(0,o.readFile)(t);const n=r.toString("utf-8");return(0,a.evaluateDocument)(n)}))).mapErr((e=>`could not evaluate ${i.SECURITY_AUDIT_FILE_NAME}: ${e}`))}t.evaluateSecurityAudit=evaluateSecurityAudit;function makeSecurityAuditOverview(e){const ratingToEmo=e=>e<33?"đŸŸĨ":e<66?"🟨":"🟩";return`Project security posture overview:\n 🧐 Total topics: ${e.score.totalTopics}\n 🔒 Secured topics: ${e.score.securedTopics}\n đŸ“ĸ Answered topics: ${e.score.answeredTopics}\n ❔ Unknown topics: ${e.score.unknownTopics}\n 📊 Rating: ${ratingToEmo(e.score.rating)} ${e.score.rating}/100`}t.makeSecurityAuditOverview=makeSecurityAuditOverview},6175:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.getGitlabHostUrl=void 0;const n=r(6884);const getGitlabHostUrl=async(e="origin")=>{const t=process.env.CI_SERVER_URL;if(t){return t.replace(/\/+$/,"")}const{gitRemoteHost:r}=await(0,n.getGitRemoteHostAndPath)(e);return`https://${r}`};t.getGitlabHostUrl=getGitlabHostUrl},492:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var n=r(2146);function _interopDefault(e){return e&&e.__esModule?e:{default:e}}var s=_interopDefault(n);const o=/\s*---([^]*?)\n\s*---(\s*(?:\n|$)[^]*)/;const i=`---\n"package-name": patch\n---`;const a=["major","minor","patch","none"];function truncate(e,t=200){return e.length>t?e.slice(0,t)+"...":e}function validateReleases(e,t){for(const r of e){if(typeof r.name!=="string"||r.name.trim()===""){throw new Error(`could not parse changeset - invalid package name in frontmatter.\n`+`Expected a non-empty string for package name, but got: ${JSON.stringify(r.name)}\n`+`Changeset contents:\n${truncate(t)}`)}if(typeof r.type!=="string"){throw new Error(`could not parse changeset - invalid release type for package "${r.name}".\n`+`Expected a string for release type, but got: ${typeof r.type}\n`+`Changeset contents:\n${truncate(t)}`)}if(!a.includes(r.type)){throw new Error(`could not parse changeset - invalid version type ${JSON.stringify(r.type)} for package "${r.name}".\n`+`Valid version types are: ${a.join(", ")}\n`+`Changeset contents:\n${truncate(t)}`)}}}function parseChangesetFile(e){const t=e.trim();if(!t){throw new Error(`could not parse changeset - file is empty.\n`+`Changesets must have frontmatter with package names and version types.\n`+`Example:\n${i}\n\nYour changeset summary here.`)}const r=o.exec(e);if(!r){throw new Error(`could not parse changeset - missing or invalid frontmatter.\n`+`Changesets must start with frontmatter delimited by "---".\n`+`Example:\n${i}\n\nYour changeset summary here.\n`+`Received content:\n${truncate(t)}`)}let[,n,a]=r;let c=a.trim();let u;let l;try{l=s["default"].load(n)}catch(e){throw new Error(`could not parse changeset - invalid YAML in frontmatter.\n`+`The frontmatter between the "---" delimiters must be valid YAML.\n`+`YAML error: ${e instanceof Error?e.message:String(e)}\n`+`Frontmatter content:\n${n}`)}if(l){if(typeof l!=="object"||Array.isArray(l)){throw new Error(`could not parse changeset - frontmatter must be an object mapping package names to version types.\n`+`Expected format:\n${i}\n`+`Received:\n${n}`)}u=Object.entries(l).map((([e,t])=>({name:e,type:t})))}else{u=[]}validateReleases(u,e);return{releases:u,summary:c}}t["default"]=parseChangesetFile},5182:(e,t,r)=>{"use strict";var n=r(8126);var s=r(6308);var o=r(891);function _interopDefault(e){return e&&e.__esModule?e:{default:e}}var i=_interopDefault(o);function appendFormFromObject(e){const t=new FormData;Object.entries(e).forEach((([e,r])=>{if(!r)return;if(Array.isArray(r))t.append(e,r[0],r[1]);else t.append(e,r)}));return t}function endpoint(e,...t){return t.reduce(((t,r,n)=>t+encodeURIComponent(r)+e[n+1]),e[0])}function parseLinkHeader(e){const t={};const r=/<([^>]+)>; rel="([^"]+)"/g;let n;while(n=r.exec(e)){const[,e,r]=n;t[r]=e}return t}function reformatObjectOptions(e,t,r=false){const n=r?s.decamelizeKeys(e):e;return i.default.stringify({[t]:n},{encode:false}).split("&").reduce(((e,t)=>{const[r,n]=t.split("=");e[r]=n;return e}),{})}function packageResponse(e,t){return t?{data:e.body,status:e.status,headers:e.headers}:e.body}function getStream(e,t){return packageResponse(e,t)}function getSingle(e,t,r){const{status:n,headers:o}=t;let{body:i}=t;if(e)i=s.camelizeKeys(i);return packageResponse({body:i,status:n,headers:o},r)}async function getManyMore(e,t,r,n,i,a){const{sudo:c,showExpanded:u,maxPages:l,pagination:p,page:d,perPage:f,idAfter:h,orderBy:g,sort:m}=i;if(e)n.body=s.camelizeKeys(n?.body);const y=[...a||[],...n.body];const v=l&&f?y.length/+f<l:true;const{next:$=""}=parseLinkHeader(n.headers.link);if(!(d&&(a||[]).length===0)&&$&&v){const n=o.parse($.split("?")[1]);const i={...s.camelizeKeys(n)};const a={...i,maxPages:l,sudo:c,showExpanded:u};const p=await t(r,{searchParams:i,sudo:c});return getManyMore(e,t,r,p,a,y)}if(!u)return y;const b=p==="keyset"?{idAfter:h?+h:null,perPage:f?+f:null,orderBy:g,sort:m}:{total:parseInt(n.headers["x-total"],10),next:parseInt(n.headers["x-next-page"],10)||null,current:parseInt(n.headers["x-page"],10)||1,previous:parseInt(n.headers["x-prev-page"],10)||null,perPage:parseInt(n.headers["x-per-page"],10),totalPages:parseInt(n.headers["x-total-pages"],10)};return{data:y,paginationInfo:b}}function get(){return async(e,t,r)=>{const{asStream:n,sudo:s,showExpanded:o,maxPages:i,...a}=r||{};const c=e.queryTimeout?AbortSignal.timeout(e.queryTimeout):void 0;const u=await e.requester.get(t,{searchParams:a,sudo:s,asStream:n,signal:c});const l=e.camelize||false;if(n)return getStream(u,o);if(!Array.isArray(u.body))return getSingle(l,u,o);const p={sudo:s,showExpanded:o,maxPages:i,...a};return getManyMore(l,((t,r)=>e.requester.get(t,{...r,signal:c})),t,u,p)}}function post(){return async(e,t,{searchParams:r,isForm:n,sudo:o,showExpanded:i,...a}={})=>{const c=n?appendFormFromObject(a):a;const u=await e.requester.post(t,{searchParams:r,body:c,sudo:o,signal:e.queryTimeout?AbortSignal.timeout(e.queryTimeout):void 0});if(e.camelize)u.body=s.camelizeKeys(u.body);return packageResponse(u,i)}}function put(){return async(e,t,{searchParams:r,isForm:n,sudo:o,showExpanded:i,...a}={})=>{const c=n?appendFormFromObject(a):a;const u=await e.requester.put(t,{body:c,searchParams:r,sudo:o,signal:e.queryTimeout?AbortSignal.timeout(e.queryTimeout):void 0});if(e.camelize)u.body=s.camelizeKeys(u.body);return packageResponse(u,i)}}function patch(){return async(e,t,{searchParams:r,isForm:n,sudo:o,showExpanded:i,...a}={})=>{const c=n?appendFormFromObject(a):a;const u=await e.requester.patch(t,{body:c,searchParams:r,sudo:o,signal:e.queryTimeout?AbortSignal.timeout(e.queryTimeout):void 0});if(e.camelize)u.body=s.camelizeKeys(u.body);return packageResponse(u,i)}}function del(){return async(e,t,{sudo:r,showExpanded:n,searchParams:s,...o}={})=>{const i=await e.requester.delete(t,{body:o,searchParams:s,sudo:r,signal:e.queryTimeout?AbortSignal.timeout(e.queryTimeout):void 0});return packageResponse(i,n)}}var a={post:post,put:put,patch:patch,get:get,del:del};var c=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/cluster_agents`,t)}allTokens(e,t,r){return a.get()(this,endpoint`projects/${e}/cluster_agents/${t}/tokens`,r)}createToken(e,t,r,n){return a.get()(this,endpoint`projects/${e}/cluster_agents/${t}/tokens`,{name:r,...n})}show(e,t,r){return a.get()(this,endpoint`projects/${e}/cluster_agents/${t}`,r)}showToken(e,t,r,n){return a.get()(this,endpoint`projects/${e}/cluster_agents/${t}/tokens/${r}`,n)}register(e,t,r){return a.post()(this,endpoint`projects/${e}/cluster_agents`,{name:t,...r})}removeToken(e,t,r,n){return a.del()(this,endpoint`projects/${e}/cluster_agents/${t}/tokens/${r}`,n)}unregister(e,t,r){return a.del()(this,endpoint`projects/${e}/cluster_agents/${t}`,r)}};var u=class extends n.BaseResource{allMetricImages(e,t,r){return a.get()(this,endpoint`projects/${e}/alert_management_alerts/${t}/metric_images`,r)}editMetricImage(e,t,r,n){return a.put()(this,endpoint`projects/${e}/alert_management_alerts/${t}/metric_images/${r}`,n)}removeMetricImage(e,t,r,n){return a.del()(this,endpoint`projects/${e}/alert_management_alerts/${t}/metric_images/${r}`,n)}uploadMetricImage(e,t,r,n){return a.post()(this,endpoint`projects/${e}/alert_management_alerts/${t}/metric_images`,{isForm:true,file:[r.content,r.filename],...n})}};var l=class extends n.BaseResource{show(e){return a.get()(this,"application/appearence",e)}edit({logo:e,pwaIcon:t,...r}={}){if(e||t){const n={...r,isForm:true};if(e)n.logo=[e.content,e.filename];if(t)n.pwaIcon=[t.content,t.filename];return a.put()(this,"application/appearence",n)}return a.put()(this,"application/appearence",r)}};var p=class extends n.BaseResource{show(e){return a.get()(this,"application/plan_limits",e)}edit(e,t={}){const{ciPipelineSize:r,ciActiveJobs:n,ciActivePipelines:s,ciProjectSubscriptions:o,ciPipelineSchedules:i,ciNeedsSizeLimit:c,ciRegisteredGroupRunners:u,ciRegisteredProjectRunners:l,conanMaxFileSize:p,genericPackagesMaxFileSize:d,helmMaxFileSize:f,mavenMaxFileSize:h,npmMaxFileSize:g,nugetMaxFileSize:m,pypiMaxFileSize:y,terraformModuleMaxFileSize:v,storageSizeLimit:$,...b}=t;return a.put()(this,"application/plan_limits",{...b,searchParams:{planName:e,ciPipelineSize:r,ciActiveJobs:n,ciActivePipelines:s,ciProjectSubscriptions:o,ciPipelineSchedules:i,ciNeedsSizeLimit:c,ciRegisteredGroupRunners:u,ciRegisteredProjectRunners:l,conanMaxFileSize:p,genericPackagesMaxFileSize:d,helmMaxFileSize:f,mavenMaxFileSize:h,npmMaxFileSize:g,nugetMaxFileSize:m,pypiMaxFileSize:y,terraformModuleMaxFileSize:v,storageSizeLimit:$}})}};var d=class extends n.BaseResource{all(e){return a.get()(this,"applications",e)}create(e,t,r,n){return a.post()(this,"applications",{name:e,redirectUri:t,scopes:r,...n})}remove(e,t){return a.del()(this,`applications/${e}`,t)}};var f=class extends n.BaseResource{show(e){return a.get()(this,"application/settings",e)}edit(e){return a.put()(this,"application/settings",e)}};var h=class extends n.BaseResource{show(e){return a.get()(this,"application/statistics",e)}};function url({projectId:e,groupId:t}={}){let r="";if(e)r=endpoint`projects/${e}/`;else if(t)r=endpoint`groups/${t}/`;return`${r}audit_events`}var g=class extends n.BaseResource{all({projectId:e,groupId:t,...r}={}){const n=url({projectId:e,groupId:t});return a.get()(this,n,r)}show(e,{projectId:t,groupId:r,...n}={}){const s=url({projectId:t,groupId:r});return a.get()(this,`${s}/${e}`,n)}};var m=class extends n.BaseResource{show(e,t){return a.get()(this,"avatar",{email:e,...t})}};var y=class extends n.BaseResource{all(e){return a.get()(this,"broadcast_messages",e)}create(e){return a.post()(this,"broadcast_messages",e)}edit(e,t){return a.put()(this,`broadcast_messages/${e}`,t)}remove(e,t){return a.del()(this,`broadcast_messages/${e}`,t)}show(e,t){return a.get()(this,`broadcast_messages/${e}`,t)}};var v=class extends n.BaseResource{createAccessToken(e){return a.post()(this,"code_suggestions/tokens",e)}generateCompletion(e){return a.post()(this,"code_suggestions/completions",e)}};var $=class extends n.BaseResource{create(e,t){return a.post()(this,endpoint`projects/${e}/packages/composer`,t)}download(e,t,r,n){return a.get()(this,endpoint`projects/${e}/packages/composer/archives/${t}`,{searchParams:{sha:r},...n})}showMetadata(e,t,r){let n;if(r&&r.sha){n=endpoint`groups/${e}/-/packages/composer/${t}$${r.sha}`}else{n=endpoint`groups/${e}/-/packages/composer/p2/${t}`}return a.get()(this,n,r)}showPackages(e,t,r){return a.get()(this,endpoint`groups/${e}/-/packages/composer/p/${t}`,r)}showBaseRepository(e,t){const r={...this};if(t&&t.composerVersion==="2"){r.headers["User-Agent"]="Composer/2"}return a.get()(r,endpoint`groups/${e}/-/packages/composer/packages`,t)}};function url2(e){return e?endpoint`projects/${e}/packages/conan/v1`:"packages/conan/v1"}var b=class extends n.BaseResource{authenticate({projectId:e,...t}={}){return a.get()(this,`${url2(e)}/users/authenticate`,t)}checkCredentials({projectId:e,...t}={}){const r=url2(e);return a.get()(this,`${r}/users/check_credentials`,t)}downloadPackageFile(e,t,r,n,s,o,i,c,{projectId:u,...l}={}){const p=url2(u);return a.get()(this,`${p}/conans/${e}/${t}/${r}/${n}/${o}/package/${s}/${i}/${c}`,l)}downloadRecipeFile(e,t,r,n,s,o,{projectId:i,...c}={}){const u=url2(i);return a.get()(this,`${u}/conans/${e}/${t}/${r}/${n}/${s}/export/${o}`,c)}showPackageUploadUrls(e,t,r,n,s,{projectId:o,...i}={}){const c=url2(o);return a.get()(this,`${c}/conans/${e}/${t}/${r}/${n}/packages/${s}/upload_urls`,i)}showPackageDownloadUrls(e,t,r,n,s,{projectId:o,...i}={}){const c=url2(o);return a.get()(this,`${c}/conans/${e}/${t}/${r}/${n}/packages/${s}/download_urls`,i)}showPackageManifest(e,t,r,n,s,{projectId:o,...i}={}){const c=url2(o);return a.get()(this,`${c}/conans/${e}/${t}/${r}/${n}/packages/${s}/digest`,i)}showPackageSnapshot(e,t,r,n,s,{projectId:o,...i}={}){const c=url2(o);return a.get()(this,`${c}/conans/${e}/${t}/${r}/${n}/packages/${s}`,i)}ping({projectId:e,...t}={}){return a.post()(this,`${url2(e)}/ping`,t)}showRecipeUploadUrls(e,t,r,n,{projectId:s,...o}={}){const i=url2(s);return a.get()(this,`${i}/conans/${e}/${t}/${r}/${n}/upload_urls`,o)}showRecipeDownloadUrls(e,t,r,n,{projectId:s,...o}={}){const i=url2(s);return a.get()(this,`${i}/conans/${e}/${t}/${r}/${n}/download_urls`,o)}showRecipeManifest(e,t,r,n,{projectId:s,...o}={}){const i=url2(s);return a.get()(this,`${i}/conans/${e}/${t}/${r}/${n}/digest`,o)}showRecipeSnapshot(e,t,r,n,{projectId:s,...o}={}){const i=url2(s);return a.get()(this,`${i}/conans/${e}/${t}/${r}/${n}`,o)}removePackageFile(e,t,r,n,{projectId:s,...o}={}){const i=url2(s);return a.get()(this,`${i}/conans/${e}/${t}/${r}/${n}`,o)}search({projectId:e,...t}={}){const r=url2(e);return a.get()(this,`${r}/conans/search`,t)}uploadPackageFile(e,t,r,n,s,o,i,c,u){const l=url2();return a.get()(this,`${l}/files/${t}/${r}/${n}/${s}/${i}/package/${o}/${c}/${e.filename}`,{isForm:true,...u,file:[e.content,e.filename]})}uploadRecipeFile(e,t,r,n,s,o,i){const c=url2();return a.get()(this,`${c}/files/${t}/${r}/${n}/${s}/${o}/export/${e.filename}`,{isForm:true,...i,file:[e.content,e.filename]})}};var w=class extends n.BaseResource{create(e,t,r,{environmentId:n,clusterId:s,...o}={}){let i;if(n)i=endpoint`environments/${n}/metrics_dashboard/annotations`;else if(s)i=endpoint`clusters/${s}/metrics_dashboard/annotations`;else throw new Error("Missing required argument. Please supply a environmentId or a cluserId in the options parameter.");return a.post()(this,i,{dashboardPath:e,startingAt:t,description:r,...o})}};function url3({projectId:e,groupId:t}={}){if(e)return endpoint`/projects/${e}/packages/debian`;if(t)return endpoint`/groups/${t}/-/packages/debian`;throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter")}var _=class extends n.BaseResource{downloadBinaryFileIndex(e,t,r,{projectId:n,groupId:s,...o}){const i=url3({projectId:n,groupId:s});return a.get()(this,`${i}/dists/${e}/${t}/binary-${r}/Packages`,o)}downloadDistributionReleaseFile(e,{projectId:t,groupId:r,...n}){const s=url3({projectId:t,groupId:r});return a.get()(this,`${s}/dists/${e}/Release`,n)}downloadSignedDistributionReleaseFile(e,{projectId:t,groupId:r,...n}){const s=url3({projectId:t,groupId:r});return a.get()(this,`${s}/dists/${e}/InRelease`,n)}downloadReleaseFileSignature(e,{projectId:t,groupId:r,...n}){const s=url3({projectId:t,groupId:r});return a.get()(this,`${s}/dists/${e}/Release.gpg`,n)}downloadPackageFile(e,t,r,n,s,o,i){return a.get()(this,endpoint`projects/${e}/packages/debian/pool/${t}/${r}/${n}/${s}/${o}`,i)}uploadPackageFile(e,t,r){return a.put()(this,endpoint`projects/${e}/packages/debian/${t.filename}`,{isForm:true,...r,file:[t.content,t.filename]})}};var S=class extends n.BaseResource{remove(e,t){return a.post()(this,`groups/${e}/dependency_proxy/cache`,t)}};var A=class extends n.BaseResource{all({projectId:e,userId:t,...r}={}){let n;if(e){n=endpoint`projects/${e}/deploy_keys`}else if(t){n=endpoint`users/${t}/project_deploy_keys`}else{n="deploy_keys"}return a.get()(this,n,r)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/deploy_keys`,{title:t,key:r,...n})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/deploy_keys/${t}`,r)}enable(e,t,r){return a.post()(this,endpoint`projects/${e}/deploy_keys/${t}/enable`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/deploy_keys/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/deploy_keys/${t}`,r)}};var j=class extends n.BaseResource{all({projectId:e,groupId:t,...r}={}){let n;if(e)n=endpoint`projects/${e}/deploy_tokens`;else if(t)n=endpoint`groups/${t}/deploy_tokens`;else n="deploy_tokens";return a.get()(this,n,r)}create(e,t,{projectId:r,groupId:n,...s}={}){let o;if(r)o=endpoint`projects/${r}/deploy_tokens`;else if(n)o=endpoint`groups/${n}/deploy_tokens`;else{throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter.")}return a.post()(this,o,{name:e,scopes:t,...s})}remove(e,{projectId:t,groupId:r,...n}={}){let s;if(t)s=endpoint`projects/${t}/deploy_tokens/${e}`;else if(r)s=endpoint`groups/${r}/deploy_tokens/${e}`;else{throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter.")}return a.del()(this,s,n)}show(e,{projectId:t,groupId:r,...n}={}){let s;if(t)s=endpoint`projects/${t}/deploy_tokens/${e}`;else if(r)s=endpoint`groups/${r}/deploy_tokens/${e}`;else{throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter.")}return a.get()(this,s,n)}};var R=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/access_requests`,t)}request(e,t){return a.post()(this,endpoint`${e}/access_requests`,t)}approve(e,t,r){return a.post()(this,endpoint`${e}/access_requests/${t}/approve`,r)}deny(e,t,r){return a.del()(this,endpoint`${e}/access_requests/${t}`,r)}};var x=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/access_tokens`,t)}create(e,t,r,n){return a.post()(this,endpoint`${e}/access_tokens`,{name:t,scopes:r,...n})}revoke(e,t,r){return a.del()(this,endpoint`${e}/access_tokens/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`${e}/access_tokens/${t}`,r)}};function url4(e,t,r,n){const[s,o]=[e,r].map(encodeURIComponent);const i=[s,t,o];i.push("award_emoji");if(n)i.push(n);return i.join("/")}var k=class extends n.BaseResource{resourceType2;constructor(e,t,r){super({prefixUrl:e,...r});this.resourceType2=t}all(e,t,r){return a.get()(this,url4(e,this.resourceType2,t),r)}award(e,t,r,n){return a.post()(this,url4(e,this.resourceType2,t),{name:r,...n})}remove(e,t,r,n){return a.del()(this,url4(e,this.resourceType2,t,r),n)}show(e,t,r,n){return a.get()(this,url4(e,this.resourceType2,t,r),n)}};function url5(e,t,r,n,s){const[o,i]=[e,r].map(encodeURIComponent);const a=[o,t,i];a.push("notes");a.push(n);a.push("award_emoji");if(s)a.push(s);return a.join("/")}var I=class extends n.BaseResource{resourceType;constructor(e,t){super({prefixUrl:"projects",...t});this.resourceType=e}all(e,t,r,n){return a.get()(this,url5(e,this.resourceType,t,r),n)}award(e,t,r,n,s){return a.post()(this,url5(e,this.resourceType,t,r),{name:n,...s})}remove(e,t,r,n,s){return a.del()(this,url5(e,this.resourceType,t,r,n),s)}show(e,t,r,n,s){return a.get()(this,url5(e,this.resourceType,t,r,n),s)}};var P=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}add(e,t,r,n){return a.post()(this,endpoint`${e}/badges`,{linkUrl:t,imageUrl:r,...n})}all(e,t){return a.get()(this,endpoint`${e}/badges`,t)}edit(e,t,r){return a.put()(this,endpoint`${e}/badges/${t}`,r)}preview(e,t,r,n){return a.get()(this,endpoint`${e}/badges/render`,{linkUrl:t,imageUrl:r,...n})}remove(e,t,r){return a.del()(this,endpoint`${e}/badges/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`${e}/badges/${t}`,r)}};var C=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/custom_attributes`,t)}remove(e,t,r){return a.del()(this,endpoint`${e}/custom_attributes/${t}`,r)}set(e,t,r,n){return a.put()(this,endpoint`${e}/custom_attributes/${t}`,{value:r,...n})}show(e,t,r){return a.get()(this,endpoint`${e}/custom_attributes/${t}`,r)}};var T=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t,r){return a.get()(this,endpoint`${e}/dora/metrics`,{metric:t,...r})}};var O=class extends n.BaseResource{resource2Type;constructor(e,t,r){super({prefixUrl:e,...r});this.resource2Type=t}addNote(e,t,r,n,s,o){return a.post()(this,endpoint`${e}/${this.resource2Type}/${t}/discussions/${r}/notes`,{...o,body:s,noteId:n})}all(e,t,r){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/discussions`,r)}create(e,t,r,{position:n,...s}={}){const o={...s,body:r};if(n){Object.assign(o,reformatObjectOptions(n,"position",true));o.isForm=true}return a.post()(this,endpoint`${e}/${this.resource2Type}/${t}/discussions`,o)}editNote(e,t,r,n,s){return a.put()(this,endpoint`${e}/${this.resource2Type}/${t}/discussions/${r}/notes/${n}`,s)}removeNote(e,t,r,n,s){return a.del()(this,endpoint`${e}/${this.resource2Type}/${t}/discussions/${r}/notes/${n}`,s)}show(e,t,r,n){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/discussions/${r}`,n)}};var M=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/boards`,t)}allLists(e,t,r){return a.get()(this,endpoint`${e}/boards/${t}/lists`,r)}create(e,t,r){return a.post()(this,endpoint`${e}/boards`,{name:t,...r})}createList(e,t,r){return a.post()(this,endpoint`${e}/boards/${t}/lists`,r)}edit(e,t,r){return a.put()(this,endpoint`${e}/boards/${t}`,r)}editList(e,t,r,n,s){return a.put()(this,endpoint`${e}/boards/${t}/lists/${r}`,{position:n,...s})}remove(e,t,r){return a.del()(this,endpoint`${e}/boards/${t}`,r)}removeList(e,t,r,n){return a.del()(this,endpoint`${e}/boards/${t}/lists/${r}`,n)}show(e,t,r){return a.get()(this,endpoint`${e}/boards/${t}`,r)}showList(e,t,r,n){return a.get()(this,endpoint`${e}/boards/${t}/lists/${r}`,n)}};var N=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/labels`,t)}create(e,t,r,n){return a.post()(this,endpoint`${e}/labels`,{name:t,color:r,...n})}edit(e,t,r){if(!r?.newName&&!r?.color)throw new Error("Missing required argument. Please supply a color or a newName in the options parameter.");return a.put()(this,endpoint`${e}/labels/${t}`,r)}promote(e,t,r){return a.put()(this,endpoint`${e}/labels/${t}/promote`,r)}remove(e,t,r){return a.del()(this,endpoint`${e}/labels/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`${e}/labels/${t}`,r)}subscribe(e,t,r){return a.post()(this,endpoint`${e}/issues/${t}/subscribe`,r)}unsubscribe(e,t,r){return a.post()(this,endpoint`${e}/issues/${t}/unsubscribe`,r)}};var L=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}add(e,t,r,n){return a.post()(this,endpoint`${e}/members`,{userId:String(t),accessLevel:r,...n})}all(e,{includeInherited:t,...r}={}){let n=endpoint`${e}/members`;if(t)n+="/all";return a.get()(this,n,r)}edit(e,t,r,n){return a.put()(this,endpoint`${e}/members/${t}`,{accessLevel:r,...n})}show(e,t,{includeInherited:r,...n}={}){const[s,o]=[e,t].map(encodeURIComponent);const i=[s,"members"];if(r)i.push("all");i.push(o);return a.get()(this,i.join("/"),n)}remove(e,t,r){return a.del()(this,endpoint`${e}/members/${t}`,r)}};var B=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/milestones`,t)}allAssignedIssues(e,t,r){return a.get()(this,endpoint`${e}/milestones/${t}/issues`,r)}allAssignedMergeRequests(e,t,r){return a.get()(this,endpoint`${e}/milestones/${t}/merge_requests`,r)}allBurndownChartEvents(e,t,r){return a.get()(this,endpoint`${e}/milestones/${t}/burndown_events`,r)}create(e,t,r){return a.post()(this,endpoint`${e}/milestones`,{title:t,...r})}edit(e,t,r){return a.put()(this,endpoint`${e}/milestones/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`${e}/milestones/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`${e}/milestones/${t}`,r)}};var D=class extends n.BaseResource{resource2Type;constructor(e,t,r){super({prefixUrl:e,...r});this.resource2Type=t}all(e,t,r){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/notes`,r)}create(e,t,r,n){return a.post()(this,endpoint`${e}/${this.resource2Type}/${t}/notes`,{body:r,...n})}edit(e,t,r,n){return a.put()(this,endpoint`${e}/${this.resource2Type}/${t}/notes/${r}`,n)}remove(e,t,r,n){return a.del()(this,endpoint`${e}/${this.resource2Type}/${t}/notes/${r}`,n)}show(e,t,r,n){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/notes/${r}`,n)}};var U=class extends n.BaseResource{constructor(e,t){super({prefixUrl:["templates",e].join("/"),...t})}all(e){process.emitWarning('This API will be deprecated as of Gitlabs v5 API. Please make the switch to "ProjectTemplates".',"DeprecationWarning");return a.get()(this,"",e)}show(e,t){process.emitWarning('This API will be deprecated as of Gitlabs v5 API. Please make the switch to "ProjectTemplates".',"DeprecationWarning");return a.get()(this,encodeURIComponent(e),t)}};var G=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/variables`,t)}create(e,t,r,n){return a.post()(this,endpoint`${e}/variables`,{key:t,value:r,...n})}edit(e,t,r,n){return a.put()(this,endpoint`${e}/variables/${t}`,{value:r,...n})}show(e,t,r){return a.get()(this,endpoint`${e}/variables/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`${e}/variables/${t}`,r)}};var q=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/wikis`,t)}create(e,t,r,n){return a.post()(this,endpoint`${e}/wikis`,{content:t,title:r,...n})}edit(e,t,r){return a.put()(this,endpoint`${e}/wikis/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`${e}/wikis/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`${e}/wikis/${t}`,r)}uploadAttachment(e,t,r){return a.post()(this,endpoint`${e}/wikis/attachments`,{...r,isForm:true,file:[t.content,t.filename]})}};var H=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}add(e,t,r){return a.post()(this,endpoint`${e}/hooks`,{url:t,...r})}all(e,t){return a.get()(this,endpoint`${e}/hooks`,t)}edit(e,t,r,n){return a.put()(this,endpoint`${e}/hooks/${t}`,{url:r,...n})}remove(e,t,r){return a.del()(this,endpoint`${e}/hooks/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`${e}/hooks/${t}`,r)}};var K=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}create(e,t){return a.post()(this,endpoint`${e}/push_rule`,t)}edit(e,t){return a.put()(this,endpoint`${e}/push_rule`,t)}remove(e,t){return a.del()(this,endpoint`${e}/push_rule`,t)}show(e,t){return a.get()(this,endpoint`${e}/push_rule`,t)}};var Y=class extends n.BaseResource{resourceType;resourceTypeSingular;constructor(e,t){super(t);this.resourceType=e;this.resourceTypeSingular=e.substring(0,e.length-1)}all(e){const t=e?.[`${this.resourceTypeSingular}Id`];const r=t?endpoint`${this.resourceType}/${t}/repository_storage_moves`:`${this.resourceTypeSingular}_repository_storage_moves`;return a.get()(this,r,e)}show(e,t){const r=t?.[`${this.resourceTypeSingular}Id`];const n=r?endpoint`${this.resourceType}/${r}/repository_storage_moves`:`${this.resourceTypeSingular}_repository_storage_moves`;return a.get()(this,`${n}/${e}`,t)}schedule(e,t){const r=t?.[`${this.resourceTypeSingular}Id`];const n=r?endpoint`${this.resourceType}/${r}/repository_storage_moves`:`${this.resourceTypeSingular}_repository_storage_moves`;return a.post()(this,n,{sourceStorageName:e,...t})}};var W=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}add(e,t,r){if(!r?.email&&!r?.userId)throw new Error("Missing required argument. Please supply a email or a userId in the options parameter.");return a.post()(this,endpoint`${e}/invitations`,{accessLevel:t,...r})}all(e,t){return a.get()(this,endpoint`${e}/invitations`,t)}edit(e,t,r){return a.put()(this,endpoint`${e}/invitations/${t}`,r)}remove(e,t,r){return a.put()(this,endpoint`${e}/invitations/${t}`,r)}};var z=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/iterations`,t)}};var V=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,`${e}/protected_environments`,t)}create(e,t,r,n){return a.post()(this,`${e}/protected_environments`,{name:t,deployAccessLevel:r,...n})}edit(e,t,r){return a.put()(this,`${e}/protected_environments/${t}`,r)}show(e,t,r){return a.get()(this,`${e}/protected_environments/${t}`,r)}remove(e,t,r){return a.del()(this,`${e}/protected_environments/${t}`,r)}};var Q=class extends n.BaseResource{resource2Type;constructor(e,t,r){super({prefixUrl:e,...r});this.resource2Type=t}all(e,t,r){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_iteration_events`,r)}show(e,t,r,n){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_iteration_events/${r}`,n)}};var J=class extends n.BaseResource{resource2Type;constructor(e,t,r){super({prefixUrl:e,...r});this.resource2Type=t}all(e,t,r){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_label_events`,r)}show(e,t,r,n){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_label_events/${r}`,n)}};var X=class extends n.BaseResource{resource2Type;constructor(e,t,r){super({prefixUrl:e,...r});this.resource2Type=t}all(e,t,r){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_milestone_events`,r)}show(e,t,r,n){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_milestone_events/${r}`,n)}};var Z=class extends n.BaseResource{resource2Type;constructor(e,t,r){super({prefixUrl:e,...r});this.resource2Type=t}all(e,t,r){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_state_events`,r)}show(e,t,r,n){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_state_events/${r}`,n)}};var ee=class extends U{constructor(e){super("dockerfiles",e)}};var te=class extends n.BaseResource{all({projectId:e,userId:t,...r}={}){let n;if(e)n=endpoint`projects/${e}/events`;else if(t)n=endpoint`users/${t}/events`;else n="events";return a.get()(this,n,r)}};var re=class extends n.BaseResource{all(e){return a.get()(this,"experiments",e)}};var ne=class extends n.BaseResource{all(e){return a.get()(this,"geo_nodes",e)}allStatuses(e){return a.get()(this,"geo_nodes/statuses",e)}allFailures(e){return a.get()(this,"geo_nodes/current/failures",e)}create(e,t,r){return a.post()(this,"geo_nodes",{name:e,url:t,...r})}edit(e,t){return a.put()(this,`geo_nodes/${e}`,t)}repair(e,t){return a.post()(this,`geo_nodes/${e}/repair`,t)}remove(e,t){return a.del()(this,`geo_nodes/${e}`,t)}show(e,t){return a.get()(this,`geo_nodes/${e}`,t)}showStatus(e,t){return a.get()(this,`geo_nodes/${e}/status`,t)}};var se=class extends n.BaseResource{all(e){return a.get()(this,"geo_sites",e)}allStatuses(e){return a.get()(this,"geo_sites/statuses",e)}allFailures(e){return a.get()(this,"geo_sites/current/failures",e)}create(e,t,r){return a.post()(this,"geo_sites",{name:e,url:t,...r})}edit(e,t){return a.put()(this,`geo_sites/${e}`,t)}repair(e,t){return a.post()(this,`geo_sites/${e}/repair`,t)}remove(e,t){return a.del()(this,`geo_sites/${e}`,t)}show(e,t){return a.get()(this,`geo_sites/${e}`,t)}showStatus(e,t){return a.get()(this,`geo_sites/${e}/status`,t)}};var oe=class extends U{constructor(e){super("gitignores",e)}};var ie=class extends U{constructor(e){super("gitlab_ci_ymls",e)}};var ae=class extends n.BaseResource{importGithubRepository(e,t,r,n){return a.post()(this,"import/github",{personalAccessToken:e,repoId:t,targetNamespace:r,...n})}cancelGithubRepositoryImport(e,t){return a.post()(this,"import/github/cancel",{projectId:e,...t})}importGithubGists(e,t){return a.post()(this,"import/github/gists",{personalAccessToken:e,...t})}importBitbucketServerRepository(e,t,r,n,s,o){return a.post()(this,"import/bitbucket_server",{bitbucketServerUrl:e,bitbucketServerUsername:t,personalAccessToken:r,bitbucketServerProject:n,bitbucketServerRepo:s,...o})}};var ce=class extends n.BaseResource{all(e){return a.get()(this,"admin/ci/variables",e)}create(e,t,r){return a.post()(this,"admin/ci/variables",{key:e,value:t,...r})}edit(e,t,r){return a.put()(this,endpoint`admin/ci/variables/${e}`,{value:t,...r})}show(e,t){return a.get()(this,endpoint`admin/ci/variables/${e}`,t)}remove(e,t){return a.get()(this,endpoint`admin/ci/variables/${e}`,t)}};var ue=class extends n.BaseResource{show({keyId:e,fingerprint:t,...r}={}){let n;if(e)n=`keys/${e}`;else if(t)n=`keys?fingerprint=${t}`;else{throw new Error("Missing required argument. Please supply a fingerprint or a keyId in the options parameter")}return a.get()(this,n,r)}};var le=class extends n.BaseResource{add(e,t){return a.post()(this,"license",{searchParams:{license:e},...t})}all(e){return a.get()(this,"licenses",e)}show(e){return a.get()(this,"license",e)}remove(e,t){return a.del()(this,`license/${e}`,t)}recalculateBillableUsers(e,t){return a.put()(this,`license/${e}/refresh_billable_users`,t)}};var pe=class extends U{constructor(e){super("Licenses",e)}};var de=class extends n.BaseResource{check(e,t){return a.get()(this,endpoint`projects/${e}/ci/lint`,t)}lint(e,t,r){return a.post()(this,endpoint`projects/${e}/ci/lint`,{...r,content:t})}};var fe=class extends n.BaseResource{render(e,t){return a.post()(this,"markdown",{text:e,...t})}};var he=class extends n.BaseResource{downloadPackageFile(e,t,{projectId:r,groupId:n,...s}){let o=endpoint`packages/maven/${e}/${t}`;if(r)o=endpoint`projects/${r}/${o}`;else if(n)o=endpoint`groups/${n}/-/${o}`;return a.get()(this,o,s)}uploadPackageFile(e,t,r,n){return a.put()(this,endpoint`projects/${e}/packages/maven/${t}/${r.filename}`,{isForm:true,...n,file:[r.content,r.filename]})}};var ge=class extends n.BaseResource{show(e){return a.get()(this,"metadata",e)}};var me=class extends n.BaseResource{all(e){return a.get()(this,"bulk_imports",e)}create(e,t,r){return a.post()(this,"bulk_imports",{configuration:e,entities:t,...r})}allEntities({bulkImportId:e,...t}={}){const r=e?endpoint`bulk_imports/${e}/entities`:"bulk_imports/entities";return a.get()(this,r,t)}show(e,t){return a.get()(this,`bulk_imports/${e}`,t)}showEntity(e,t,r){return a.get()(this,`bulk_imports/${e}/entities/${t}`,r)}};var ye=class extends n.BaseResource{all(e){return a.get()(this,"namespaces",e)}exists(e,t){return a.get()(this,endpoint`namespaces/${e}/exists`,t)}show(e,t){return a.get()(this,endpoint`namespaces/${e}`,t)}};function url6({projectId:e,groupId:t}={}){let r="";if(e)r=endpoint`projects/${e}/`;if(t)r=endpoint`groups/${t}/`;return`${r}notification_settings`}var ve=class extends n.BaseResource{edit({groupId:e,projectId:t,...r}={}){const n=url6({groupId:e,projectId:t});return a.put()(this,n,r)}show({groupId:e,projectId:t,...r}={}){const n=url6({groupId:e,projectId:t});return a.get()(this,n,r)}};function url7(e){return e?endpoint`/projects/${e}/packages/npm`:"packages/npm"}var $e=class extends n.BaseResource{downloadPackageFile(e,t,r,n){return a.get()(this,endpoint`projects/${e}/packages/npm/${t}/-/${r}`,n)}removeDistTag(e,t,r){const n=url7(r?.projectId);return a.del()(this,`${n}/-/package/${e}/dist-tags/${t}`,r)}setDistTag(e,t,r){const n=url7(r?.projectId);return a.put()(this,`${n}/-/package/${e}/dist-tags/${t}`,r)}showDistTags(e,t){const r=url7(t?.projectId);return a.get()(this,`${r}/-/package/${e}/dist-tags`,t)}showMetadata(e,t){const r=url7(t?.projectId);return a.get()(this,`${r}/${e}`,t)}uploadPackageFile(e,t,r,n,s){return a.put()(this,endpoint`projects/${e}/packages/npm/${t}`,{...s,versions:r,...n})}};function url8({projectId:e,groupId:t}={}){if(e)return endpoint`/projects/${e}/packages/nuget`;if(t)return endpoint`/groups/${t}/-/packages/nuget`;throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter")}var be=class extends n.BaseResource{downloadPackageFile(e,t,r,n,s){return a.get()(this,endpoint`projects/${e}/packages/nuget/download/${t}/${r}/${n}`,s)}search(e,{projectId:t,groupId:r,...n}){const s=url8({projectId:t,groupId:r});return a.get()(this,`${s}/query`,{q:e,...n})}showMetadata(e,{projectId:t,groupId:r,...n}){const s=url8({projectId:t,groupId:r});return a.get()(this,`${s}/metadata/${e}/index`,n)}showPackageIndex(e,t,r){return a.get()(this,endpoint`projects/${e}/packages/nuget/download/${t}/index`,r)}showServiceIndex({projectId:e,groupId:t,...r}){const n=url8({projectId:e,groupId:t});return a.get()(this,`${n}/index`,r)}showVersionMetadata(e,t,{projectId:r,groupId:n,...s}){const o=url8({projectId:r,groupId:n});return a.get()(this,`${o}/metadata/${e}/${t}`,s)}uploadPackageFile(e,t,r,n,s){return a.put()(this,endpoint`projects/${e}/packages/nuget`,{isForm:true,...s,packageName:t,packageVersion:r,file:[n.content,n.filename]})}uploadSymbolPackage(e,t,r,n,s){return a.put()(this,endpoint`projects/${e}/packages/nuget/symbolpackage`,{isForm:true,...s,packageName:t,packageVersion:r,file:[n.content,n.filename]})}};var we=class extends n.BaseResource{all(e){return a.get()(this,"personal_access_tokens",e)}create(e,t,r,n){return a.post()(this,endpoint`users/${e}/personal_access_tokens`,{name:t,scopes:r,...n})}remove({tokenId:e,...t}={}){const r=e?endpoint`personal_access_tokens/${e}`:"personal_access_tokens/self";return a.del()(this,r,t)}rotate(e,t){return a.post()(this,endpoint`personal_access_tokens/${e}/rotate`,t)}show({tokenId:e,...t}={}){const r=e?endpoint`personal_access_tokens/${e}`:"personal_access_tokens/self";return a.get()(this,r,t)}};var _e=class extends n.BaseResource{downloadPackageFile(e,t,{projectId:r,groupId:n,...s}={}){let o;if(r){o=endpoint`projects/${r}/packages/pypi/files/${e}/${t}`}else if(n){o=endpoint`groups/${n}/packages/pypi/files/${e}/${t}`}else{throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter")}return a.get()(this,o,s)}showPackageDescriptor(e,{projectId:t,groupId:r,...n}){let s;if(t){s=endpoint`projects/${t}/packages/pypi/simple/${e}`}else if(r){s=endpoint`groups/${r}/packages/pypi/simple/${e}`}else{throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter")}return a.get()(this,s,n)}uploadPackageFile(e,t,r){return a.put()(this,endpoint`projects/${e}/packages/pypi`,{...r,isForm:true,file:[t.content,t.filename]})}};var Ee=class extends n.BaseResource{allDependencies(e,t){return a.get()(this,endpoint`projects/${e}/packages/rubygems/api/v1/dependencies`,t)}downloadGemFile(e,t,r){return a.get()(this,endpoint`projects/${e}/packages/rubygems/gems/${t}`,r)}uploadGemFile(e,t,r){return a.post()(this,`projects/${e}/packages/rubygems/api/v1/gems`,{isForm:true,...r,file:[t.content,t.filename]})}};var Se=class extends n.BaseResource{all(e,t,r){const{projectId:n,groupId:s,...o}=r||{};let i;if(n)i=endpoint`projects/${n}/`;else if(s)i=endpoint`groups/${s}/`;else i="";return a.get()(this,`${i}search`,{scope:e,search:t,...o})}};var Ae=class extends n.BaseResource{all(e){return a.get()(this,"admin/search/migrations",e)}show(e,t){return a.get()(this,endpoint`admin/search/migrations/${e}`,t)}};var je=class extends n.BaseResource{create(e){return a.post()(this,endpoint`service_accounts`,e)}};var Re=class extends n.BaseResource{showMetricDefinitions(e){return a.get()(this,"usage_data/metric_definitions",e)}showServicePingSQLQueries(e){return a.get()(this,"usage_data/queries",e)}showUsageDataNonSQLMetrics(e){return a.get()(this,"usage_data/non_sql_metrics",e)}};var xe=class extends n.BaseResource{queueMetrics(){return a.get()(this,"sidekiq/queue_metrics")}processMetrics(){return a.get()(this,"sidekiq/process_metrics")}jobStats(){return a.get()(this,"sidekiq/job_stats")}compoundMetrics(){return a.get()(this,"sidekiq/compound_metrics")}};var ke=class extends n.BaseResource{remove(e,t){return a.get()(this,endpoint`admin/sidekiq/queues/${e}`,t)}};var Ie=class extends Y{constructor(e){super("snippets",e)}};var Pe=class extends n.BaseResource{all({public:e,...t}={}){const r=e?"snippets/public":"snippets";return a.get()(this,r,t)}create(e,t){return a.post()(this,"snippets",{title:e,...t})}edit(e,t){return a.put()(this,`snippets/${e}`,t)}remove(e,t){return a.del()(this,`snippets/${e}`,t)}show(e,t){return a.get()(this,`snippets/${e}`,t)}showContent(e,t){return a.get()(this,`snippets/${e}/raw`,t)}showRepositoryFileContent(e,t,r,n){return a.get()(this,endpoint`snippets/${e}/files/${t}/${r}/raw`,n)}showUserAgentDetails(e,t){return a.get()(this,`snippets/${e}/user_agent_detail`,t)}};var Ce=class extends n.BaseResource{edit(e,t){return a.put()(this,`suggestions/${e}/apply`,t)}editBatch(e,t){return a.put()(this,`suggestions/batch_apply`,{...t,ids:e})}};var Te=class extends n.BaseResource{all(e){return a.get()(this,"hooks",e)}add(e,t){return this.create(e,t)}create(e,t){return a.post()(this,"hooks",{url:e,...t})}test(e,t){return a.post()(this,`hooks/${e}`,t)}remove(e,t){return a.del()(this,`hooks/${e}`,t)}show(e,t){return a.post()(this,`hooks/${e}`,t)}};var Oe=class extends n.BaseResource{all(e){return a.get()(this,"todos",e)}done({todoId:e,...t}={}){let r="todos";if(e)r+=`/${e}`;return a.post()(this,`${r}/mark_as_done`,t)}};var Me=class extends n.BaseResource{all(e){return a.get()(this,"topics",e)}create(e,{avatar:t,...r}={}){const n={name:e,...r};if(t){n.isForm=true;n.file=[t.content,t.filename]}return a.post()(this,"topics",n)}edit(e,{avatar:t,...r}={}){const n={...r};if(t){n.isForm=true;n.file=[t.content,t.filename]}return a.put()(this,`topics/${e}`,n)}merge(e,t,r){return a.post()(this,`topics/merge`,{sourceTopicId:e,targetTopicId:t,...r})}remove(e,t){return a.del()(this,`topics/${e}`,t)}show(e,t){return a.get()(this,`topics/${e}`,t)}};var Ne=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/repository/branches`,t)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/repository/branches`,{branch:t,ref:r,...n})}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/repository/branches/${t}`,r)}removeMerged(e,t){return a.del()(this,endpoint`projects/${e}/repository/merged_branches`,t)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/branches/${t}`,r)}};var Le=class extends O{constructor(e){super("projects","repository/commits",e)}};var Fe=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/repository/commits`,t)}allComments(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}/comments`,r)}allDiscussions(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}/discussions`,r)}allMergeRequests(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}/merge_requests`,r)}allReferences(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}/refs`,r)}allStatuses(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}/statuses`,r)}cherryPick(e,t,r,n){return a.post()(this,endpoint`projects/${e}/repository/commits/${t}/cherry_pick`,{branch:r,...n})}create(e,t,r,n=[],s={}){return a.post()(this,endpoint`projects/${e}/repository/commits`,{branch:t,commitMessage:r,actions:n,...s})}createComment(e,t,r,n){return a.post()(this,endpoint`projects/${e}/repository/commits/${t}/comments`,{note:r,...n})}editStatus(e,t,r,n){return a.post()(this,endpoint`projects/${e}/statuses/${t}`,{state:r,...n})}revert(e,t,r,n){return a.post()(this,endpoint`projects/${e}/repository/commits/${t}/revert`,{...n,branch:r})}show(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}`,r)}showDiff(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}/diff`,r)}showGPGSignature(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}/signature`,r)}};var Be=class extends n.BaseResource{allRepositories({groupId:e,projectId:t,...r}={}){let n;if(e)n=endpoint`groups/${e}/registry/repositories`;else if(t)n=endpoint`projects/${t}/registry/repositories`;else throw new Error("Missing required argument. Please supply a groupId or a projectId in the options parameter.");return a.get()(this,n,r)}allTags(e,t,r){return a.get()(this,endpoint`projects/${e}/registry/repositories/${t}/tags`,r)}editRegistryVisibility(e,t){return a.get()(this,endpoint`projects/${e}`,t)}removeRepository(e,t,r){return a.del()(this,endpoint`projects/${e}/registry/repositories/${t}`,r)}removeTag(e,t,r,n){return a.del()(this,endpoint`projects/${e}/registry/repositories/${t}/tags/${r}`,n)}removeTags(e,t,r,n){return a.del()(this,endpoint`projects/${e}/registry/repositories/${t}/tags`,{nameRegexDelete:r,...n})}showRepository(e,t){return a.get()(this,endpoint`registry/repositories/${e}`,t)}showTag(e,t,r,n){return a.get()(this,endpoint`projects/${e}/registry/repositories/${t}/tags/${r}`,n)}};var De=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/deployments`,t)}allMergeRequests(e,t,r){return a.get()(this,endpoint`projects/${e}/deployments/${t}/merge_requests`,r)}create(e,t,r,n,s,o){return a.post()(this,endpoint`projects/${e}/deployments`,{environment:t,sha:r,ref:n,tag:s,...o})}edit(e,t,r,n){return a.put()(this,endpoint`projects/${e}/deployments/${t}`,{...n,status:r})}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/deployments/${t}`,r)}setApproval(e,t,r,n){return a.post()(this,endpoint`projects/${e}/deployments/${t}/approval`,{...n,status:r})}show(e,t,r){return a.get()(this,endpoint`projects/${e}/deployments/${t}`,r)}};var Ue=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/environments`,t)}create(e,t,r){return a.post()(this,endpoint`projects/${e}/environments`,{name:t,...r})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/environments/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/environments/${t}`,r)}removeReviewApps(e,t){return a.del()(this,endpoint`projects/${e}/environments/review_apps`,t)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/environments/${t}`,r)}stop(e,t,r){return a.post()(this,endpoint`projects/${e}/environments/${t}/stop`,r)}stopStale(e,t,r){return a.post()(this,endpoint`projects/${e}/environments/stop_stale`,{searchParams:{before:t},...r})}};var Ge=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/error_tracking/client_keys`,t)}create(e,t){return a.post()(this,endpoint`projects/${e}/error_tracking/client_keys`,t)}remove(e,t){return a.del()(this,endpoint`projects/${e}/error_tracking/client_keys`,t)}};var qe=class extends n.BaseResource{create(e,t,r,n){return a.put()(this,endpoint`projects/${e}/error_tracking/settings`,{searchParams:{active:t,integrated:r},...n})}edit(e,t,{integrated:r,...n}={}){return a.patch()(this,endpoint`projects/${e}/error_tracking/settings`,{searchParams:{active:t,integrated:r},...n})}show(e,t){return a.get()(this,endpoint`projects/${e}/error_tracking/settings`,t)}};var He=class extends n.BaseResource{all(e,t){const{mergerequestIId:r,...n}=t||{};let s=endpoint`projects/${e}`;if(r){s+=endpoint`/merge_requests/${r}/status_checks`}else{s+="/external_status_checks"}return a.get()(this,s,n)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/external_status_checks`,{name:t,externalUrl:r,...n})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/external_status_checks/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/external_status_checks/${t}`,r)}set(e,t,r,n,s){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/status_check_responses`,{sha:r,externalStatusCheckId:n,...s})}};var Ke=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/feature_flags`,t)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/feature_flags`,{name:t,version:r,...n})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/feature_flags/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/feature_flags/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/feature_flags/${t}`,r)}};var Ye=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/feature_flags_user_lists`,t)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/feature_flags_user_lists`,{name:t,userXids:r,...n})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/feature_flags_user_lists/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/feature_flags_user_lists/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/feature_flags_user_lists/${t}`,r)}};var We=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/freeze_periods`,t)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/freeze_periods`,{freezeStart:t,freezeEnd:r,...n})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/freeze_periods/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/freeze_periods/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/freeze_periods/${t}`,r)}};var ze=class extends n.BaseResource{remove(e,t){return a.del()(this,endpoint`projects/${e}/pages`,t)}};var Ve=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`projects/${e}/packages/go/${t}/@v/list`,r)}showVersionMetadata(e,t,r,n){return a.get()(this,endpoint`projects/${e}/packages/go/${t}/@v/${r}.info`,n)}downloadModuleFile(e,t,r,n){return a.get()(this,endpoint`projects/${e}/packages/go/${t}/@v/${r}.mod`,n)}downloadModuleSource(e,t,r,n){return a.get()(this,endpoint`projects/${e}/packages/go/${t}/@v/${r}.zip`,n)}};var Qe=class extends n.BaseResource{downloadChartIndex(e,t,r){return a.get()(this,endpoint`projects/${e}/packages/helm/${t}/index.yaml`,r)}downloadChart(e,t,r,n){return a.get()(this,endpoint`projects/${e}/packages/helm/${t}/charts/${r}.tgz`,n)}import(e,t,r,n){return a.post()(this,endpoint`projects/${e}/packages/helm/api/${t}/charts`,{isForm:true,...n,chart:[r.content,r.filename]})}};var Je=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/integrations`,t)}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/integrations/${t}`,r)}disable(e,t,r){return a.del()(this,endpoint`projects/${e}/integrations/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/integrations/${t}`,r)}};var Xe=class extends k{constructor(e){super("projects","issues",e)}};var Ze=class extends O{constructor(e){super("projects","issues",e)}};var et=class extends Q{constructor(e){super("projects","issues",e)}};var tt=class extends J{constructor(e){super("projects","issues",e)}};var rt=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`projects/${e}/issues/${t}/links`,r)}create(e,t,r,n,s){return a.post()(this,endpoint`projects/${e}/issues/${t}/links`,{targetProjectId:r,targetIssueIid:n,...s})}remove(e,t,r,n){return a.del()(this,endpoint`projects/${e}/issues/${t}/links/${r}`,n)}};var nt=class extends X{constructor(e){super("projects","issues",e)}};var st=class extends I{constructor(e){super("issues",e)}};var ot=class extends D{constructor(e){super("projects","issues",e)}};var it=class extends n.BaseResource{addSpentTime(e,t,r,n){return a.post()(this,endpoint`projects/${e}/issues/${t}/add_spent_time`,{duration:r,...n})}addTimeEstimate(e,t,r,n){return a.post()(this,endpoint`projects/${e}/issues/${t}/time_estimate`,{duration:r,...n})}all({projectId:e,groupId:t,...r}={}){let n;if(e)n=endpoint`projects/${e}/issues`;else if(t)n=endpoint`groups/${t}/issues`;else n="issues";return a.get()(this,n,r)}allMetricImages(e,t,r){return a.get()(this,endpoint`projects/${e}/issues/${t}/metric_images`,r)}allParticipants(e,t,r){return a.get()(this,endpoint`projects/${e}/issues/${t}/participants`,r)}allRelatedMergeRequests(e,t,r){return a.get()(this,endpoint`projects/${e}/issues/${t}/related_merge_requests`,r)}create(e,t,r){return a.post()(this,endpoint`projects/${e}/issues`,{...r,title:t})}createTodo(e,t,r){return a.post()(this,endpoint`projects/${e}/issues/${t}/todo`,r)}clone(e,t,r,n){return a.post()(this,endpoint`projects/${e}/issues/${t}/clone`,{toProjectId:r,...n})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/issues/${t}`,r)}editMetricImage(e,t,r,n){return a.put()(this,endpoint`projects/${e}/issues/${t}/metric_images/${r}`,n)}move(e,t,r,n){return a.post()(this,endpoint`projects/${e}/issues/${t}/move`,{toProjectId:r,...n})}promote(e,t,r,n){return a.post()(this,endpoint`projects/${e}/issues/${t}/notes`,{searchParams:{body:`${r} \n /promote`},...n})}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/issues/${t}`,r)}removeMetricImage(e,t,r,n){return a.del()(this,endpoint`projects/${e}/issues/${t}/metric_images/${r}`,n)}reorder(e,t,r){return a.put()(this,endpoint`projects/${e}/issues/${t}/reorder`,r)}resetSpentTime(e,t,r){return a.post()(this,endpoint`projects/${e}/issues/${t}/reset_spent_time`,r)}resetTimeEstimate(e,t,r){return a.post()(this,endpoint`projects/${e}/issues/${t}/reset_time_estimate`,r)}show(e,{projectId:t,...r}={}){const n=t?endpoint`projects/${t}/issues/${e}`:`issues/${e}`;return a.get()(this,n,r)}subscribe(e,t,r){return a.post()(this,endpoint`projects/${e}/issues/${t}/subscribe`,r)}allClosedByMergeRequestst(e,t,r){return a.get()(this,endpoint`projects/${e}/issues/${t}/closed_by`,r)}showTimeStats(e,t,r){return a.get()(this,endpoint`projects/${e}/issues/${t}/time_stats`,r)}unsubscribe(e,t,r){return a.post()(this,endpoint`projects/${e}/issues/${t}/unsubscribe`,r)}uploadMetricImage(e,t,r,n){return a.post()(this,endpoint`projects/${e}/issues/${t}/metric_images`,{isForm:true,...n,file:[r.content,r.filename]})}showUserAgentDetails(e,t,r){return a.get()(this,endpoint`projects/${e}/issues/${t}/user_agent_details`,r)}};var at=class extends n.BaseResource{all({projectId:e,groupId:t,...r}={}){let n;if(e)n=endpoint`projects/${e}/issues_statistics`;else if(t)n=endpoint`groups/${t}/issues_statistics`;else n="issues_statistics";return a.get()(this,n,r)}};var ct=class extends Z{constructor(e){super("projects","issues",e)}};var ut=class extends Z{constructor(e){super("projects","issues",e)}};function generateDownloadPathForJob(e,t,r){let n=endpoint`projects/${e}/jobs/${t}/artifacts`;if(r)n+=`/${r}`;return n}function generateDownloadPath(e,t,r){let n=endpoint`projects/${e}/jobs/artifacts/${t}`;if(r){n+=endpoint`/raw/${r}`}else{n+=endpoint`/download`}return n}var lt=class extends n.BaseResource{downloadArchive(e,{jobId:t,artifactPath:r,ref:n,...s}={}){let o;if(t)o=generateDownloadPathForJob(e,t,r);else if(s?.job&&n)o=generateDownloadPath(e,n,r);else throw new Error("Missing one of the required parameters. See typing documentation for available arguments.");return a.get()(this,o,s)}keep(e,t,r){return a.post()(this,endpoint`projects/${e}/jobs/${t}/artifacts/keep`,r)}remove(e,{jobId:t,...r}={}){let n;if(t){n=endpoint`projects/${e}/jobs/${t}/artifacts`}else{n=endpoint`projects/${e}/artifacts`}return a.del()(this,n,r)}};var pt=class extends n.BaseResource{all(e,{pipelineId:t,...r}={}){const n=t?endpoint`projects/${e}/pipelines/${t}/jobs`:endpoint`projects/${e}/jobs`;return a.get()(this,n,r)}allPipelineBridges(e,t,r){return a.get()(this,endpoint`projects/${e}/pipelines/${t}/bridges`,r)}cancel(e,t,r){return a.post()(this,endpoint`projects/${e}/jobs/${t}/cancel`,r)}erase(e,t,r){return a.post()(this,endpoint`projects/${e}/jobs/${t}/erase`,r)}play(e,t,r){return a.post()(this,endpoint`projects/${e}/jobs/${t}/play`,r)}retry(e,t,r){return a.post()(this,endpoint`projects/${e}/jobs/${t}/retry`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/jobs/${t}`,r)}showConnectedJob(e){if(!this.headers["job-token"])throw new Error('Missing required header "job-token"');return a.get()(this,"job",e)}showConnectedJobK8Agents(e){if(!this.headers["job-token"])throw new Error('Missing required header "job-token"');return a.get()(this,"job/allowed_agents",e)}showLog(e,t,r){return a.get()(this,endpoint`projects/${e}/jobs/${t}/trace`,r)}};var dt=class extends n.BaseResource{allApprovalRules(e,{mergerequestIId:t,...r}={}){let n;if(t){n=endpoint`projects/${e}/merge_requests/${t}/approval_rules`}else{n=endpoint`projects/${e}/approval_rules`}return a.get()(this,n,r)}approve(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/approve`,r)}createApprovalRule(e,t,r,{mergerequestIId:n,...s}={}){let o;if(n){o=endpoint`projects/${e}/merge_requests/${n}/approval_rules`}else{o=endpoint`projects/${e}/approval_rules`}return a.post()(this,o,{name:t,approvalsRequired:r,...s})}editApprovalRule(e,t,r,n,{mergerequestIId:s,...o}={}){let i;if(s){i=endpoint`projects/${e}/merge_requests/${s}/approval_rules/${t}`}else{i=endpoint`projects/${e}/approval_rules/${t}`}return a.put()(this,i,{name:r,approvalsRequired:n,...o})}editConfiguration(e,t){return a.post()(this,endpoint`projects/${e}/approvals`,t)}removeApprovalRule(e,t,{mergerequestIId:r,...n}={}){let s;if(r){s=endpoint`projects/${e}/merge_requests/${r}/approval_rules/${t}`}else{s=endpoint`projects/${e}/approval_rules/${t}`}return a.del()(this,s,n)}showApprovalRule(e,t,r){return a.get()(this,endpoint`projects/${e}/approval_rules/${t}`,r)}showApprovalState(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/approval_state`,r)}showConfiguration(e,{mergerequestIId:t,...r}={}){let n;if(t){n=endpoint`projects/${e}/merge_requests/${t}/approvals`}else{n=endpoint`projects/${e}/approvals`}return a.get()(this,n,r)}unapprove(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/unapprove`,r)}};var ft=class extends k{constructor(e){super("projects","merge_requests",e)}};var ht=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/context_commits`,r)}create(e,t,{mergerequestIId:r,...n}={}){const s=endpoint`projects/${e}/merge_requests`;const o=r?`${s}/${r}/context_commits`:s;return a.post()(this,o,{commits:t,...n})}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/merge_requests/${t}/context_commits`,r)}};var gt=class extends O{constructor(e){super("projects","merge_requests",e)}resolve(e,t,r,n,s){return a.put()(this,endpoint`${e}/merge_requests/${t}/discussions/${r}`,{searchParams:{resolved:n},...s})}};var mt=class extends J{constructor(e){super("projects","merge_requests",e)}};var yt=class extends X{constructor(e){super("projects","merge_requests",e)}};var vt=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/draft_notes`,r)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/draft_notes`,{...n,note:r})}edit(e,t,r,n){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/draft_notes/${r}`,n)}publish(e,t,r,n){return a.put()(this,endpoint`projects/${e}/merge_requests/${t}/draft_notes/${r}/publish`,n)}publishBulk(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/draft_notes/bulk_publish`,r)}remove(e,t,r,n){return a.del()(this,endpoint`projects/${e}/merge_requests/${t}/draft_notes/${r}`,n)}show(e,t,r,n){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/draft_notes/${r}`,n)}};var $t=class extends D{constructor(e){super("projects","merge_requests",e)}};var bt=class extends I{constructor(e){super("merge_requests",e)}};var wt=class extends n.BaseResource{accept(e,t,r){return this.merge(e,t,r)}addSpentTime(e,t,r,n){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/add_spent_time`,{duration:r,...n})}all({projectId:e,groupId:t,...r}={}){let n="";if(e){n=endpoint`projects/${e}/`}else if(t){n=endpoint`groups/${t}/`}return a.get()(this,`${n}merge_requests`,r)}allDiffs(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/diffs`,r)}allCommits(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/commits`,r)}allDiffVersions(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/versions`,r)}allIssuesClosed(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/closes_issues`,r)}allParticipants(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/participants`,r)}allPipelines(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/pipelines`,r)}cancelOnPipelineSuccess(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/cancel_merge_when_pipeline_succeeds`,r)}create(e,t,r,n,s){return a.post()(this,endpoint`projects/${e}/merge_requests`,{sourceBranch:t,targetBranch:r,title:n,...s})}createPipeline(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/pipelines`,r)}createTodo(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/todo`,r)}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/merge_requests/${t}`,r)}merge(e,t,r){return a.put()(this,endpoint`projects/${e}/merge_requests/${t}/merge`,r)}mergeToDefault(e,t,r){return a.put()(this,endpoint`projects/${e}/merge_requests/${t}/merge_ref`,r)}rebase(e,t,r){return a.put()(this,endpoint`projects/${e}/merge_requests/${t}/rebase`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/merge_requests/${t}`,r)}resetSpentTime(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/reset_spent_time`,r)}resetTimeEstimate(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/reset_time_estimate`,r)}setTimeEstimate(e,t,r,n){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/time_estimate`,{duration:r,...n})}show(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}`,r)}showChanges(e,t,r){process.emitWarning('This endpoint was deprecated in Gitlab API 15.7 and will be removed in API v5. Please use the "allDiffs" function instead.',"DeprecationWarning");return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/changes`,r)}showDiffVersion(e,t,r,n){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/versions/${r}`,n)}showTimeStats(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/time_stats`,r)}subscribe(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/subscribe`,r)}unsubscribe(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/unsubscribe`,r)}};var _t=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/merge_trains`,t)}showStatus(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_trains/merge_requests/${t}`,r)}addMergeRequest(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_trains/merge_requests/${t}`,r)}};var Et=class extends n.BaseResource{publish(e,t,r,n,{contentType:s,...o}={}){return a.put()(this,endpoint`projects/${e}/packages/generic/${t}/${r}/${n.filename}`,{isForm:true,file:[n.content,n.filename],...o})}download(e,t,r,n,s){return a.get()(this,endpoint`projects/${e}/packages/generic/${t}/${r}/${n}`,s)}};var St=class extends n.BaseResource{all({projectId:e,groupId:t,...r}={}){let n;if(e)n=endpoint`projects/${e}/packages`;else if(t)n=endpoint`groups/${t}/packages`;else{throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter.")}return a.get()(this,n,r)}allFiles(e,t,r){return a.get()(this,endpoint`projects/${e}/packages/${t}/package_files`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/packages/${t}`,r)}removeFile(e,t,r,n){return a.del()(this,endpoint`projects/${e}/packages/${t}/package_files/${r}`,n)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/packages/${t}`,r)}};var At=class extends n.BaseResource{all({projectId:e,...t}={}){const r=e?endpoint`projects/${e}/`:"";return a.get()(this,`${r}pages/domains`,t)}create(e,t,r){return a.post()(this,endpoint`projects/${e}/pages/domains`,{domain:t,...r})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/pages/domains/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/pages/domains/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/pages/domains/${t}`,r)}};var jt=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/pipelines`,t)}allVariables(e,t,r){return a.get()(this,endpoint`projects/${e}/pipelines/${t}/variables`,r)}cancel(e,t,r){return a.post()(this,endpoint`projects/${e}/pipelines/${t}/cancel`,r)}create(e,t,r){return a.post()(this,endpoint`projects/${e}/pipeline`,{ref:t,...r})}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/pipelines/${t}`,r)}retry(e,t,r){return a.post()(this,endpoint`projects/${e}/pipelines/${t}/retry`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/pipelines/${t}`,r)}showTestReport(e,t,r){return a.get()(this,endpoint`projects/${e}/pipelines/${t}/test_report`,r)}showTestReportSummary(e,t,r){return a.get()(this,endpoint`projects/${e}/pipelines/${t}/test_report_summary`,r)}};var Rt=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/pipeline_schedules`,t)}allTriggeredPipelines(e,t,r){return a.get()(this,endpoint`projects/${e}/pipeline_schedules/${t}/pipelines`,r)}create(e,t,r,n,s){return a.post()(this,endpoint`projects/${e}/pipeline_schedules`,{description:t,ref:r,cron:n,...s})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/pipeline_schedules/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/pipeline_schedules/${t}`,r)}run(e,t,r){return a.post()(this,endpoint`projects/${e}/pipeline_schedules/${t}/play`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/pipeline_schedules/${t}`,r)}takeOwnership(e,t,r){return a.post()(this,endpoint`projects/${e}/pipeline_schedules/${t}/take_ownership`,r)}};var xt=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`projects/${e}/pipeline_schedules/${t}/variables`,r)}create(e,t,r,n,s){return a.post()(this,endpoint`projects/${e}/pipeline_schedules/${t}/variables`,{...s,key:r,value:n})}edit(e,t,r,n,s){return a.put()(this,endpoint`projects/${e}/pipeline_schedules/${t}/variables/${r}`,{...s,value:n})}remove(e,t,r,n){return a.del()(this,endpoint`projects/${e}/pipeline_schedules/${t}/variables/${r}`,n)}};var kt=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/triggers`,t)}create(e,t,r){return a.post()(this,endpoint`projects/${e}/triggers`,{description:t,...r})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/triggers/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/triggers/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/triggers/${t}`,r)}trigger(e,t,r,{variables:n,...s}={}){const o={...s,searchParams:{token:r,ref:t}};if(n){o.isForm=true;Object.assign(o,reformatObjectOptions(n,"variables"))}return a.post()(this,endpoint`projects/${e}/trigger/pipeline`,o)}};var It=class extends n.BaseResource{allFunnels(e,t){return a.get()(this,endpoint`projects/${e}/product_analytics/funnels`,t)}load(e,t){return a.post()(this,endpoint`projects/${e}/product_analytics/request/load`,t)}dryRun(e,t){return a.post()(this,endpoint`projects/${e}/product_analytics/request/dry-run`,t)}showMetadata(e,t){return a.get()(this,endpoint`projects/${e}/product_analytics/request/meta`,t)}};var Pt=class extends R{constructor(e){super("projects",e)}};var Ct=class extends x{constructor(e){super("projects",e)}};var Tt=class extends n.BaseResource{all(e){return a.get()(this,"project_aliases",e)}create(e,t,r){return a.post()(this,"project_aliases",{name:t,projectId:e,...r})}edit(e,t){return a.post()(this,`project_aliases/${e}`,t)}remove(e,t){return a.del()(this,`project_aliases/${e}`,t)}};var Ot=class extends P{constructor(e){super("projects",e)}};var Mt=class extends C{constructor(e){super("projects",e)}};var Nt=class extends T{constructor(e){super("projects",e)}};var Lt=class extends H{constructor(e){super("projects",e)}};var Ft=class extends n.BaseResource{download(e,t){return a.get()(this,endpoint`projects/${e}/export/download`,t)}import(e,t,r){return a.post()(this,"projects/import",{isForm:true,...r,file:[e.content,e.filename],path:t})}importRemote(e,t,r){return a.post()(this,"projects/remote-import",{...r,path:t,url:e})}importRemoteS3(e,t,r,n,s,o,i){return a.post()(this,"projects/remote-import",{...i,accessKeyId:e,bucketName:t,fileKey:r,path:n,region:s,secretAccessKey:o})}showExportStatus(e,t){return a.get()(this,endpoint`projects/${e}/export`,t)}showImportStatus(e,t){return a.get()(this,endpoint`projects/${e}/import`,t)}scheduleExport(e,t,r){return a.post()(this,endpoint`projects/${e}/export`,{...r,upload:t})}};var Bt=class extends W{constructor(e){super("projects",e)}};var Dt=class extends M{constructor(e){super("projects",e)}};var Ut=class extends z{constructor(e){super("project",e)}};var Gt=class extends N{constructor(e){super("projects",e)}};var qt=class extends L{constructor(e){super("projects",e)}};var Ht=class extends B{constructor(e){super("projects",e)}promote(e,t,r){return a.post()(this,endpoint`${e}/milestones/${t}/promote`,r)}};var Kt=class extends V{constructor(e){super("groups",e)}};var Yt=class extends K{constructor(e){super("projects",e)}};var Wt=class extends n.BaseResource{download(e,t,r){return a.get()(this,endpoint`projects/${e}/export_relations/download`,{relation:t,...r})}showExportStatus(e,t){return a.get()(this,endpoint`projects/${e}/export_relations/status`,t)}scheduleExport(e,t){return a.post()(this,endpoint`projects/${e}/export_relations`,t)}};var zt=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/releases`,t)}create(e,t){return a.post()(this,endpoint`projects/${e}/releases`,t)}createEvidence(e,t,r){return a.post()(this,endpoint`projects/${e}/releases/${t}/evidence`,r)}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/releases/${t}`,r)}download(e,t,r,n){return a.get()(this,endpoint`projects/${e}/releases/${t}/downloads/${r}`,n)}downloadLatest(e,t,r){return a.get()(this,endpoint`projects/${e}/releases/permalink/latest/downloads/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/releases/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/releases/${t}`,r)}showLatest(e,t){return a.get()(this,endpoint`projects/${e}/releases/permalink/latest`,t)}showLatestEvidence(e,t){return a.get()(this,endpoint`projects/${e}/releases/permalink/latest/evidence`,t)}};var Vt=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/remote_mirrors`,t)}createPullMirror(e,t,r,n){return a.post()(this,endpoint`projects/${e}/mirror/pull`,{importUrl:t,mirror:r,...n})}createPushMirror(e,t,r){return a.post()(this,endpoint`projects/${e}/remote_mirrors`,{url:t,...r})}edit(e,t,r){return a.post()(this,endpoint`projects/${e}/remote_mirrors/${t}`,r)}remove(e,t){return a.del()(this,`project_aliases/${e}`,t)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/remote_mirrors/${t}`,r)}};var Qt=class extends Y{constructor(e){super("projects",e)}};var Jt=class extends n.BaseResource{all({userId:e,starredOnly:t,...r}={}){let n;if(e&&t)n=endpoint`users/${e}/starred_projects`;else if(e)n=endpoint`users/${e}/projects`;else n="projects";return a.get()(this,n,r)}allTransferLocations(e,t){return a.get()(this,endpoint`projects/${e}/transfer_locations`,t)}allUsers(e,t){return a.get()(this,endpoint`projects/${e}/users`,t)}allGroups(e,t){return a.get()(this,endpoint`projects/${e}/groups`,t)}allSharableGroups(e,t){return a.get()(this,endpoint`projects/${e}/share_locations`,t)}allForks(e,t){return a.get()(this,endpoint`projects/${e}/forks`,t)}allStarrers(e,t){return a.get()(this,endpoint`projects/${e}/starrers`,t)}allStoragePaths(e,t){return a.get()(this,endpoint`projects/${e}/storage`,t)}archive(e,t){return a.post()(this,endpoint`projects/${e}/archive`,t)}create({userId:e,avatar:t,...r}={}){const n=e?`projects/user/${e}`:"projects";if(t){return a.post()(this,n,{...r,isForm:true,avatar:[t.content,t.filename]})}return a.post()(this,n,{...r,avatar:t})}createForkRelationship(e,t,r){return a.post()(this,endpoint`projects/${e}/fork/${t}`,r)}createPullMirror(e,t,r,n){return a.post()(this,endpoint`projects/${e}/mirror/pull`,{importUrl:t,mirror:r,...n})}downloadSnapshot(e,t){return a.get()(this,endpoint`projects/${e}/snapshot`,t)}edit(e,{avatar:t,...r}={}){const n=endpoint`projects/${e}`;if(t){return a.put()(this,n,{...r,isForm:true,avatar:[t.content,t.filename]})}return a.put()(this,n,{...r,avatar:t})}fork(e,t){return a.post()(this,endpoint`projects/${e}/fork`,t)}housekeeping(e,t){return a.post()(this,endpoint`projects/${e}/housekeeping`,t)}importProjectMembers(e,t,r){return a.post()(this,endpoint`projects/${e}/import_project_members/${t}`,r)}remove(e,t){return a.del()(this,endpoint`projects/${e}`,t)}removeForkRelationship(e,t){return a.del()(this,endpoint`projects/${e}/fork`,t)}removeAvatar(e,t){return a.put()(this,endpoint`projects/${e}`,{...t,avatar:""})}restore(e,t){return a.post()(this,endpoint`projects/${e}/restore`,t)}search(e,t){return a.get()(this,"projects",{search:e,...t})}share(e,t,r,n){return a.post()(this,endpoint`projects/${e}/share`,{groupId:t,groupAccess:r,...n})}show(e,t){return a.get()(this,endpoint`projects/${e}`,t)}showLanguages(e,t){return a.get()(this,endpoint`projects/${e}/languages`,t)}showPullMirror(e,t){return a.get()(this,endpoint`projects/${e}/mirror/pull`,t)}star(e,t){return a.post()(this,endpoint`projects/${e}/star`,t)}transfer(e,t,r){return a.put()(this,endpoint`projects/${e}/transfer`,{...r,namespace:t})}unarchive(e,t){return a.post()(this,endpoint`projects/${e}/unarchive`,t)}unshare(e,t,r){return a.del()(this,endpoint`projects/${e}/share/${t}`,r)}unstar(e,t){return a.post()(this,endpoint`projects/${e}/unstar`,t)}uploadForReference(e,t,r){return a.post()(this,endpoint`projects/${e}/uploads`,{...r,isForm:true,file:[t.content,t.filename]})}uploadAvatar(e,t,r){return a.put()(this,endpoint`projects/${e}`,{...r,isForm:true,avatar:[t.content,t.filename]})}};var Xt=class extends k{constructor(e){super("projects","snippets",e)}};var Zt=class extends O{constructor(e){super("projects","snippets",e)}};var er=class extends D{constructor(e){super("projects","snippets",e)}};var tr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/snippets`,t)}create(e,t,r){return a.post()(this,endpoint`projects/${e}/snippets`,{title:t,...r})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/snippets/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/snippets/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/snippets/${t}`,r)}showContent(e,t,r){return a.get()(this,endpoint`projects/${e}/snippets/${t}/raw`,r)}showRepositoryFileContent(e,t,r,n,s){return a.get()(this,endpoint`projects/${e}/snippets/${t}/files/${r}/${n}/raw`,s)}showUserAgentDetails(e,t,r){return a.get()(this,endpoint`projects/${e}/snippets/${t}/user_agent_detail`,r)}};var rr=class extends n.BaseResource{show(e,t){return a.get()(this,endpoint`projects/${e}/statistics`,t)}};var nr=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`projects/${e}/templates/${t}`,r)}show(e,t,r,n){return a.get()(this,endpoint`projects/${e}/templates/${t}/${r}`,n)}};var sr=class extends G{constructor(e){super("projects",e)}};var or=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/vulnerabilities`,t)}create(e,t,r){return a.post()(this,endpoint`projects/${e}/vulnerabilities`,{...r,searchParams:{findingId:t}})}};var ir=class extends q{constructor(e){super("projects",e)}};var ar=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/protected_branches`,t)}create(e,t,r){const{sudo:n,showExpanded:s,...o}=r||{};return a.post()(this,endpoint`projects/${e}/protected_branches`,{searchParams:{...o,name:t},sudo:n,showExpanded:s})}protect(e,t,r){return this.create(e,t,r)}edit(e,t,r){return a.patch()(this,endpoint`projects/${e}/protected_branches/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/protected_branches/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/protected_branches/${t}`,r)}unprotect(e,t,r){return this.remove(e,t,r)}};var cr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/protected_tags`,t)}create(e,t,r){const{sudo:n,showExpanded:s,...o}=r||{};return a.post()(this,endpoint`projects/${e}/protected_tags`,{searchParams:{name:t,...o},sudo:n,showExpanded:s})}protect(e,t,r){return this.create(e,t,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/protected_tags/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/protected_tags/${t}`,r)}unprotect(e,t,r){return this.remove(e,t,r)}};var ur=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`projects/${e}/releases/${t}/assets/links`,r)}create(e,t,r,n,s){return a.post()(this,endpoint`projects/${e}/releases/${t}/assets/links`,{name:r,url:n,...s})}edit(e,t,r,n){return a.put()(this,endpoint`projects/${e}/releases/${t}/assets/links/${r}`,n)}remove(e,t,r,n){return a.del()(this,endpoint`projects/${e}/releases/${t}/assets/links/${r}`,n)}show(e,t,r,n){return a.get()(this,endpoint`projects/${e}/releases/${t}/assets/links/${r}`,n)}};var lr=class extends n.BaseResource{allContributors(e,t){return a.get()(this,endpoint`projects/${e}/repository/contributors`,t)}allRepositoryTrees(e,t){return a.get()(this,endpoint`projects/${e}/repository/tree`,t)}compare(e,t,r,n){return a.get()(this,endpoint`projects/${e}/repository/compare`,{from:t,to:r,...n})}editChangelog(e,t,r){return a.post()(this,endpoint`projects/${e}/repository/changelog`,{...r,version:t})}mergeBase(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/merge_base`,{...r,refs:t})}showArchive(e,{fileType:t="tar.gz",...r}={}){return a.get()(this,endpoint`projects/${e}/repository/archive.${t}`,r)}showBlob(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/blobs/${t}`,r)}showBlobRaw(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/blobs/${t}/raw`,r)}showChangelog(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/changelog`,{...r,version:t})}};var pr=class extends n.BaseResource{allFileBlames(e,t,r,n){return a.get()(this,endpoint`projects/${e}/repository/files/${t}/blame`,{ref:r,...n})}create(e,t,r,n,s,o){return a.post()(this,endpoint`projects/${e}/repository/files/${t}`,{branch:r,content:n,commitMessage:s,...o})}edit(e,t,r,n,s,o){return a.put()(this,endpoint`projects/${e}/repository/files/${t}`,{branch:r,content:n,commitMessage:s,...o})}remove(e,t,r,n,s){return a.del()(this,endpoint`projects/${e}/repository/files/${t}`,{branch:r,commitMessage:n,...s})}show(e,t,r,n){return a.get()(this,endpoint`projects/${e}/repository/files/${t}`,{ref:r,...n})}showRaw(e,t,r,n){return a.get()(this,endpoint`projects/${e}/repository/files/${t}/raw`,{ref:r,...n})}};var dr=class extends n.BaseResource{edit(e,t,r,n,s){return a.put()(this,endpoint`projects/${e}/repository/submodules/${t}`,{branch:r,commitSha:n,...s})}};var fr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/resource_groups`,t)}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/resource_groups/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/resource_groups/${t}`,r)}allUpcomingJobs(e,t){return a.get()(this,endpoint`projects/${e}/resource_groups/upcoming_jobs`,t)}};var hr=class extends n.BaseResource{all({projectId:e,groupId:t,owned:r,...n}={}){let s;if(e)s=endpoint`projects/${e}/runners`;else if(t)s=endpoint`groups/${t}/runners`;else if(r)s="runners";else s="runners/all";return a.get()(this,s,n)}allJobs(e,t){return a.get()(this,`runners/${e}/jobs`,t)}create(e,t){return a.post()(this,`runners`,{token:e,...t})}edit(e,t){return a.put()(this,`runners/${e}`,t)}enable(e,t,r){return a.post()(this,endpoint`projects/${e}/runners`,{runnerId:t,...r})}disable(e,t,r){return a.del()(this,endpoint`projects/${e}/runners/${t}`,r)}register(e,t){return this.create(e,t)}remove({runnerId:e,token:t,...r}){let n;if(e)n=`runners/${e}`;else if(t){n="runners"}else throw new Error("Missing required argument. Please supply a runnerId or a token in the options parameter");return a.del()(this,n,{token:t,...r})}resetRegistrationToken({runnerId:e,token:t,...r}={}){let n;if(e)n=endpoint`runners/${e}/reset_registration_token`;else if(t)n="runners/reset_registration_token";else{throw new Error("Missing either runnerId or token parameters")}return a.post()(this,n,{token:t,...r})}show(e,t){return a.get()(this,`runners/${e}`,t)}verify(e){return a.post()(this,`runners/verify`,e)}};var gr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/secure_files`,t)}create(e,t,r,n){return a.post()(this,`projects/${e}/secure_files`,{isForm:true,...n,file:[r.content,r.filename],name:t})}download(e,t,r){return a.get()(this,endpoint`projects/${e}/secure_files/${t}/download`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/secure_files/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/secure_files/${t}`,r)}};var mr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/repository/tags`,t)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/repository/tags`,{searchParams:{tagName:t,ref:r},...n})}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/repository/tags/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/tags/${t}`,r)}showSignature(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/tags/${t}/signature`,r)}};var yr=class extends n.BaseResource{create(e,t,r){return a.get()(this,endpoint`projects/${e}/metrics/user_starred_dashboards`,{dashboardPath:t,...r})}remove(e,t){return a.del()(this,endpoint`projects/${e}/metrics/user_starred_dashboards`,t)}};var vr=class extends k{constructor(e){super("epics","issues",e)}};var $r=class extends O{constructor(e){super("groups","epics",e)}};var br=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`groups/${e}/epics/${t}/issues`,r)}assign(e,t,r,n){return a.post()(this,endpoint`groups/${e}/epics/${t}/issues/${r}`,n)}edit(e,t,r,n){return a.put()(this,endpoint`groups/${e}/epics/${t}/issues/${r}`,n)}remove(e,t,r,n){return a.del()(this,endpoint`groups/${e}/epics/${t}/issues/${r}`,n)}};var wr=class extends J{constructor(e){super("groups","epic",e)}};var _r=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`groups/${e}/epics/${t}/links`,r)}assign(e,t,r,n){return a.post()(this,endpoint`groups/${e}/epics/${t}/links/${r}`,n)}create(e,t,r,n){return a.post()(this,endpoint`groups/${e}/epics/${t}/links`,{searchParams:{title:r},...n})}reorder(e,t,r,n){return a.put()(this,endpoint`groups/${e}/epics/${t}/links/${r}`,n)}unassign(e,t,r,n){return a.del()(this,endpoint`groups/${e}/epics/${t}/links/${r}`,n)}};var Er=class extends D{constructor(e){super("groups","epics",e)}};var Sr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`groups/${e}/epics`,t)}create(e,t,r){return a.post()(this,endpoint`groups/${e}/epics`,{title:t,...r})}createTodo(e,t,r){return a.post()(this,endpoint`groups/${e}/epics/${t}/todos`,r)}edit(e,t,r){return a.put()(this,endpoint`groups/${e}/epics/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`groups/${e}/epics/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`groups/${e}/epics/${t}`,r)}};var Ar=class extends R{constructor(e){super("groups",e)}};var jr=class extends x{constructor(e){super("groups",e)}};var Rr=class extends n.BaseResource{showIssuesCount(e,t){return a.get()(this,"analytics/group_activity/issues_count",{searchParams:{groupPath:e},...t})}showMergeRequestsCount(e,t){return a.get()(this,"analytics/group_activity/merge_requests_count",{searchParams:{groupPath:e},...t})}showNewMembersCount(e,t){return a.get()(this,"analytics/group_activity/new_members_count",{searchParams:{groupPath:e},...t})}};var xr=class extends P{constructor(e){super("groups",e)}};var kr=class extends C{constructor(e){super("groups",e)}};var Ir=class extends T{constructor(e){super("groups",e)}};var Pr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`groups/${e}/epic_boards`,t)}allLists(e,t,r){return a.get()(this,endpoint`groups/${e}/epic_boards/${t}/lists`,r)}show(e,t,r){return a.get()(this,endpoint`groups/${e}/epic_boards/${t}`,r)}showList(e,t,r,n){return a.get()(this,endpoint`groups/${e}/epic_boards/${t}/lists/${r}`,n)}};var Cr=class extends H{constructor(e){super("groups",e)}};var Tr=class extends n.BaseResource{download(e,t){return a.get()(this,endpoint`groups/${e}/export/download`,t)}import(e,t,{parentId:r,name:n,...s}){return a.post()(this,"groups/import",{isForm:true,...s,file:[e.content,e.filename],path:t,name:n||t.split("/").at(0),parentId:r})}scheduleExport(e,t){return a.post()(this,endpoint`groups/${e}/export`,t)}};var Or=class extends W{constructor(e){super("groups",e)}};var Mr=class extends M{constructor(e){super("groups",e)}};var Nr=class extends z{constructor(e){super("groups",e)}};var Lr=class extends N{constructor(e){super("groups",e)}};var Fr=class extends n.BaseResource{add(e,t,r,n){return a.post()(this,endpoint`groups/${e}/ldap_group_links`,{groupAccess:t,provider:r,...n})}all(e,t){return a.get()(this,endpoint`groups/${e}/ldap_group_links`,t)}remove(e,t,r){return a.del()(this,endpoint`groups/${e}/ldap_group_links`,{provider:t,...r})}sync(e,t){return a.post()(this,endpoint`groups/${e}/ldap_sync`,t)}};var Br=class extends L{constructor(e){super("groups",e)}allBillable(e,t){return a.get()(this,endpoint`${e}/billable_members`,t)}allPending(e,t){return a.get()(this,endpoint`${e}/pending_members`,t)}allBillableMemberships(e,t,r){return a.get()(this,endpoint`${e}/billable_members/${t}/memberships`,r)}approve(e,t,r){return a.put()(this,endpoint`${e}/members/${t}/approve`,r)}approveAll(e,t){return a.put()(this,endpoint`${e}/members/approve_all`,t)}removeBillable(e,t,r){return a.del()(this,endpoint`${e}/billable_members/${t}`,r)}removeOverrideFlag(e,t,r){return a.del()(this,endpoint`${e}/members/${t}/override`,r)}setOverrideFlag(e,t,r){return a.post()(this,endpoint`${e}/members/${t}/override`,r)}};var Dr=class extends n.BaseResource{add(e,t,r){return a.post()(this,endpoint`groups/${e}/members`,{baseAccessLevel:t,...r})}all(e,t){return a.get()(this,endpoint`groups/${e}/member_roles`,t)}remove(e,t,r){return a.del()(this,endpoint`groups/${e}/member_roles/${t}`,r)}};var Ur=class extends B{constructor(e){super("groups",e)}};var Gr=class extends V{constructor(e){super("groups",e)}};var qr=class extends K{constructor(e){super("groups",e)}};var Hr=class extends n.BaseResource{download(e,t,r){return a.get()(this,endpoint`groups/${e}/export_relations/download`,{searchParams:{relation:t},...r})}exportStatus(e,t){return a.get()(this,endpoint`groups/${e}/export_relations`,t)}scheduleExport(e,t){return a.post()(this,endpoint`groups/${e}/export_relations`,t)}};var Kr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`groups/${e}/releases`,t)}};var Yr=class extends Y{constructor(e){super("groups",e)}};var Wr=class extends n.BaseResource{all(e){return a.get()(this,"groups",e)}allDescendantGroups(e,t){return a.get()(this,endpoint`groups/${e}/descendant_groups`,t)}allProjects(e,t){return a.get()(this,endpoint`groups/${e}/projects`,t)}allSharedProjects(e,t){return a.get()(this,endpoint`groups/${e}/projects/shared`,t)}allSubgroups(e,t){return a.get()(this,endpoint`groups/${e}/subgroups`,t)}allProvisionedUsers(e,t){return a.get()(this,endpoint`groups/${e}/provisioned_users`,t)}allTransferLocations(e,t){return a.get()(this,endpoint`groups/${e}/transfer_locations`,t)}create(e,t,{avatar:r,...n}={}){if(r){return a.post()(this,"groups",{...n,isForm:true,avatar:[r.content,r.filename],name:e,path:t})}return a.post()(this,"groups",{name:e,path:t,...n})}downloadAvatar(e,t){return a.get()(this,endpoint`groups/${e}/avatar`,t)}edit(e,{avatar:t,...r}={}){if(t){return a.post()(this,endpoint`groups/${e}`,{...r,isForm:true,avatar:[t.content,t.filename]})}return a.put()(this,endpoint`groups/${e}`,r)}remove(e,t){return a.del()(this,endpoint`groups/${e}`,t)}removeAvatar(e,t){return a.put()(this,endpoint`groups/${e}`,{...t,avatar:""})}restore(e,t){return a.post()(this,endpoint`groups/${e}/restore`,t)}search(e,t){return a.get()(this,"groups",{search:e,...t})}share(e,t,r,n){return a.post()(this,endpoint`groups/${e}/share`,{groupId:t,groupAccess:r,...n})}show(e,t){return a.get()(this,endpoint`groups/${e}`,t)}transfer(e,t){return a.post()(this,endpoint`groups/${e}/transfer`,t)}transferProject(e,t,r){return a.post()(this,endpoint`groups/${e}/projects/${t}`,r)}unshare(e,t,r){return a.del()(this,endpoint`groups/${e}/share/${t}`,r)}uploadAvatar(e,t,{filename:r,...n}={}){return a.put()(this,endpoint`groups/${e}/avatar`,{isForm:true,...n,file:[t,r]})}};var zr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`groups/${e}/saml/identities`,t)}edit(e,t,r){return a.patch()(this,endpoint`groups/${e}/saml/${t}`,r)}};var Vr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`groups/${e}/saml_group_links`,t)}create(e,t,r,n){return a.post()(this,endpoint`groups/${e}/saml_group_links`,{accessLevel:r,samlGroupName:t,...n})}remove(e,t,r){return a.del()(this,endpoint`groups/${e}/saml_group_links/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`groups/${e}/saml_group_links/${t}`,r)}};var Qr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`groups/${e}/scim/identities`,t)}edit(e,t,r){return a.patch()(this,endpoint`groups/${e}/scim/${t}`,r)}};var Jr=class extends n.BaseResource{create(e,t){return a.post()(this,endpoint`groups/${e}/service_accounts`,t)}addPersonalAccessToken(e,t,r){return a.post()(this,endpoint`groups/${e}/service_accounts/${t}`,r)}rotatePersonalAccessToken(e,t,r,n){return a.post()(this,endpoint`groups/${e}/service_accounts/${t}/personal_access_tokens/${r}/rotate`,n)}};var Xr=class extends G{constructor(e){super("groups",e)}};var Zr=class extends q{constructor(e){super("groups",e)}};var en=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`groups/${e}/epics/${t}/related_epics`,r)}create(e,t,r,n,s){return a.post()(this,endpoint`groups/${e}/epics/${t}/related_epics`,{searchParams:{targetGroupId:n,targetEpicIid:r},...s})}remove(e,t,r,n){return a.del()(this,endpoint`groups/${e}/epics/${t}/related_epics/${r}`,n)}};var tn=class extends C{constructor(e){super("users",e)}};var url9=e=>e?`users/${e}/emails`:"user/emails";var rn=class extends n.BaseResource{add(e,t){return this.create(e,t)}all({userId:e,...t}={}){return a.get()(this,url9(e),t)}create(e,{userId:t,...r}={}){return a.post()(this,url9(t),{email:e,...r})}show(e,t){return a.get()(this,`user/emails/${e}`,t)}remove(e,{userId:t,...r}={}){return a.del()(this,`${url9(t)}/${e}`,r)}};var url10=e=>e?`users/${e}/gpg_keys`:"user/gpg_keys";var nn=class extends n.BaseResource{add(e,t){return this.create(e,t)}all({userId:e,...t}={}){return a.get()(this,url10(e),t)}create(e,{userId:t,...r}={}){return a.post()(this,url10(t),{key:e,...r})}show(e,{userId:t,...r}={}){return a.get()(this,`${url10(t)}/${e}`,r)}remove(e,{userId:t,...r}={}){return a.del()(this,`${url10(t)}/${e}`,r)}};var sn=class extends n.BaseResource{all(e,t){return a.get()(this,`users/${e}/impersonation_tokens`,t)}create(e,t,r,n){return a.post()(this,`users/${e}/impersonation_tokens`,{name:t,scopes:r,...n})}show(e,t,r){return a.get()(this,`users/${e}/impersonation_tokens/${t}`,r)}remove(e,t,r){return a.del()(this,`users/${e}/impersonation_tokens/${t}`,r)}revoke(e,t,r){return this.remove(e,t,r)}};var on=class extends n.BaseResource{activate(e,t){return a.post()(this,endpoint`users/${e}/activate`,t)}all(e){return a.get()(this,"users",e)}allActivities(e){return a.get()(this,"user/activities",e)}allEvents(e,t){return a.get()(this,endpoint`users/${e}/events`,t)}allFollowers(e,t){return a.get()(this,endpoint`users/${e}/followers`,t)}allFollowing(e,t){return a.get()(this,endpoint`users/${e}/following`,t)}allMemberships(e,t){return a.get()(this,endpoint`users/${e}/memberships`,t)}allProjects(e,t){return a.get()(this,endpoint`users/${e}/projects`,t)}allContributedProjects(e,t){return a.get()(this,endpoint`users/${e}/contributed_projects`,t)}allStarredProjects(e,t){return a.get()(this,endpoint`users/${e}/starred_projects`,t)}approve(e,t){return a.post()(this,endpoint`users/${e}/approve`,t)}ban(e,t){return a.post()(this,endpoint`users/${e}/ban`,t)}block(e,t){return a.post()(this,endpoint`users/${e}/block`,t)}create(e){return a.post()(this,"users",e)}createPersonalAccessToken(e,t,r,n){return a.post()(this,endpoint`users/${e}/personal_access_tokens`,{name:t,scopes:r,...n})}createCIRunner(e,t){return a.post()(this,"user/runners",{...t,runnerType:e})}deactivate(e,t){return a.post()(this,endpoint`users/${e}/deactivate`,t)}disableTwoFactor(e,t){return a.patch()(this,endpoint`users/${e}/disable_two_factor`,t)}edit(e,t){return a.put()(this,endpoint`users/${e}`,t)}editStatus(e){return a.put()(this,"user/status",e)}editCurrentUserPreferences(e,t,r){return a.put()(this,"user/preferences",{viewDiffsFileByFile:e,showWhitespaceInDiffs:t,...r})}follow(e,t){return a.post()(this,endpoint`users/${e}/follow`,t)}reject(e,t){return a.post()(this,endpoint`users/${e}/reject`,t)}show(e,t){return a.get()(this,endpoint`users/${e}`,t)}showCount(e){return a.get()(this,"user_counts",e)}showAssociationsCount(e,t){return a.get()(this,`users/${e}/associations_count`,t)}showCurrentUser(e){return a.get()(this,"user",e)}showCurrentUserPreferences(e){return a.get()(this,"user/preferences",e)}showStatus({iDOrUsername:e,...t}={}){let r;if(e)r=`users/${e}/status`;else r="user/status";return a.get()(this,r,t)}remove(e,t){return a.del()(this,endpoint`users/${e}`,t)}removeAuthenticationIdentity(e,t,r){return a.del()(this,endpoint`users/${e}/identities/${t}`,r)}unban(e,t){return a.post()(this,endpoint`users/${e}/unban`,t)}unblock(e,t){return a.post()(this,endpoint`users/${e}/unblock`,t)}unfollow(e,t){return a.post()(this,endpoint`users/${e}/unfollow`,t)}};var url11=e=>e?`users/${e}/keys`:"user/keys";var an=class extends n.BaseResource{add(e,t,r){return this.create(e,t,r)}all({userId:e,...t}={}){return a.get()(this,url11(e),t)}create(e,t,{userId:r,...n}={}){return a.post()(this,url11(r),{title:e,key:t,...n})}show(e,{userId:t,...r}={}){return a.get()(this,`${url11(t)}/${e}`,r)}remove(e,{userId:t,...r}={}){return a.del()(this,`${url11(t)}/${e}`,r)}};var cn={Agents:c,AlertManagement:u,ApplicationAppearance:l,ApplicationPlanLimits:p,Applications:d,ApplicationSettings:f,ApplicationStatistics:h,AuditEvents:g,Avatar:m,BroadcastMessages:y,CodeSuggestions:v,Composer:$,Conan:b,DashboardAnnotations:w,Debian:_,DependencyProxy:S,DeployKeys:A,DeployTokens:j,DockerfileTemplates:ee,Events:te,Experiments:re,GeoNodes:ne,GeoSites:se,GitignoreTemplates:oe,GitLabCIYMLTemplates:ie,Import:ae,InstanceLevelCICDVariables:ce,Keys:ue,License:le,LicenseTemplates:pe,Lint:de,Markdown:fe,Maven:he,Metadata:ge,Migrations:me,Namespaces:ye,NotificationSettings:ve,NPM:$e,NuGet:be,PersonalAccessTokens:we,PyPI:_e,RubyGems:Ee,Search:Se,SearchAdmin:Ae,ServiceAccounts:je,ServiceData:Re,SidekiqMetrics:xe,SidekiqQueues:ke,SnippetRepositoryStorageMoves:Ie,Snippets:Pe,Suggestions:Ce,SystemHooks:Te,TodoLists:Oe,Topics:Me,Branches:Ne,CommitDiscussions:Le,Commits:Fe,ContainerRegistry:Be,Deployments:De,Environments:Ue,ErrorTrackingClientKeys:Ge,ErrorTrackingSettings:qe,ExternalStatusChecks:He,FeatureFlags:Ke,FeatureFlagUserLists:Ye,FreezePeriods:We,GitlabPages:ze,GoProxy:Ve,Helm:Qe,Integrations:Je,IssueAwardEmojis:Xe,IssueDiscussions:Ze,IssueIterationEvents:et,IssueLabelEvents:tt,IssueLinks:rt,IssueMilestoneEvents:nt,IssueNoteAwardEmojis:st,IssueNotes:ot,Issues:it,IssuesStatistics:at,IssueStateEvents:ct,IssueWeightEvents:ut,JobArtifacts:lt,Jobs:pt,MergeRequestApprovals:dt,MergeRequestAwardEmojis:ft,MergeRequestContextCommits:ht,MergeRequestDiscussions:gt,MergeRequestLabelEvents:mt,MergeRequestMilestoneEvents:yt,MergeRequestDraftNotes:vt,MergeRequestNotes:$t,MergeRequestNoteAwardEmojis:bt,MergeRequests:wt,MergeTrains:_t,PackageRegistry:Et,Packages:St,PagesDomains:At,Pipelines:jt,PipelineSchedules:Rt,PipelineScheduleVariables:xt,PipelineTriggerTokens:kt,ProductAnalytics:It,ProjectAccessRequests:Pt,ProjectAccessTokens:Ct,ProjectAliases:Tt,ProjectBadges:Ot,ProjectCustomAttributes:Mt,ProjectDORA4Metrics:Nt,ProjectHooks:Lt,ProjectImportExports:Ft,ProjectInvitations:Bt,ProjectIssueBoards:Dt,ProjectIterations:Ut,ProjectLabels:Gt,ProjectMembers:qt,ProjectMilestones:Ht,ProjectProtectedEnvironments:Kt,ProjectPushRules:Yt,ProjectRelationsExport:Wt,ProjectReleases:zt,ProjectRemoteMirrors:Vt,ProjectRepositoryStorageMoves:Qt,Projects:Jt,ProjectSnippetAwardEmojis:Xt,ProjectSnippetDiscussions:Zt,ProjectSnippetNotes:er,ProjectSnippets:tr,ProjectStatistics:rr,ProjectTemplates:nr,ProjectVariables:sr,ProjectVulnerabilities:or,ProjectWikis:ir,ProtectedBranches:ar,ProtectedTags:cr,ReleaseLinks:ur,Repositories:lr,RepositoryFiles:pr,RepositorySubmodules:dr,ResourceGroups:fr,Runners:hr,SecureFiles:gr,Tags:mr,UserStarredMetricsDashboard:yr,EpicAwardEmojis:vr,EpicDiscussions:$r,EpicIssues:br,EpicLabelEvents:wr,EpicLinks:_r,EpicNotes:Er,Epics:Sr,GroupAccessRequests:Ar,GroupAccessTokens:jr,GroupActivityAnalytics:Rr,GroupBadges:xr,GroupCustomAttributes:kr,GroupDORA4Metrics:Ir,GroupEpicBoards:Pr,GroupHooks:Cr,GroupImportExports:Tr,GroupInvitations:Or,GroupIssueBoards:Mr,GroupIterations:Nr,GroupLabels:Lr,GroupLDAPLinks:Fr,GroupMembers:Br,GroupMemberRoles:Dr,GroupMilestones:Ur,GroupProtectedEnvironments:Gr,GroupPushRules:qr,GroupRelationExports:Hr,GroupReleases:Kr,GroupRepositoryStorageMoves:Yr,Groups:Wr,GroupSAMLIdentities:zr,GroupSAMLLinks:Vr,GroupSCIMIdentities:Qr,GroupServiceAccounts:Jr,GroupVariables:Xr,GroupWikis:Zr,LinkedEpics:en,UserCustomAttributes:tn,UserEmails:rn,UserGPGKeys:nn,UserImpersonationTokens:sn,Users:on,UserSSHKeys:an};var un=class extends n.BaseResource{constructor(e){super(e);Object.keys(cn).forEach((t=>{this[t]=new cn[t](e)}))}};var ln=(e=>{e[e["NO_ACCESS"]=0]="NO_ACCESS";e[e["MINIMAL_ACCESS"]=5]="MINIMAL_ACCESS";e[e["GUEST"]=10]="GUEST";e[e["REPORTER"]=20]="REPORTER";e[e["DEVELOPER"]=30]="DEVELOPER";e[e["MAINTAINER"]=40]="MAINTAINER";e[e["OWNER"]=50]="OWNER";e[e["ADMIN"]=60]="ADMIN";return e})(ln||{});t.AccessLevel=ln;t.Agents=c;t.AlertManagement=u;t.ApplicationAppearance=l;t.ApplicationPlanLimits=p;t.ApplicationSettings=f;t.ApplicationStatistics=h;t.Applications=d;t.AuditEvents=g;t.Avatar=m;t.Branches=Ne;t.BroadcastMessages=y;t.CodeSuggestions=v;t.CommitDiscussions=Le;t.Commits=Fe;t.Composer=$;t.Conan=b;t.ContainerRegistry=Be;t.DashboardAnnotations=w;t.Debian=_;t.DependencyProxy=S;t.DeployKeys=A;t.DeployTokens=j;t.Deployments=De;t.DockerfileTemplates=ee;t.Environments=Ue;t.EpicAwardEmojis=vr;t.EpicDiscussions=$r;t.EpicIssues=br;t.EpicLabelEvents=wr;t.EpicLinks=_r;t.EpicNotes=Er;t.Epics=Sr;t.ErrorTrackingClientKeys=Ge;t.ErrorTrackingSettings=qe;t.Events=te;t.Experiments=re;t.ExternalStatusChecks=He;t.FeatureFlagUserLists=Ye;t.FeatureFlags=Ke;t.FreezePeriods=We;t.GeoNodes=ne;t.GeoSites=se;t.GitLabCIYMLTemplates=ie;t.GitignoreTemplates=oe;t.Gitlab=un;t.GitlabPages=ze;t.GoProxy=Ve;t.GroupAccessRequests=Ar;t.GroupAccessTokens=jr;t.GroupActivityAnalytics=Rr;t.GroupBadges=xr;t.GroupCustomAttributes=kr;t.GroupDORA4Metrics=Ir;t.GroupEpicBoards=Pr;t.GroupHooks=Cr;t.GroupImportExports=Tr;t.GroupInvitations=Or;t.GroupIssueBoards=Mr;t.GroupIterations=Nr;t.GroupLDAPLinks=Fr;t.GroupLabels=Lr;t.GroupMemberRoles=Dr;t.GroupMembers=Br;t.GroupMilestones=Ur;t.GroupProtectedEnvironments=Gr;t.GroupPushRules=qr;t.GroupRelationExports=Hr;t.GroupReleases=Kr;t.GroupRepositoryStorageMoves=Yr;t.GroupSAMLIdentities=zr;t.GroupSAMLLinks=Vr;t.GroupSCIMIdentities=Qr;t.GroupServiceAccounts=Jr;t.GroupVariables=Xr;t.GroupWikis=Zr;t.Groups=Wr;t.Helm=Qe;t.Import=ae;t.InstanceLevelCICDVariables=ce;t.Integrations=Je;t.IssueAwardEmojis=Xe;t.IssueDiscussions=Ze;t.IssueIterationEvents=et;t.IssueLabelEvents=tt;t.IssueLinks=rt;t.IssueMilestoneEvents=nt;t.IssueNoteAwardEmojis=st;t.IssueNotes=ot;t.IssueStateEvents=ct;t.IssueWeightEvents=ut;t.Issues=it;t.IssuesStatistics=at;t.JobArtifacts=lt;t.Jobs=pt;t.Keys=ue;t.License=le;t.LicenseTemplates=pe;t.LinkedEpics=en;t.Lint=de;t.Markdown=fe;t.Maven=he;t.MergeRequestApprovals=dt;t.MergeRequestAwardEmojis=ft;t.MergeRequestContextCommits=ht;t.MergeRequestDiscussions=gt;t.MergeRequestDraftNotes=vt;t.MergeRequestLabelEvents=mt;t.MergeRequestMilestoneEvents=yt;t.MergeRequestNoteAwardEmojis=bt;t.MergeRequestNotes=$t;t.MergeRequests=wt;t.MergeTrains=_t;t.Metadata=ge;t.Migrations=me;t.NPM=$e;t.Namespaces=ye;t.NotificationSettings=ve;t.NuGet=be;t.PackageRegistry=Et;t.Packages=St;t.PagesDomains=At;t.PersonalAccessTokens=we;t.PipelineScheduleVariables=xt;t.PipelineSchedules=Rt;t.PipelineTriggerTokens=kt;t.Pipelines=jt;t.ProductAnalytics=It;t.ProjectAccessRequests=Pt;t.ProjectAccessTokens=Ct;t.ProjectAliases=Tt;t.ProjectBadges=Ot;t.ProjectCustomAttributes=Mt;t.ProjectDORA4Metrics=Nt;t.ProjectHooks=Lt;t.ProjectImportExports=Ft;t.ProjectInvitations=Bt;t.ProjectIssueBoards=Dt;t.ProjectIterations=Ut;t.ProjectLabels=Gt;t.ProjectMembers=qt;t.ProjectMilestones=Ht;t.ProjectProtectedEnvironments=Kt;t.ProjectPushRules=Yt;t.ProjectRelationsExport=Wt;t.ProjectReleases=zt;t.ProjectRemoteMirrors=Vt;t.ProjectRepositoryStorageMoves=Qt;t.ProjectSnippetAwardEmojis=Xt;t.ProjectSnippetDiscussions=Zt;t.ProjectSnippetNotes=er;t.ProjectSnippets=tr;t.ProjectStatistics=rr;t.ProjectTemplates=nr;t.ProjectVariables=sr;t.ProjectVulnerabilities=or;t.ProjectWikis=ir;t.Projects=Jt;t.ProtectedBranches=ar;t.ProtectedTags=cr;t.PyPI=_e;t.ReleaseLinks=ur;t.Repositories=lr;t.RepositoryFiles=pr;t.RepositorySubmodules=dr;t.ResourceGroups=fr;t.RubyGems=Ee;t.Runners=hr;t.Search=Se;t.SearchAdmin=Ae;t.SecureFiles=gr;t.ServiceAccounts=je;t.ServiceData=Re;t.SidekiqMetrics=xe;t.SidekiqQueues=ke;t.SnippetRepositoryStorageMoves=Ie;t.Snippets=Pe;t.Suggestions=Ce;t.SystemHooks=Te;t.Tags=mr;t.TodoLists=Oe;t.Topics=Me;t.UserCustomAttributes=tn;t.UserEmails=rn;t.UserGPGKeys=nn;t.UserImpersonationTokens=sn;t.UserSSHKeys=an;t.UserStarredMetricsDashboard=yr;t.Users=on},8126:(e,t,r)=>{"use strict";var n=r(891);var s=r(6308);var o=r(9490);var i=r(6674);function _interopDefault(e){return e&&e.__esModule?e:{default:e}}var a=_interopDefault(i);function formatQuery(e={}){const t=s.decamelizeKeys(e);return n.stringify(t,{arrayFormat:"brackets"})}async function defaultOptionsHandler(e,{body:t,searchParams:r,sudo:n,signal:o,asStream:i=false,method:a="GET"}={}){const{headers:c,authHeaders:u,url:l}=e;const p={...c};const d={method:a,asStream:i,signal:o,prefixUrl:l};d.headers=p;if(n)d.headers.sudo=`${n}`;if(t){if(t instanceof FormData){d.body=t}else{d.body=JSON.stringify(s.decamelizeKeys(t));d.headers["content-type"]="application/json"}}const[f,h]=Object.entries(u)[0];d.headers[f]=await h();const g=formatQuery(r);if(g)d.searchParams=g;return Promise.resolve(d)}function createRateLimiters(e={}){const t={};Object.entries(e).forEach((([e,r])=>{if(typeof r==="number")t[e]=o.RateLimit(r,{timeUnit:6e4});else t[e]={method:r.method.toUpperCase(),limit:o.RateLimit(r.limit,{timeUnit:6e4})}}));return t}function createRequesterFn(e,t){const r=["get","post","put","patch","delete"];return n=>{const s={};const o=createRateLimiters(n.rateLimits);r.forEach((r=>{s[r]=async(s,i)=>{const a=await defaultOptionsHandler(n,{...i,method:r.toUpperCase()});const c=await e(n,a);return t(s,{...c,rateLimiters:o})}}));return s}}function extendClass(e,t){return class extends e{constructor(...e){const[r,...n]=e;super({...t,...r},...n)}}}function presetResourceArguments(e,t={}){const r={};Object.entries(e).filter((([,e])=>typeof e==="function")).forEach((([e,n])=>{r[e]=extendClass(n,t)}));return r}function getMatchingRateLimiter(e,t={},r="GET"){const n=Object.keys(t).sort().reverse();const s=n.find((t=>a.default.isMatch(e,t)));const i=s&&t[s];if(i&&typeof i!=="object"){return i}if(i&&i.method.toUpperCase()===r.toUpperCase()){return i.limit}return o.RateLimit(3e3,{timeUnit:6e4})}function getDynamicToken(e){return e instanceof Function?e():Promise.resolve(e)}var c=Object.freeze({"**":3e3,"projects/import":6,"projects/*/export":6,"projects/*/download":1,"groups/import":6,"groups/*/export":6,"groups/*/download":1,"projects/*/issues/*/notes":{method:"post",limit:300},"projects/*/snippets/*/notes":{method:"post",limit:300},"projects/*/merge_requests/*/notes":{method:"post",limit:300},"groups/*/epics/*/notes":{method:"post",limit:300},"projects/*/repository/archive*":5,"projects/*/jobs":600,"projects/*/members":60,"groups/*/members":60});var u=class{url;requester;queryTimeout;headers;authHeaders;camelize;rejectUnauthorized;constructor({sudo:e,profileToken:t,camelize:r,requesterFn:n,profileMode:s="execution",host:o="https://gitlab.com",prefixUrl:i="",rejectUnauthorized:a=true,queryTimeout:u=3e5,rateLimits:l=c,...p}){if(!n)throw new ReferenceError("requesterFn must be passed");this.url=[o,"api","v4",i].join("/");this.headers={};this.authHeaders={};this.rejectUnauthorized=a;this.camelize=r;this.queryTimeout=u;if("oauthToken"in p)this.authHeaders.authorization=async()=>{const e=await getDynamicToken(p.oauthToken);return`Bearer ${e}`};else if("jobToken"in p)this.authHeaders["job-token"]=async()=>getDynamicToken(p.jobToken);else if("token"in p)this.authHeaders["private-token"]=async()=>getDynamicToken(p.token);else{throw new ReferenceError("A token, oauthToken or jobToken must be passed")}if(t){this.headers["X-Profile-Token"]=t;this.headers["X-Profile-Mode"]=s}if(e)this.headers.Sudo=`${e}`;this.requester=n({...this,rateLimits:l})}};var l=class extends Error{constructor(e,t){super(e,t);this.name="GitbeakerRequestError"}};var p=class extends Error{constructor(e){super(e);this.name="GitbeakerTimeoutError"}};var d=class extends Error{constructor(e){super(e);this.name="GitbeakerTimeoutError"}};t.BaseResource=u;t.GitbeakerRequestError=l;t.GitbeakerRetryError=d;t.GitbeakerTimeoutError=p;t.createRateLimiters=createRateLimiters;t.createRequesterFn=createRequesterFn;t.defaultOptionsHandler=defaultOptionsHandler;t.formatQuery=formatQuery;t.getMatchingRateLimiter=getMatchingRateLimiter;t.presetResourceArguments=presetResourceArguments},3532:(e,t,r)=>{"use strict";var n=r(5182);var s=r(8126);function _interopNamespace(e){if(e&&e.__esModule)return e;var t=Object.create(null);if(e){Object.keys(e).forEach((function(r){if(r!=="default"){var n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:true,get:function(){return e[r]}})}}))}t.default=e;return Object.freeze(t)}var o=_interopNamespace(n);async function defaultOptionsHandler(e,t){const n={...t};if(e.url.includes("https")&&e.rejectUnauthorized!=null&&e.rejectUnauthorized===false){if(typeof window!=="object"){const{Agent:e}=await Promise.resolve().then(r.t.bind(r,5692,23));n.agent=new e({rejectUnauthorized:false})}}return n}async function processBody(e){const t=(e.headers.get("content-type")||"").split(";")[0].trim();if(t==="application/json"){return e.json().then((e=>e||{}))}if(t.startsWith("text/")){return e.text().then((e=>e||""))}return e.blob()}function delay(e){return new Promise((t=>{setTimeout(t,e)}))}async function parseResponse(e,t=false){const{status:r,headers:n}=e;const s=Object.fromEntries(n.entries());let o;if(t){o=e.body}else{o=r===204?null:await processBody(e)}return{body:o,headers:s,status:r}}async function throwFailedRequestError(e,t){const r=await t.text();const n=t.headers.get("Content-Type");let o="API Request Error";if(n?.includes("application/json")){const e=JSON.parse(r);o=JSON.stringify(e.error||e.message,null,2)}else{o=r}throw new s.GitbeakerRequestError(t.statusText,{cause:{description:o,request:e,response:t}})}function getConditionalMode(e){if(e.includes("repository/archive"))return"same-origin";return void 0}async function defaultRequestHandler(e,t){const r=[429,502];const n=10;const{prefixUrl:o,asStream:i,searchParams:a,rateLimiters:c,method:u,...l}=t||{};const p=s.getMatchingRateLimiter(e,c,u);let d;if(o)d=o.endsWith("/")?o:`${o}/`;const f=new URL(e,d);f.search=a||"";const h=getConditionalMode(e);for(let e=0;e<n;e+=1){const t=new Request(f,{...l,method:u,mode:h});await p();const n=await fetch(t).catch((e=>{if(e.name==="TimeoutError"||e.name==="AbortError"){throw new s.GitbeakerTimeoutError("Query timeout was reached")}throw e}));if(n.ok)return parseResponse(n,i);if(!r.includes(n.status))await throwFailedRequestError(t,n);await delay(2**e*.25);continue}throw new s.GitbeakerRetryError(`Could not successfully complete this request due to Error 429. Check the applicable rate limits for this endpoint.`)}var i=s.createRequesterFn(defaultOptionsHandler,defaultRequestHandler);var{AccessLevel:a,...c}=o;var u=s.presetResourceArguments(c,{requesterFn:i});var l=a;var{Agents:p,AlertManagement:d,ApplicationAppearance:f,ApplicationPlanLimits:h,Applications:g,ApplicationSettings:m,ApplicationStatistics:y,AuditEvents:v,Avatar:$,BroadcastMessages:b,CodeSuggestions:w,Composer:_,Conan:S,DashboardAnnotations:A,Debian:j,DependencyProxy:R,DeployKeys:x,DeployTokens:k,DockerfileTemplates:I,Events:P,Experiments:C,GeoNodes:T,GeoSites:O,GitignoreTemplates:M,GitLabCIYMLTemplates:N,Import:L,InstanceLevelCICDVariables:B,Keys:D,License:U,LicenseTemplates:G,Lint:q,Markdown:H,Maven:K,Metadata:Y,Migrations:W,Namespaces:z,NotificationSettings:V,NPM:Q,NuGet:J,PersonalAccessTokens:X,PyPI:Z,RubyGems:ee,Search:te,SearchAdmin:re,ServiceAccounts:ne,ServiceData:se,SidekiqMetrics:oe,SidekiqQueues:ie,SnippetRepositoryStorageMoves:ae,Snippets:ce,Suggestions:ue,SystemHooks:le,TodoLists:pe,Topics:de,Branches:fe,CommitDiscussions:he,Commits:ge,ContainerRegistry:me,Deployments:ye,Environments:ve,ErrorTrackingClientKeys:$e,ErrorTrackingSettings:be,ExternalStatusChecks:we,FeatureFlags:_e,FeatureFlagUserLists:Ee,FreezePeriods:Se,GitlabPages:Ae,GoProxy:je,Helm:Re,Integrations:xe,IssueAwardEmojis:ke,IssueDiscussions:Ie,IssueIterationEvents:Pe,IssueLabelEvents:Ce,IssueLinks:Te,IssueMilestoneEvents:Oe,IssueNoteAwardEmojis:Me,IssueNotes:Ne,Issues:Le,IssuesStatistics:Fe,IssueStateEvents:Be,IssueWeightEvents:De,JobArtifacts:Ue,Jobs:Ge,MergeRequestApprovals:qe,MergeRequestAwardEmojis:He,MergeRequestContextCommits:Ke,MergeRequestDiscussions:Ye,MergeRequestLabelEvents:We,MergeRequestMilestoneEvents:ze,MergeRequestDraftNotes:Ve,MergeRequestNotes:Qe,MergeRequestNoteAwardEmojis:Je,MergeRequests:Xe,MergeTrains:Ze,PackageRegistry:et,Packages:tt,PagesDomains:rt,Pipelines:nt,PipelineSchedules:st,PipelineScheduleVariables:ot,PipelineTriggerTokens:it,ProductAnalytics:at,ProjectAccessRequests:ct,ProjectAccessTokens:ut,ProjectAliases:lt,ProjectBadges:pt,ProjectCustomAttributes:dt,ProjectDORA4Metrics:ft,ProjectHooks:ht,ProjectImportExports:gt,ProjectInvitations:mt,ProjectIssueBoards:yt,ProjectIterations:vt,ProjectLabels:$t,ProjectMembers:bt,ProjectMilestones:wt,ProjectProtectedEnvironments:_t,ProjectPushRules:Et,ProjectRelationsExport:St,ProjectReleases:At,ProjectRemoteMirrors:jt,ProjectRepositoryStorageMoves:Rt,Projects:xt,ProjectSnippetAwardEmojis:kt,ProjectSnippetDiscussions:It,ProjectSnippetNotes:Pt,ProjectSnippets:Ct,ProjectStatistics:Tt,ProjectTemplates:Ot,ProjectVariables:Mt,ProjectVulnerabilities:Nt,ProjectWikis:Lt,ProtectedBranches:Ft,ProtectedTags:Bt,ReleaseLinks:Dt,Repositories:Ut,RepositoryFiles:Gt,RepositorySubmodules:qt,ResourceGroups:Ht,Runners:Kt,SecureFiles:Yt,Tags:Wt,UserStarredMetricsDashboard:zt,EpicAwardEmojis:Vt,EpicDiscussions:Qt,EpicIssues:Jt,EpicLabelEvents:Xt,EpicLinks:Zt,EpicNotes:er,Epics:tr,GroupAccessRequests:rr,GroupAccessTokens:nr,GroupActivityAnalytics:sr,GroupBadges:or,GroupCustomAttributes:ir,GroupDORA4Metrics:ar,GroupEpicBoards:cr,GroupHooks:ur,GroupImportExports:lr,GroupInvitations:pr,GroupIssueBoards:dr,GroupIterations:fr,GroupLabels:hr,GroupLDAPLinks:gr,GroupMembers:mr,GroupMemberRoles:yr,GroupMilestones:vr,GroupProtectedEnvironments:$r,GroupPushRules:br,GroupRelationExports:wr,GroupReleases:_r,GroupRepositoryStorageMoves:Er,Groups:Sr,GroupSAMLIdentities:Ar,GroupSAMLLinks:jr,GroupSCIMIdentities:Rr,GroupServiceAccounts:xr,GroupVariables:kr,GroupWikis:Ir,LinkedEpics:Pr,UserCustomAttributes:Cr,UserEmails:Tr,UserGPGKeys:Or,UserImpersonationTokens:Mr,Users:Nr,UserSSHKeys:Lr,Gitlab:Fr}=u;t.AccessLevel=l;t.Agents=p;t.AlertManagement=d;t.ApplicationAppearance=f;t.ApplicationPlanLimits=h;t.ApplicationSettings=m;t.ApplicationStatistics=y;t.Applications=g;t.AuditEvents=v;t.Avatar=$;t.Branches=fe;t.BroadcastMessages=b;t.CodeSuggestions=w;t.CommitDiscussions=he;t.Commits=ge;t.Composer=_;t.Conan=S;t.ContainerRegistry=me;t.DashboardAnnotations=A;t.Debian=j;t.DependencyProxy=R;t.DeployKeys=x;t.DeployTokens=k;t.Deployments=ye;t.DockerfileTemplates=I;t.Environments=ve;t.EpicAwardEmojis=Vt;t.EpicDiscussions=Qt;t.EpicIssues=Jt;t.EpicLabelEvents=Xt;t.EpicLinks=Zt;t.EpicNotes=er;t.Epics=tr;t.ErrorTrackingClientKeys=$e;t.ErrorTrackingSettings=be;t.Events=P;t.Experiments=C;t.ExternalStatusChecks=we;t.FeatureFlagUserLists=Ee;t.FeatureFlags=_e;t.FreezePeriods=Se;t.GeoNodes=T;t.GeoSites=O;t.GitLabCIYMLTemplates=N;t.GitignoreTemplates=M;t.Gitlab=Fr;t.GitlabPages=Ae;t.GoProxy=je;t.GroupAccessRequests=rr;t.GroupAccessTokens=nr;t.GroupActivityAnalytics=sr;t.GroupBadges=or;t.GroupCustomAttributes=ir;t.GroupDORA4Metrics=ar;t.GroupEpicBoards=cr;t.GroupHooks=ur;t.GroupImportExports=lr;t.GroupInvitations=pr;t.GroupIssueBoards=dr;t.GroupIterations=fr;t.GroupLDAPLinks=gr;t.GroupLabels=hr;t.GroupMemberRoles=yr;t.GroupMembers=mr;t.GroupMilestones=vr;t.GroupProtectedEnvironments=$r;t.GroupPushRules=br;t.GroupRelationExports=wr;t.GroupReleases=_r;t.GroupRepositoryStorageMoves=Er;t.GroupSAMLIdentities=Ar;t.GroupSAMLLinks=jr;t.GroupSCIMIdentities=Rr;t.GroupServiceAccounts=xr;t.GroupVariables=kr;t.GroupWikis=Ir;t.Groups=Sr;t.Helm=Re;t.Import=L;t.InstanceLevelCICDVariables=B;t.Integrations=xe;t.IssueAwardEmojis=ke;t.IssueDiscussions=Ie;t.IssueIterationEvents=Pe;t.IssueLabelEvents=Ce;t.IssueLinks=Te;t.IssueMilestoneEvents=Oe;t.IssueNoteAwardEmojis=Me;t.IssueNotes=Ne;t.IssueStateEvents=Be;t.IssueWeightEvents=De;t.Issues=Le;t.IssuesStatistics=Fe;t.JobArtifacts=Ue;t.Jobs=Ge;t.Keys=D;t.License=U;t.LicenseTemplates=G;t.LinkedEpics=Pr;t.Lint=q;t.Markdown=H;t.Maven=K;t.MergeRequestApprovals=qe;t.MergeRequestAwardEmojis=He;t.MergeRequestContextCommits=Ke;t.MergeRequestDiscussions=Ye;t.MergeRequestDraftNotes=Ve;t.MergeRequestLabelEvents=We;t.MergeRequestMilestoneEvents=ze;t.MergeRequestNoteAwardEmojis=Je;t.MergeRequestNotes=Qe;t.MergeRequests=Xe;t.MergeTrains=Ze;t.Metadata=Y;t.Migrations=W;t.NPM=Q;t.Namespaces=z;t.NotificationSettings=V;t.NuGet=J;t.PackageRegistry=et;t.Packages=tt;t.PagesDomains=rt;t.PersonalAccessTokens=X;t.PipelineScheduleVariables=ot;t.PipelineSchedules=st;t.PipelineTriggerTokens=it;t.Pipelines=nt;t.ProductAnalytics=at;t.ProjectAccessRequests=ct;t.ProjectAccessTokens=ut;t.ProjectAliases=lt;t.ProjectBadges=pt;t.ProjectCustomAttributes=dt;t.ProjectDORA4Metrics=ft;t.ProjectHooks=ht;t.ProjectImportExports=gt;t.ProjectInvitations=mt;t.ProjectIssueBoards=yt;t.ProjectIterations=vt;t.ProjectLabels=$t;t.ProjectMembers=bt;t.ProjectMilestones=wt;t.ProjectProtectedEnvironments=_t;t.ProjectPushRules=Et;t.ProjectRelationsExport=St;t.ProjectReleases=At;t.ProjectRemoteMirrors=jt;t.ProjectRepositoryStorageMoves=Rt;t.ProjectSnippetAwardEmojis=kt;t.ProjectSnippetDiscussions=It;t.ProjectSnippetNotes=Pt;t.ProjectSnippets=Ct;t.ProjectStatistics=Tt;t.ProjectTemplates=Ot;t.ProjectVariables=Mt;t.ProjectVulnerabilities=Nt;t.ProjectWikis=Lt;t.Projects=xt;t.ProtectedBranches=Ft;t.ProtectedTags=Bt;t.PyPI=Z;t.ReleaseLinks=Dt;t.Repositories=Ut;t.RepositoryFiles=Gt;t.RepositorySubmodules=qt;t.ResourceGroups=Ht;t.RubyGems=ee;t.Runners=Kt;t.Search=te;t.SearchAdmin=re;t.SecureFiles=Yt;t.ServiceAccounts=ne;t.ServiceData=se;t.SidekiqMetrics=oe;t.SidekiqQueues=ie;t.SnippetRepositoryStorageMoves=ae;t.Snippets=ce;t.Suggestions=ue;t.SystemHooks=le;t.Tags=Wt;t.TodoLists=pe;t.Topics=de;t.UserCustomAttributes=Cr;t.UserEmails=Tr;t.UserGPGKeys=Or;t.UserImpersonationTokens=Mr;t.UserSSHKeys=Lr;t.UserStarredMetricsDashboard=zt;t.Users=Nr},9490:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.RateLimit=t.Sema=void 0;const s=n(r(4434));function arrayMove(e,t,r,n,s){for(let o=0;o<s;++o){r[o+n]=e[o+t];e[o+t]=void 0}}function pow2AtLeast(e){e=e>>>0;e=e-1;e=e|e>>1;e=e|e>>2;e=e|e>>4;e=e|e>>8;e=e|e>>16;return e+1}function getCapacity(e){return pow2AtLeast(Math.min(Math.max(16,e),1073741824))}class Deque{constructor(e){this._capacity=getCapacity(e);this._length=0;this._front=0;this.arr=[]}push(e){const t=this._length;this.checkCapacity(t+1);const r=this._front+t&this._capacity-1;this.arr[r]=e;this._length=t+1;return t+1}pop(){const e=this._length;if(e===0){return void 0}const t=this._front+e-1&this._capacity-1;const r=this.arr[t];this.arr[t]=void 0;this._length=e-1;return r}shift(){const e=this._length;if(e===0){return void 0}const t=this._front;const r=this.arr[t];this.arr[t]=void 0;this._front=t+1&this._capacity-1;this._length=e-1;return r}get length(){return this._length}checkCapacity(e){if(this._capacity<e){this.resizeTo(getCapacity(this._capacity*1.5+16))}}resizeTo(e){const t=this._capacity;this._capacity=e;const r=this._front;const n=this._length;if(r+n>t){const e=r+n&t-1;arrayMove(this.arr,0,this.arr,t,e)}}}class ReleaseEmitter extends s.default{}function isFn(e){return typeof e==="function"}function defaultInit(){return"1"}class Sema{constructor(e,{initFn:t=defaultInit,pauseFn:r,resumeFn:n,capacity:s=10}={}){if(isFn(r)!==isFn(n)){throw new Error("pauseFn and resumeFn must be both set for pausing")}this.nrTokens=e;this.free=new Deque(e);this.waiting=new Deque(s);this.releaseEmitter=new ReleaseEmitter;this.noTokens=t===defaultInit;this.pauseFn=r;this.resumeFn=n;this.paused=false;this.releaseEmitter.on("release",(e=>{const t=this.waiting.shift();if(t){t.resolve(e)}else{if(this.resumeFn&&this.paused){this.paused=false;this.resumeFn()}this.free.push(e)}}));for(let r=0;r<e;r++){this.free.push(t())}}tryAcquire(){return this.free.pop()}async acquire(){let e=this.tryAcquire();if(e!==void 0){return e}return new Promise(((e,t)=>{if(this.pauseFn&&!this.paused){this.paused=true;this.pauseFn()}this.waiting.push({resolve:e,reject:t})}))}release(e){this.releaseEmitter.emit("release",this.noTokens?"1":e)}drain(){const e=new Array(this.nrTokens);for(let t=0;t<this.nrTokens;t++){e[t]=this.acquire()}return Promise.all(e)}nrWaiting(){return this.waiting.length}}t.Sema=Sema;function RateLimit(e,{timeUnit:t=1e3,uniformDistribution:r=false}={}){const n=new Sema(r?1:e);const s=r?t/e:t;return async function rl(){await n.acquire();setTimeout((()=>n.release()),s)}}t.RateLimit=RateLimit},8671:(e,t,r)=>{"use strict";const n=r(3062);const s=r(4898);const o=r(5331);const i=r(168);const braces=(e,t={})=>{let r=[];if(Array.isArray(e)){for(const n of e){const e=braces.create(n,t);if(Array.isArray(e)){r.push(...e)}else{r.push(e)}}}else{r=[].concat(braces.create(e,t))}if(t&&t.expand===true&&t.nodupes===true){r=[...new Set(r)]}return r};braces.parse=(e,t={})=>i(e,t);braces.stringify=(e,t={})=>{if(typeof e==="string"){return n(braces.parse(e,t),t)}return n(e,t)};braces.compile=(e,t={})=>{if(typeof e==="string"){e=braces.parse(e,t)}return s(e,t)};braces.expand=(e,t={})=>{if(typeof e==="string"){e=braces.parse(e,t)}let r=o(e,t);if(t.noempty===true){r=r.filter(Boolean)}if(t.nodupes===true){r=[...new Set(r)]}return r};braces.create=(e,t={})=>{if(e===""||e.length<3){return[e]}return t.expand!==true?braces.compile(e,t):braces.expand(e,t)};e.exports=braces},4898:(e,t,r)=>{"use strict";const n=r(9730);const s=r(2474);const compile=(e,t={})=>{const walk=(e,r={})=>{const o=s.isInvalidBrace(r);const i=e.invalid===true&&t.escapeInvalid===true;const a=o===true||i===true;const c=t.escapeInvalid===true?"\\":"";let u="";if(e.isOpen===true){return c+e.value}if(e.isClose===true){console.log("node.isClose",c,e.value);return c+e.value}if(e.type==="open"){return a?c+e.value:"("}if(e.type==="close"){return a?c+e.value:")"}if(e.type==="comma"){return e.prev.type==="comma"?"":a?e.value:"|"}if(e.value){return e.value}if(e.nodes&&e.ranges>0){const r=s.reduce(e.nodes);const o=n(...r,{...t,wrap:false,toRegex:true,strictZeros:true});if(o.length!==0){return r.length>1&&o.length>1?`(${o})`:o}}if(e.nodes){for(const t of e.nodes){u+=walk(t,e)}}return u};return walk(e)};e.exports=compile},1778:e=>{"use strict";e.exports={MAX_LENGTH:1e4,CHAR_0:"0",CHAR_9:"9",CHAR_UPPERCASE_A:"A",CHAR_LOWERCASE_A:"a",CHAR_UPPERCASE_Z:"Z",CHAR_LOWERCASE_Z:"z",CHAR_LEFT_PARENTHESES:"(",CHAR_RIGHT_PARENTHESES:")",CHAR_ASTERISK:"*",CHAR_AMPERSAND:"&",CHAR_AT:"@",CHAR_BACKSLASH:"\\",CHAR_BACKTICK:"`",CHAR_CARRIAGE_RETURN:"\r",CHAR_CIRCUMFLEX_ACCENT:"^",CHAR_COLON:":",CHAR_COMMA:",",CHAR_DOLLAR:"$",CHAR_DOT:".",CHAR_DOUBLE_QUOTE:'"',CHAR_EQUAL:"=",CHAR_EXCLAMATION_MARK:"!",CHAR_FORM_FEED:"\f",CHAR_FORWARD_SLASH:"/",CHAR_HASH:"#",CHAR_HYPHEN_MINUS:"-",CHAR_LEFT_ANGLE_BRACKET:"<",CHAR_LEFT_CURLY_BRACE:"{",CHAR_LEFT_SQUARE_BRACKET:"[",CHAR_LINE_FEED:"\n",CHAR_NO_BREAK_SPACE:" ",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:"\t",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\ufeff"}},5331:(e,t,r)=>{"use strict";const n=r(9730);const s=r(3062);const o=r(2474);const append=(e="",t="",r=false)=>{const n=[];e=[].concat(e);t=[].concat(t);if(!t.length)return e;if(!e.length){return r?o.flatten(t).map((e=>`{${e}}`)):t}for(const s of e){if(Array.isArray(s)){for(const e of s){n.push(append(e,t,r))}}else{for(let e of t){if(r===true&&typeof e==="string")e=`{${e}}`;n.push(Array.isArray(e)?append(s,e,r):s+e)}}}return o.flatten(n)};const expand=(e,t={})=>{const r=t.rangeLimit===undefined?1e3:t.rangeLimit;const walk=(e,i={})=>{e.queue=[];let a=i;let c=i.queue;while(a.type!=="brace"&&a.type!=="root"&&a.parent){a=a.parent;c=a.queue}if(e.invalid||e.dollar){c.push(append(c.pop(),s(e,t)));return}if(e.type==="brace"&&e.invalid!==true&&e.nodes.length===2){c.push(append(c.pop(),["{}"]));return}if(e.nodes&&e.ranges>0){const i=o.reduce(e.nodes);if(o.exceedsLimit(...i,t.step,r)){throw new RangeError("expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.")}let a=n(...i,t);if(a.length===0){a=s(e,t)}c.push(append(c.pop(),a));e.nodes=[];return}const u=o.encloseBrace(e);let l=e.queue;let p=e;while(p.type!=="brace"&&p.type!=="root"&&p.parent){p=p.parent;l=p.queue}for(let t=0;t<e.nodes.length;t++){const r=e.nodes[t];if(r.type==="comma"&&e.type==="brace"){if(t===1)l.push("");l.push("");continue}if(r.type==="close"){c.push(append(c.pop(),l,u));continue}if(r.value&&r.type!=="open"){l.push(append(l.pop(),r.value));continue}if(r.nodes){walk(r,e)}}return l};return o.flatten(walk(e))};e.exports=expand},168:(e,t,r)=>{"use strict";const n=r(3062);const{MAX_LENGTH:s,CHAR_BACKSLASH:o,CHAR_BACKTICK:i,CHAR_COMMA:a,CHAR_DOT:c,CHAR_LEFT_PARENTHESES:u,CHAR_RIGHT_PARENTHESES:l,CHAR_LEFT_CURLY_BRACE:p,CHAR_RIGHT_CURLY_BRACE:d,CHAR_LEFT_SQUARE_BRACKET:f,CHAR_RIGHT_SQUARE_BRACKET:h,CHAR_DOUBLE_QUOTE:g,CHAR_SINGLE_QUOTE:m,CHAR_NO_BREAK_SPACE:y,CHAR_ZERO_WIDTH_NOBREAK_SPACE:v}=r(1778);const parse=(e,t={})=>{if(typeof e!=="string"){throw new TypeError("Expected a string")}const r=t||{};const $=typeof r.maxLength==="number"?Math.min(s,r.maxLength):s;if(e.length>$){throw new SyntaxError(`Input length (${e.length}), exceeds max characters (${$})`)}const b={type:"root",input:e,nodes:[]};const w=[b];let _=b;let S=b;let A=0;const j=e.length;let R=0;let x=0;let k;const advance=()=>e[R++];const push=e=>{if(e.type==="text"&&S.type==="dot"){S.type="text"}if(S&&S.type==="text"&&e.type==="text"){S.value+=e.value;return}_.nodes.push(e);e.parent=_;e.prev=S;S=e;return e};push({type:"bos"});while(R<j){_=w[w.length-1];k=advance();if(k===v||k===y){continue}if(k===o){push({type:"text",value:(t.keepEscaping?k:"")+advance()});continue}if(k===h){push({type:"text",value:"\\"+k});continue}if(k===f){A++;let e;while(R<j&&(e=advance())){k+=e;if(e===f){A++;continue}if(e===o){k+=advance();continue}if(e===h){A--;if(A===0){break}}}push({type:"text",value:k});continue}if(k===u){_=push({type:"paren",nodes:[]});w.push(_);push({type:"text",value:k});continue}if(k===l){if(_.type!=="paren"){push({type:"text",value:k});continue}_=w.pop();push({type:"text",value:k});_=w[w.length-1];continue}if(k===g||k===m||k===i){const e=k;let r;if(t.keepQuotes!==true){k=""}while(R<j&&(r=advance())){if(r===o){k+=r+advance();continue}if(r===e){if(t.keepQuotes===true)k+=r;break}k+=r}push({type:"text",value:k});continue}if(k===p){x++;const e=S.value&&S.value.slice(-1)==="$"||_.dollar===true;const t={type:"brace",open:true,close:false,dollar:e,depth:x,commas:0,ranges:0,nodes:[]};_=push(t);w.push(_);push({type:"open",value:k});continue}if(k===d){if(_.type!=="brace"){push({type:"text",value:k});continue}const e="close";_=w.pop();_.close=true;push({type:e,value:k});x--;_=w[w.length-1];continue}if(k===a&&x>0){if(_.ranges>0){_.ranges=0;const e=_.nodes.shift();_.nodes=[e,{type:"text",value:n(_)}]}push({type:"comma",value:k});_.commas++;continue}if(k===c&&x>0&&_.commas===0){const e=_.nodes;if(x===0||e.length===0){push({type:"text",value:k});continue}if(S.type==="dot"){_.range=[];S.value+=k;S.type="range";if(_.nodes.length!==3&&_.nodes.length!==5){_.invalid=true;_.ranges=0;S.type="text";continue}_.ranges++;_.args=[];continue}if(S.type==="range"){e.pop();const t=e[e.length-1];t.value+=S.value+k;S=t;_.ranges--;continue}push({type:"dot",value:k});continue}push({type:"text",value:k})}do{_=w.pop();if(_.type!=="root"){_.nodes.forEach((e=>{if(!e.nodes){if(e.type==="open")e.isOpen=true;if(e.type==="close")e.isClose=true;if(!e.nodes)e.type="text";e.invalid=true}}));const e=w[w.length-1];const t=e.nodes.indexOf(_);e.nodes.splice(t,1,..._.nodes)}}while(w.length>0);push({type:"eos"});return b};e.exports=parse},3062:(e,t,r)=>{"use strict";const n=r(2474);e.exports=(e,t={})=>{const stringify=(e,r={})=>{const s=t.escapeInvalid&&n.isInvalidBrace(r);const o=e.invalid===true&&t.escapeInvalid===true;let i="";if(e.value){if((s||o)&&n.isOpenOrClose(e)){return"\\"+e.value}return e.value}if(e.value){return e.value}if(e.nodes){for(const t of e.nodes){i+=stringify(t)}}return i};return stringify(e)}},2474:(e,t)=>{"use strict";t.isInteger=e=>{if(typeof e==="number"){return Number.isInteger(e)}if(typeof e==="string"&&e.trim()!==""){return Number.isInteger(Number(e))}return false};t.find=(e,t)=>e.nodes.find((e=>e.type===t));t.exceedsLimit=(e,r,n=1,s)=>{if(s===false)return false;if(!t.isInteger(e)||!t.isInteger(r))return false;return(Number(r)-Number(e))/Number(n)>=s};t.escapeNode=(e,t=0,r)=>{const n=e.nodes[t];if(!n)return;if(r&&n.type===r||n.type==="open"||n.type==="close"){if(n.escaped!==true){n.value="\\"+n.value;n.escaped=true}}};t.encloseBrace=e=>{if(e.type!=="brace")return false;if(e.commas>>0+e.ranges>>0===0){e.invalid=true;return true}return false};t.isInvalidBrace=e=>{if(e.type!=="brace")return false;if(e.invalid===true||e.dollar)return true;if(e.commas>>0+e.ranges>>0===0){e.invalid=true;return true}if(e.open!==true||e.close!==true){e.invalid=true;return true}return false};t.isOpenOrClose=e=>{if(e.type==="open"||e.type==="close"){return true}return e.open===true||e.close===true};t.reduce=e=>e.reduce(((e,t)=>{if(t.type==="text")e.push(t.value);if(t.type==="range")t.type="text";return e}),[]);t.flatten=(...e)=>{const t=[];const flat=e=>{for(let r=0;r<e.length;r++){const n=e[r];if(Array.isArray(n)){flat(n);continue}if(n!==undefined){t.push(n)}}return t};flat(e);return t}},3845:(e,t,r)=>{"use strict";var n=r(7596);var s=r(6125);var o=s(n("String.prototype.indexOf"));e.exports=function callBoundIntrinsic(e,t){var r=n(e,!!t);if(typeof r==="function"&&o(e,".prototype.")>-1){return s(r)}return r}},6125:(e,t,r)=>{"use strict";var n=r(7797);var s=r(7596);var o=r(3798);var i=r(4785);var a=s("%Function.prototype.apply%");var c=s("%Function.prototype.call%");var u=s("%Reflect.apply%",true)||n.call(c,a);var l=r(2072);var p=s("%Math.max%");e.exports=function callBind(e){if(typeof e!=="function"){throw new i("a function is required")}var t=u(n,c,arguments);return o(t,1+p(0,e.length-(arguments.length-1)),true)};var d=function applyBind(){return u(n,a,arguments)};if(l){l(e.exports,"apply",{value:d})}else{e.exports.apply=d}},1542:(e,t,r)=>{"use strict";if(r(7914).major>=4){e.exports=r(1994)}else{e.exports=r(9304)}},1083:e=>{"use strict";function _classCallCheck(e,t){if(!(e instanceof t)){throw new TypeError("Cannot call a class as a function")}}function _possibleConstructorReturn(e,t){if(!e){throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}return t&&(typeof t==="object"||typeof t==="function")?t:e}function _inherits(e,t){if(typeof t!=="function"&&t!==null){throw new TypeError("Super expression must either be null or a function, not "+typeof t)}e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:false,writable:true,configurable:true}});if(t)Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t}var t=function(e){_inherits(ChildProcessError,e);function ChildProcessError(e,t,r,n,s){_classCallCheck(this,ChildProcessError);var o=_possibleConstructorReturn(this,(ChildProcessError.__proto__||Object.getPrototypeOf(ChildProcessError)).call(this,e));Error.captureStackTrace(o,o.constructor);o.name=o.constructor.name;o.code=t;o.childProcess=r;o.stdout=n;o.stderr=s;return o}return ChildProcessError}(Error);e.exports=t},560:(e,t,r)=>{"use strict";var n=function(){function defineProperties(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||false;n.configurable=true;if("value"in n)n.writable=true;Object.defineProperty(e,n.key,n)}}return function(e,t,r){if(t)defineProperties(e.prototype,t);if(r)defineProperties(e,r);return e}}();var s=function get(e,t,r){if(e===null)e=Function.prototype;var n=Object.getOwnPropertyDescriptor(e,t);if(n===undefined){var s=Object.getPrototypeOf(e);if(s===null){return undefined}else{return get(s,t,r)}}else if("value"in n){return n.value}else{var o=n.get;if(o===undefined){return undefined}return o.call(r)}};function _classCallCheck(e,t){if(!(e instanceof t)){throw new TypeError("Cannot call a class as a function")}}function _possibleConstructorReturn(e,t){if(!e){throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}return t&&(typeof t==="object"||typeof t==="function")?t:e}function _inherits(e,t){if(typeof t!=="function"&&t!==null){throw new TypeError("Super expression must either be null or a function, not "+typeof t)}e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:false,writable:true,configurable:true}});if(t)Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t}var o;if(r(7914).major>=4){o=global.Promise}else{o=r(2799)}var i=function(e){_inherits(ChildProcessPromise,e);function ChildProcessPromise(e){_classCallCheck(this,ChildProcessPromise);var t;var r;var n=_possibleConstructorReturn(this,(ChildProcessPromise.__proto__||Object.getPrototypeOf(ChildProcessPromise)).call(this,(function(n,s){t=n;r=s;if(e){e(t,r)}})));n._cpResolve=t;n._cpReject=r;n.childProcess=undefined;return n}n(ChildProcessPromise,[{key:"progress",value:function progress(e){var t=this;process.nextTick((function(){e(t.childProcess)}));return this}},{key:"then",value:function then(e,t){var r=s(ChildProcessPromise.prototype.__proto__||Object.getPrototypeOf(ChildProcessPromise.prototype),"then",this).call(this,e,t);r.childProcess=this.childProcess;return r}},{key:"catch",value:function _catch(e){var t=s(ChildProcessPromise.prototype.__proto__||Object.getPrototypeOf(ChildProcessPromise.prototype),"catch",this).call(this,e);t.childProcess=this.childProcess;return t}},{key:"done",value:function done(){this.catch((function(e){process.nextTick((function(){throw e}))}))}}]);return ChildProcessPromise}(o);i.prototype.fail=i.prototype.catch;e.exports=i},9304:(e,t,r)=>{"use strict";var n=r(5317);var s=r(349);var o=r(560);var i=r(1083);var a=Array.prototype.slice;function doExec(e,t){var r;var s=new o;var c=s._cpReject;var u=s._cpResolve;var l=a.call(t,0);l.push(callback);r=n[e].apply(n,l);function callback(e,s,o){if(e){var a=t[0]+(Array.isArray(t[1])?" "+t[1].join(" "):"");e.message+=" `"+a+"` (exited with error code "+e.code+")";e.stdout=s;e.stderr=o;var l=new i(e.message,e.code,n,s,o);c(l)}else{u({childProcess:r,stdout:s,stderr:o})}}s.childProcess=r;return s}function exec(){return doExec("exec",arguments)}function execFile(){return doExec("execFile",arguments)}function doSpawn(e,t,r,n){var s={};var a;var c=new o;var u=c._cpReject;var l=c._cpResolve;var p=n&&n.successfulExitCodes||[0];a=e(t,r,n);var d=false;var f=false;var h=n&&n.capture;if(h){for(var g=0,m=h.length;g<m;g++){var y=h[g];if(y==="stdout"){d=true}else if(y==="stderr"){f=true}}}s.childProcess=a;if(d){s.stdout="";a.stdout.on("data",(function(e){s.stdout+=e}))}if(f){s.stderr="";a.stderr.on("data",(function(e){s.stderr+=e}))}a.on("error",u);a.on("close",(function(e){if(p.indexOf(e)===-1){var n=t+(r.length?" "+r.join(" "):"");var o="`"+n+"` failed with code "+e;var c=new i(o,e,a);if(f){c.stderr=s.stderr.toString()}if(d){c.stdout=s.stdout.toString()}u(c)}else{s.code=e;l(s)}}));c.childProcess=a;return c}function spawn(e,t,r){return doSpawn(s,e,t,r)}function fork(e,t,r){return doSpawn(n.fork,e,t,r)}t.exec=exec;t.execFile=execFile;t.spawn=spawn;t.fork=fork},1793:e=>{"use strict";class ChildProcessError extends Error{constructor(e,t,r,n,s){super(e);Error.captureStackTrace(this,this.constructor);this.name=this.constructor.name;this.code=t;this.childProcess=r;this.stdout=n;this.stderr=s}}e.exports=ChildProcessError},7802:(e,t,r)=>{"use strict";var n;if(r(7914).major>=4){n=global.Promise}else{n=r(2799)}class ChildProcessPromise extends n{constructor(e){var t;var r;super(((n,s)=>{t=n;r=s;if(e){e(t,r)}}));this._cpResolve=t;this._cpReject=r;this.childProcess=undefined}progress(e){process.nextTick((()=>{e(this.childProcess)}));return this}then(e,t){var r=super.then(e,t);r.childProcess=this.childProcess;return r}catch(e){var t=super.catch(e);t.childProcess=this.childProcess;return t}done(){this.catch((e=>{process.nextTick((()=>{throw e}))}))}}ChildProcessPromise.prototype.fail=ChildProcessPromise.prototype.catch;e.exports=ChildProcessPromise},1994:(e,t,r)=>{"use strict";var n=r(5317);var s=r(349);var o=r(7802);var i=r(1793);var a=Array.prototype.slice;function doExec(e,t){var r;var s=new o;var c=s._cpReject;var u=s._cpResolve;var l=a.call(t,0);l.push(callback);r=n[e].apply(n,l);function callback(e,s,o){if(e){var a=t[0]+(Array.isArray(t[1])?" "+t[1].join(" "):"");e.message+=" `"+a+"` (exited with error code "+e.code+")";e.stdout=s;e.stderr=o;var l=new i(e.message,e.code,n,s,o);c(l)}else{u({childProcess:r,stdout:s,stderr:o})}}s.childProcess=r;return s}function exec(){return doExec("exec",arguments)}function execFile(){return doExec("execFile",arguments)}function doSpawn(e,t,r,n){var s={};var a;var c=new o;var u=c._cpReject;var l=c._cpResolve;var p=n&&n.successfulExitCodes||[0];a=e(t,r,n);var d=false;var f=false;var h=n&&n.capture;if(h){for(var g=0,m=h.length;g<m;g++){var y=h[g];if(y==="stdout"){d=true}else if(y==="stderr"){f=true}}}s.childProcess=a;if(d){s.stdout="";a.stdout.on("data",(function(e){s.stdout+=e}))}if(f){s.stderr="";a.stderr.on("data",(function(e){s.stderr+=e}))}a.on("error",u);a.on("close",(function(e){if(p.indexOf(e)===-1){var n=t+(r.length?" "+r.join(" "):"");var o="`"+n+"` failed with code "+e;var c=new i(o,e,a);if(f){c.stderr=s.stderr.toString()}if(d){c.stdout=s.stdout.toString()}u(c)}else{s.code=e;l(s)}}));c.childProcess=a;return c}function spawn(e,t,r){return doSpawn(s,e,t,r)}function fork(e,t,r){return doSpawn(n.fork,e,t,r)}t.exec=exec;t.execFile=execFile;t.spawn=spawn;t.fork=fork},349:(e,t,r)=>{"use strict";var n=r(5317);var s=r(5386);var o=r(232);var i=n.spawnSync;function spawn(e,t,r){var i;var a;i=s(e,t,r);a=n.spawn(i.command,i.args,i.options);o.hookChildProcess(a,i);return a}function spawnSync(e,t,n){var a;var c;if(!i){try{i=r(8426)}catch(e){throw new Error("In order to use spawnSync on node 0.10 or older, you must "+"install spawn-sync:\n\n"+" npm install spawn-sync --save")}}a=s(e,t,n);c=i(a.command,a.args,a.options);c.error=c.error||o.verifyENOENTSync(c.status,a);return c}e.exports=spawn;e.exports.spawn=spawn;e.exports.sync=spawnSync;e.exports._parse=s;e.exports._enoent=o},232:(e,t,r)=>{"use strict";var n=process.platform==="win32";var s=r(6172);var o=process.version.indexOf("v0.10.")===0;function notFoundError(e,t){var r;r=new Error(t+" "+e+" ENOENT");r.code=r.errno="ENOENT";r.syscall=t+" "+e;return r}function hookChildProcess(e,t){var r;if(!n){return}r=e.emit;e.emit=function(n,s){var o;if(n==="exit"){o=verifyENOENT(s,t,"spawn");if(o){return r.call(e,"error",o)}}return r.apply(e,arguments)}}function verifyENOENT(e,t){if(n&&e===1&&!t.file){return notFoundError(t.original,"spawn")}return null}function verifyENOENTSync(e,t){if(n&&e===1&&!t.file){return notFoundError(t.original,"spawnSync")}if(o&&e===-1){t.file=n?t.file:s(t.original);if(!t.file){return notFoundError(t.original,"spawnSync")}}return null}e.exports.hookChildProcess=hookChildProcess;e.exports.verifyENOENT=verifyENOENT;e.exports.verifyENOENTSync=verifyENOENTSync;e.exports.notFoundError=notFoundError},4269:e=>{"use strict";e.exports=function(){if(process.platform!=="win32"){return false}var e=process.version.substr(1).split(".").map((function(e){return parseInt(e,10)}));return e[0]===0&&e[1]<12}()},5386:(e,t,r)=>{"use strict";var n=r(9896);var s=r(9939);var o=r(6172);var i=r(4269);var a=process.platform==="win32";var c=new s({max:50,maxAge:30*1e3});function readShebang(e){var t;var r;var s;var o;if(c.has(e)){return c.get(e)}t=new Buffer(150);try{r=n.openSync(e,"r");n.readSync(r,t,0,150,0);n.closeSync(r)}catch(e){}s=t.toString().trim().match(/#!(.+)/i);if(s){o=s[1].replace(/\/usr\/bin\/env\s+/i,"")}c.set(e,o);return o}function escapeArg(e,t){e=""+e;if(!t){e=e.replace(/([\(\)%!\^<>&|;,"'\s])/g,"^$1")}else{e=e.replace(/(\\*)"/g,'$1$1\\"');e=e.replace(/(\\*)$/,"$1$1");e='"'+e+'"'}return e}function escapeCommand(e){return/^[a-z0-9_-]+$/i.test(e)?e:escapeArg(e,true)}function requiresShell(e){return!/\.(?:com|exe)$/i.test(e)}function parse(e,t,r){var n;var s;var c;var u;var l;if(t&&!Array.isArray(t)){r=t;t=null}t=t?t.slice(0):[];r=r||{};u=e;if(a){c=o(e);c=c||o(e,true);n=c&&readShebang(c);l=r.shell||i;if(n){t.unshift(c);e=n;l=l||requiresShell(o(n)||o(n,true))}else{l=l||requiresShell(c)}if(l){s=e!=="echo";e=escapeCommand(e);t=t.map((function(e){return escapeArg(e,s)}));t=["/s","/c",'"'+e+(t.length?" "+t.join(" "):"")+'"'];e=process.env.comspec||"cmd.exe";r.windowsVerbatimArguments=true}}return{command:e,args:t,options:r,file:c,original:u}}e.exports=parse},6172:(e,t,r)=>{"use strict";var n=r(6928);var s=r(2871);var o=r(9939);var i=new o({max:50,maxAge:30*1e3});function resolveCommand(e,t){var r;t=!!t;r=i.get(e+"!"+t);if(i.has(e)){return i.get(e)}try{r=!t?s.sync(e):s.sync(e,{pathExt:n.delimiter+(process.env.PATHEXT||"")})}catch(e){}i.set(e+"!"+t,r);return r}e.exports=resolveCommand},2071:(e,t,r)=>{"use strict";var n=r(2072);var s=r(9546);var o=r(4785);var i=r(5583);e.exports=function defineDataProperty(e,t,r){if(!e||typeof e!=="object"&&typeof e!=="function"){throw new o("`obj` must be an object or a function`")}if(typeof t!=="string"&&typeof t!=="symbol"){throw new o("`property` must be a string or a symbol`")}if(arguments.length>3&&typeof arguments[3]!=="boolean"&&arguments[3]!==null){throw new o("`nonEnumerable`, if provided, must be a boolean or null")}if(arguments.length>4&&typeof arguments[4]!=="boolean"&&arguments[4]!==null){throw new o("`nonWritable`, if provided, must be a boolean or null")}if(arguments.length>5&&typeof arguments[5]!=="boolean"&&arguments[5]!==null){throw new o("`nonConfigurable`, if provided, must be a boolean or null")}if(arguments.length>6&&typeof arguments[6]!=="boolean"){throw new o("`loose`, if provided, must be a boolean")}var a=arguments.length>3?arguments[3]:null;var c=arguments.length>4?arguments[4]:null;var u=arguments.length>5?arguments[5]:null;var l=arguments.length>6?arguments[6]:false;var p=!!i&&i(e,t);if(n){n(e,t,{configurable:u===null&&p?p.configurable:!u,enumerable:a===null&&p?p.enumerable:!a,value:r,writable:c===null&&p?p.writable:!c})}else if(l||!a&&!c&&!u){e[t]=r}else{throw new s("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")}}},2072:(e,t,r)=>{"use strict";var n=r(7596);var s=n("%Object.defineProperty%",true)||false;if(s){try{s({},"a",{value:1})}catch(e){s=false}}e.exports=s},1247:e=>{"use strict";e.exports=EvalError},6621:e=>{"use strict";e.exports=Error},6136:e=>{"use strict";e.exports=RangeError},252:e=>{"use strict";e.exports=ReferenceError},9546:e=>{"use strict";e.exports=SyntaxError},4785:e=>{"use strict";e.exports=TypeError},1223:e=>{"use strict";e.exports=URIError},9730:(e,t,r)=>{"use strict";
1
+ (()=>{var __webpack_modules__={403:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.gitConfigSet=t.gitConfigGet=void 0;const n=r(1542);const argsJoin=e=>e.filter(Boolean).join(" ");async function gitConfigGet(e,{location:t}={}){const{stdout:r}=await(0,n.exec)(`git config --get ${argsJoin([t?`--${t}`:undefined])} ${e}`);return r.trim()}t.gitConfigGet=gitConfigGet;const gitConfigSet=(e,t,{location:r,comment:s}={})=>(0,n.exec)(`git config --set ${argsJoin([r?`--${r}`:undefined,s?`--comment=${s}`:undefined])} ${e} ${t}`);t.gitConfigSet=gitConfigSet},6884:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.gitProjectInformation=t.getGitRemoteHostAndPath=t.getProjectRootPath=void 0;const n=r(403);const s=r(1542);const getProjectRootPath=async()=>{const{stdout:e}=await(0,s.exec)(`git rev-parse --show-toplevel`);return e.trim()};t.getProjectRootPath=getProjectRootPath;const getGitRemoteHostAndPath=async(e="origin")=>{var t;const r=await(0,n.gitConfigGet)(`remote.${e}.url`);const s=/(https:\/\/|git@)([^:/]+)[:/]([^.]*)(\.git)?/;const o=(t=r.match(s))!==null&&t!==void 0?t:[];const[,,i,a]=o;if(!(i===null||i===void 0?void 0:i.length)||!(a===null||a===void 0?void 0:a.length)){throw new Error(`Failed to parse git remote hostname and path from git configs remote.${e}.url! ${r}`)}return{gitRemoteHost:i,gitRemotePath:a}};t.getGitRemoteHostAndPath=getGitRemoteHostAndPath;const gitProjectInformation=async()=>{const[{gitRemoteHost:e,gitRemotePath:r},n]=await Promise.all([(0,t.getGitRemoteHostAndPath)(),(0,t.getProjectRootPath)()]);return{gitRemoteHost:e,gitRemotePath:r,projectRootPath:n}};t.gitProjectInformation=gitProjectInformation},3961:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.parseNpmPublishArgs=t.npmPublishJob=t.DEFAULT_NPM_REGISTRY=void 0;const n=r(5317);const s=r(1943);const o=r(6928);const i=r(1535);t.DEFAULT_NPM_REGISTRY="https://registry.npmjs.org/";const readCiContext=e=>{var t,r,n,s;const o=process.env;if(o.GITLAB_CI==="true"){return{ciTag:o.CI_COMMIT_TAG||null,refSlug:(t=o.CI_COMMIT_REF_SLUG)!==null&&t!==void 0?t:"",shortSha:(r=o.CI_COMMIT_SHORT_SHA)!==null&&r!==void 0?r:""}}if(o.GITHUB_ACTIONS==="true"){return{ciTag:o.GITHUB_REF_TYPE==="tag"?(n=o.GITHUB_REF_NAME)!==null&&n!==void 0?n:null:null,refSlug:(0,i.slugifyRef)(o.GITHUB_HEAD_REF||o.GITHUB_REF_NAME||""),shortSha:((s=o.GITHUB_SHA)!==null&&s!==void 0?s:"").slice(0,8)}}throw new Error(`publish npm for "${e.dir}" must run in a gitlab or github CI job (no CI provider detected)`)};const setPackageVersion=async(e,t)=>{const r=(0,o.join)(e,"package.json");const n=JSON.parse(await(0,s.readFile)(r,"utf-8"));n.version=t;await(0,s.writeFile)(r,JSON.stringify(n,null,2)+"\n");return n.name};const writeNpmrc=async(e,t)=>{const r=t.replace(/^https?:/,"").replace(/\/?$/,"/");const n=(0,o.resolve)(e,".npmrc");await(0,s.writeFile)(n,`${r}:_authToken=\${NPM_TOKEN}\n`);return n};const hasOidcCredentials=()=>!!process.env.ACTIONS_ID_TOKEN_REQUEST_URL&&!!process.env.ACTIONS_ID_TOKEN_REQUEST_TOKEN;const npmPublish=(e,t,r)=>new Promise(((s,o)=>{const i=(0,n.spawn)("npm",["publish",...r],{cwd:e,stdio:"inherit",env:{...process.env,...t?{NPM_CONFIG_USERCONFIG:t}:{}}});i.on("error",o);i.on("exit",(e=>e===0?s():o(new Error(`npm publish exited with ${e}`))))}));const npmPublishJob=async e=>{var r,n;const s=hasOidcCredentials();if(!s&&!process.env.NPM_TOKEN){throw new Error("NPM_TOKEN is not set — configure it as a catladder secret for this component, or publish from a workflow registered as a trusted publisher on npm")}const o=(r=e.registry)!==null&&r!==void 0?r:t.DEFAULT_NPM_REGISTRY;const a=(0,i.computeNpmPublishPlan)({envType:e.envType,distTagOverride:e.distTag,...readCiContext(e)});const c=await setPackageVersion(e.dir,a.version);const u=s&&!process.env.NPM_TOKEN?undefined:await writeNpmrc(e.dir,o);console.log(`publishing ${c}@${a.version} (dist-tag ${a.distTag}) to ${o}${u?"":" via trusted publishing (OIDC)"}`);await npmPublish(e.dir,u,["--tag",a.distTag,"--access",(n=e.access)!==null&&n!==void 0?n:"public","--registry",o,"--workspaces=false"]);console.log(`published ${c}@${a.version} 🚀`)};t.npmPublishJob=npmPublishJob;const parseNpmPublishArgs=e=>{const t={};for(let r=0;r<e.length;r+=2){const n=e[r];const s=e[r+1];if(!(n===null||n===void 0?void 0:n.startsWith("--"))||s===undefined)return null;t[n.slice(2)]=s}const{dir:r,access:n,registry:s}=t;const o=t["env-type"];const i=t["dist-tag"];if(!r||!o)return null;return{dir:r,envType:o,access:n,registry:s,distTag:i}};t.parseNpmPublishArgs=parseNpmPublishArgs},1535:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.slugifyRef=t.computeNpmPublishPlan=t.BRANCH_DIST_TAGS=void 0;t.BRANCH_DIST_TAGS=["next","beta"];const computeNpmPublishPlan=e=>{var r,n;if(e.envType==="prod"||e.envType==="stage"){if(!e.ciTag){throw new Error(`npm publish for env type "${e.envType}" expects a tagged-release pipeline, but no git tag is set`)}return{version:e.ciTag.replace(/^v/,""),distTag:(r=e.distTagOverride)!==null&&r!==void 0?r:"latest"}}return{version:`0.0.0-${e.refSlug}-${e.shortSha}`,distTag:(n=e.distTagOverride)!==null&&n!==void 0?n:t.BRANCH_DIST_TAGS.includes(e.refSlug)?e.refSlug:"canary"}};t.computeNpmPublishPlan=computeNpmPublishPlan;const slugifyRef=e=>e.toLowerCase().replace(/[^0-9a-z]/g,"-").slice(0,63).replace(/^-+|-+$/g,"");t.slugifyRef=slugifyRef},118:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.runChangesetCheck=t.CHANGESET_CHECK_MARKER=void 0;const n=r(4423);t.CHANGESET_CHECK_MARKER="\x3c!-- catladder-changeset-check --\x3e";const runChangesetCheck=({addedFiles:e,pending:r,lastTag:s,requestLabel:o,packageManager:i})=>{const a=e.length>0;const c=[t.CHANGESET_CHECK_MARKER,"## đŸĻ‹ Changeset check",""];if(a){c.push(`✅ This ${o} adds ${e.length} changeset${e.length===1?"":"s"}: ${e.map((e=>`\`${e}\``)).join(", ")}`)}else{c.push(`âš ī¸ **This ${o} adds no changeset.** If the change is user-facing it will be missing from the next release's changelog — add \`.changeset/<name>.md\` (or run \`${i} changeset\`). For docs/chore changes this warning can be ignored.`)}c.push("");if(r.length===0){c.push("No changesets are pending — merging will **not** trigger a release.")}else{const e=(0,n.getNextVersion)(s,(0,n.maxBump)(r.map((e=>e.bump))));c.push(`${r.length} changeset${r.length===1?" is":"s are"} pending after merge — the next release will be **v${e}**${s?` (from ${s})`:" (first release)"}:`,"","<details><summary>Changelog preview</summary>","",(0,n.renderChangelogEntries)(r),"","</details>")}return{addsChangeset:a,markdown:c.join("\n")}};t.runChangesetCheck=runChangesetCheck},291:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.changesetCheckJob=t.CHANGESET_REPORT_FILE=void 0;const n=r(9896);const s=r(1943);const o=r(118);const i=r(7307);const a=r(1177);const c=r(4074);t.CHANGESET_REPORT_FILE="changeset-report.md";const onGithub=()=>process.env.GITHUB_ACTIONS==="true";const detectPackageManager=()=>(0,n.existsSync)("pnpm-lock.yaml")?"pnpm":"yarn";const getAddedChangesetFiles=async()=>{const e=onGithub()?process.env.GITHUB_BASE_REF:process.env.CI_MERGE_REQUEST_TARGET_BRANCH_NAME;if(!e){return null}await(0,a.git)("fetch","--quiet","origin",e);const t=await(0,a.git)("merge-base","HEAD","FETCH_HEAD");const r=await(0,a.git)("diff","--name-only","--diff-filter=A",t,"HEAD");return r.split("\n").filter((e=>e.startsWith(".changeset/")&&e.endsWith(".md")&&!e.toLowerCase().endsWith("readme.md"))).map((e=>e.slice(".changeset/".length)))};const findSticky=e=>e.find((e=>{var t;return(t=e.body)===null||t===void 0?void 0:t.includes(o.CHANGESET_CHECK_MARKER)}));const request=async(e,t)=>{var r;const n=await fetch(e,t);if(!n.ok){throw new Error(`${(r=t.method)!==null&&r!==void 0?r:"GET"} ${e} failed: ${n.status} ${await n.text()}`)}return n};const upsertGithubComment=async e=>{var t,r;const n=process.env.GITHUB_TOKEN;const s=(t=process.env.GITHUB_API_URL)!==null&&t!==void 0?t:"https://api.github.com";const o=process.env.GITHUB_REPOSITORY;const i=parseInt((r=process.env.GITHUB_REF_NAME)!==null&&r!==void 0?r:"");if(!n||!o||!i){console.log("no PR context/token — skipping the PR comment");return}const a={authorization:`Bearer ${n}`,accept:"application/vnd.github+json","content-type":"application/json"};const c=await(await request(`${s}/repos/${o}/issues/${i}/comments?per_page=100`,{headers:a})).json();const u=findSticky(c);if(u){await request(`${s}/repos/${o}/issues/comments/${u.id}`,{method:"PATCH",headers:a,body:JSON.stringify({body:e})})}else{await request(`${s}/repos/${o}/issues/${i}/comments`,{method:"POST",headers:a,body:JSON.stringify({body:e})})}console.log("updated the sticky PR comment")};const upsertGitlabComment=async e=>{const t=process.env.GL_TOKEN;if(!t){console.log("GL_TOKEN is not available in this pipeline — skipping the MR comment (report available in the job log and the exposed artifact)");return}const r=process.env.CI_API_V4_URL;const n=process.env.CI_PROJECT_ID;const s=process.env.CI_MERGE_REQUEST_IID;if(!r||!n||!s){console.log("no MR context — skipping the MR comment");return}const o={"PRIVATE-TOKEN":t,"content-type":"application/json"};const i=`${r}/projects/${n}/merge_requests/${s}/notes`;const a=await(await request(`${i}?per_page=100`,{headers:o})).json();const c=findSticky(a);if(c){await request(`${i}/${c.id}`,{method:"PUT",headers:o,body:JSON.stringify({body:e})})}else{await request(i,{method:"POST",headers:o,body:JSON.stringify({body:e})})}console.log("updated the sticky MR comment")};const changesetCheckJob=async()=>{await(0,a.ensureReleaseHistory)();const e=await(0,i.readPendingChangesets)();const r=await(0,a.getLastReleaseTag)();const n=await getAddedChangesetFiles();const u=(0,o.runChangesetCheck)({addedFiles:n!==null&&n!==void 0?n:[],pending:e,lastTag:r,requestLabel:onGithub()?"pull request":"merge request",packageManager:detectPackageManager()});console.log(u.markdown.replace(`${o.CHANGESET_CHECK_MARKER}\n`,""));await(0,s.writeFile)(t.CHANGESET_REPORT_FILE,u.markdown);try{if(onGithub()){await upsertGithubComment(u.markdown)}else{await upsertGitlabComment(u.markdown)}}catch(e){console.warn(`could not update the sticky comment: ${e}`)}if(n===null){console.log("not running against a merge request — check skipped");return}if(!u.addsChangeset){if(onGithub()){console.log("::warning title=No changeset::this pull request adds no changeset — "+"if the change is user-facing, add one so it appears in the next release's changelog");(0,c.appendStepSummary)(u.markdown.replace(`${o.CHANGESET_CHECK_MARKER}\n`,""))}else{console.log("âš ī¸ this merge request adds no changeset — if the change is user-facing, "+"add one so it appears in the next release's changelog (see the changeset report)")}}};t.changesetCheckJob=changesetCheckJob},4423:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.prependToChangelog=t.renderChangelogEntries=t.getNextVersion=t.maxBump=t.parseChangesetFile=t.BUMPS=void 0;const s=n(r(492));t.BUMPS=["patch","minor","major"];const isBump=e=>t.BUMPS.includes(e);const parseChangesetFile=(e,r)=>{let n;try{n=(0,s.default)(r)}catch(t){throw new Error(`${e}: not a valid changeset (${t instanceof Error?t.message:t})`)}const o=n.releases.map((e=>e.type)).filter(isBump);if(o.length===0){throw new Error(`${e}: changeset declares no effective version bump (major|minor|patch)`)}const i=n.summary.trim();if(i===""){throw new Error(`${e}: changeset has no summary`)}return{fileName:e,bump:(0,t.maxBump)(o),summary:i}};t.parseChangesetFile=parseChangesetFile;const maxBump=e=>e.reduce(((e,r)=>t.BUMPS.indexOf(r)>t.BUMPS.indexOf(e)?r:e));t.maxBump=maxBump;const getNextVersion=(e,t)=>{if(e===null){return"1.0.0"}const r=e.match(/^v(\d+)\.(\d+)\.(\d+)$/);if(!r){throw new Error(`last release tag "${e}" is not of the form vX.Y.Z — cannot derive the next version`)}const[n,s,o]=r.slice(1).map(Number);switch(t){case"major":return`${n+1}.0.0`;case"minor":return`${n}.${s+1}.0`;case"patch":return`${n}.${s}.${o+1}`}};t.getNextVersion=getNextVersion;const o={major:"Major Changes",minor:"Minor Changes",patch:"Patch Changes"};const renderChangelogEntries=e=>[...t.BUMPS].reverse().map((t=>{const r=e.filter((e=>e.bump===t));if(r.length===0)return null;return[`### ${o[t]}`,"",...r.map((e=>`- ${e.summary.replace(/\r?\n/g,"\n ")}`))].join("\n")})).filter((e=>e!==null)).join("\n\n");t.renderChangelogEntries=renderChangelogEntries;const i="# Changelog";const prependToChangelog=(e,t,r,n)=>{const s=`## ${t} (${r})\n\n${n}\n`;const o=(e!==null&&e!==void 0?e:"").replace(new RegExp(`^${i}\\s*\\n`),"").trim();return[i,"",s+(o?"\n"+o+"\n":"")].join("\n")};t.prependToChangelog=prependToChangelog},7307:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.changesetsReleaseJob=t.dispatchTaggedReleaseWorkflow=t.readPendingChangesets=void 0;const n=r(9896);const s=r(1943);const o=r(6928);const i=r(4423);const a=r(4023);const c=r(1177);const u=r(881);const l=r(4074);const p=".changeset";const d="CHANGELOG.md";const f="catladder-release.yml";const readPendingChangesets=async()=>{const e=await(0,s.readdir)(p).catch((()=>[]));const t=e.filter((e=>e.endsWith(".md")&&e.toLowerCase()!=="readme.md"));return Promise.all(t.map((async e=>(0,i.parseChangesetFile)(e,await(0,s.readFile)((0,o.join)(p,e),"utf-8")))))};t.readPendingChangesets=readPendingChangesets;const ensureGitIdentity=async()=>{const e=await(0,c.git)("config","user.email").catch((()=>""));if(e!=="")return;const t=process.env.GITHUB_ACTIONS==="true";await(0,c.git)("config","user.name",t?"github-actions[bot]":"catladder");await(0,c.git)("config","user.email",t?"41898282+github-actions[bot]@users.noreply.github.com":"catladder-release@panter.ch")};const requireEnv=e=>{const t=process.env[e];if(!t){throw new Error(`${e} is not set — cannot push the release`)}return t};const pushCommitAndTag=async e=>{var t;if(process.env.GITHUB_ACTIONS==="true"){const r=requireEnv("GITHUB_REF_NAME");const n=[`HEAD:refs/heads/${r}`,e];const s=(0,a.getReleaseDeployKey)();if(s){await(0,a.pushWithDeployKey)(s,n);return}try{await(0,c.git)("push","--atomic","origin",...n)}catch(e){if(/GH006|GH013|protected branch|rule violations/i.test(`${(t=e===null||e===void 0?void 0:e.message)!==null&&t!==void 0?t:e}`)){throw new Error(`pushing the release to '${r}' was rejected by its branch protection:\n`+`${e.message}\n`+`The workflow token cannot bypass a required status check on '${r}'. `+`Run \`catladder project setup\` to provision the release deploy key `+`(${a.RELEASE_DEPLOY_KEY_ENV} secret + ruleset bypass), then rerun this job.`)}throw e}return}const r=requireEnv("GL_TOKEN");const n=requireEnv("CI_SERVER_HOST");const s=requireEnv("CI_PROJECT_PATH");const o=requireEnv("CI_COMMIT_BRANCH");const i=`https://oauth2:${r}@${n}/${s}.git`;await(0,c.git)("push","--atomic",i,`HEAD:refs/heads/${o}`,e)};const dispatchTaggedReleaseWorkflow=async e=>{var t;const r=(t=process.env.GITHUB_API_URL)!==null&&t!==void 0?t:"https://api.github.com";const n=requireEnv("GITHUB_REPOSITORY");const s=requireEnv("GITHUB_TOKEN");const o=await fetch(`${r}/repos/${n}/actions/workflows/${f}/dispatches`,{method:"POST",headers:{authorization:`Bearer ${s}`,accept:"application/vnd.github+json"},body:JSON.stringify({ref:e})});if(!o.ok){throw new Error(`dispatching ${f} for ${e} failed: ${o.status} ${await o.text()}`)}console.log(`dispatched ${f} for ${e}`)};t.dispatchTaggedReleaseWorkflow=dispatchTaggedReleaseWorkflow;const h={fileName:"",bump:"patch",summary:"Forced release without pending changesets."};const changesetsReleaseJob=async()=>{const e=await(0,t.readPendingChangesets)();const r=e.length===0&&process.env.CATLADDER_FORCE_RELEASE==="true";if(e.length===0&&!r){console.log(`no changesets found in ${p}/ — nothing to release`);console.log(`add one with \`${(0,n.existsSync)("pnpm-lock.yaml")?"pnpm":"yarn"} changeset\` (or write .changeset/<name>.md by hand) and merge it to release`);console.log("to release anyway (patch bump), run the force release job instead");(0,l.appendStepSummary)(`â„šī¸ **Nothing released** — no pending changesets in \`${p}/\`. `+"Merge a changeset and release again, or force the release for a patch bump.");return}const a=r?[h]:e;if(r){console.log("no changesets pending — forced release, bumping a patch")}await(0,c.ensureReleaseHistory)();const f=await(0,c.getLastReleaseTag)();const g=(0,i.getNextVersion)(f,(0,i.maxBump)(a.map((e=>e.bump))));const m=`v${g}`;console.log(`releasing ${m} (${f!==null&&f!==void 0?f:"first release"} + ${a.length} changeset(s))`);const y=(0,i.renderChangelogEntries)(a);const v=await(0,s.readFile)(d,"utf-8").catch((()=>null));const $=(new Date).toISOString().slice(0,10);await(0,s.writeFile)(d,(0,i.prependToChangelog)(v,g,$,y));await Promise.all(e.map((e=>(0,s.rm)((0,o.join)(p,e.fileName)))));await ensureGitIdentity();if(r){await(0,c.git)("add",d)}else{await(0,c.git)("add",d,p)}const b=process.env.GITHUB_ACTIONS==="true";const w=`chore(release): ${g}${b?" [skip ci]":""}`;await(0,c.git)("commit","-m",`${w}\n\n${y}`);await(0,c.git)("tag",m);await pushCommitAndTag(m);console.log(`released ${m}`);(0,l.appendStepSummary)(`🚀 **Released ${m}**\n\n${y}`);await(0,u.createReleaseEntry)(m,y);if(process.env.GITHUB_ACTIONS==="true"){await(0,t.dispatchTaggedReleaseWorkflow)(m)}};t.changesetsReleaseJob=changesetsReleaseJob},4023:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.githubDeployKeyRemoteJob=t.configureDeployKeyRemote=t.pushWithDeployKey=t.writeDeployKeyFile=t.deployKeySshCommand=t.deployKeyRemoteUrl=t.getReleaseDeployKey=t.RELEASE_DEPLOY_KEY_ENV=void 0;const n=r(1943);const s=r(857);const o=r(6928);const i=r(1177);t.RELEASE_DEPLOY_KEY_ENV="CATLADDER_RELEASE_KEY";const a="catladder release";const requireEnv=e=>{const t=process.env[e];if(!t){throw new Error(`${e} is not set — cannot push the release`)}return t};const getReleaseDeployKey=()=>process.env[t.RELEASE_DEPLOY_KEY_ENV]||null;t.getReleaseDeployKey=getReleaseDeployKey;const deployKeyRemoteUrl=()=>{var e;const t=(e=process.env.GITHUB_SERVER_URL)!==null&&e!==void 0?e:"https://github.com";const r=new URL(t).host;const n=requireEnv("GITHUB_REPOSITORY");return`git@${r}:${n}.git`};t.deployKeyRemoteUrl=deployKeyRemoteUrl;const deployKeySshCommand=e=>`ssh -i ${e} -o IdentitiesOnly=yes -o StrictHostKeyChecking=accept-new`;t.deployKeySshCommand=deployKeySshCommand;const writeDeployKeyFile=async e=>{const t=await(0,n.mkdtemp)((0,o.join)((0,s.tmpdir)(),"release-key-"));const r=(0,o.join)(t,"id_ed25519");await(0,n.writeFile)(r,e.endsWith("\n")?e:`${e}\n`,{mode:384});return{dir:t,keyFile:r}};t.writeDeployKeyFile=writeDeployKeyFile;const pushWithDeployKey=async(e,r)=>{const{dir:s,keyFile:o}=await(0,t.writeDeployKeyFile)(e);try{await(0,i.gitWithEnv)({GIT_SSH_COMMAND:(0,t.deployKeySshCommand)(o)},"push","--atomic",(0,t.deployKeyRemoteUrl)(),...r)}finally{await(0,n.rm)(s,{recursive:true,force:true})}};t.pushWithDeployKey=pushWithDeployKey;const configureDeployKeyRemote=async e=>{var r;const n=(0,t.deployKeyRemoteUrl)();const{keyFile:s}=await(0,t.writeDeployKeyFile)(e);await(0,i.git)("config","core.sshCommand",(0,t.deployKeySshCommand)(s));try{await(0,i.git)("ls-remote","--exit-code",n,"HEAD")}catch(e){throw new Error(`the release deploy key cannot reach ${n}: ${(r=e===null||e===void 0?void 0:e.message)!==null&&r!==void 0?r:e}\n`+`The ${t.RELEASE_DEPLOY_KEY_ENV} secret does not match the '${a}' deploy key of the repository `+`(or the key was removed). Run \`catladder project setup\` to provision both again, then rerun this job.`)}return n};t.configureDeployKeyRemote=configureDeployKeyRemote;const githubDeployKeyRemoteJob=async()=>{const e=(0,t.getReleaseDeployKey)();if(!e){throw new Error(`${t.RELEASE_DEPLOY_KEY_ENV} is not set — the release push cannot use the deploy key `+`(without merge gating the workflow token push works: run semantic-release without --repository-url)`)}const r=await(0,t.configureDeployKeyRemote)(e);console.error(`release push: ${r} over ssh with the release deploy key (bypasses the merge-gating ruleset)`);process.stdout.write(`${r}\n`)};t.githubDeployKeyRemoteJob=githubDeployKeyRemoteJob},7695:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.githubQueuedGuardJob=t.githubQueueCheckJob=void 0;const n=r(9896);const s=r(1177);const o=r(4074);const i="catladder-main.yml";const a="catladder-release-on-green.yml";const c="refs/catladder/release-queued";const ensureGitSafeDirectory=async()=>{await(0,s.git)("config","--global","--add","safe.directory",process.cwd())};const requireEnv=e=>{const t=process.env[e];if(!t){throw new Error(`${e} is not set`)}return t};const fail=e=>{console.error(e);process.exit(1)};const setStepOutput=(e,t)=>{const r=process.env.GITHUB_OUTPUT;if(!r){return}(0,n.appendFileSync)(r,`${e}=${t}\n`)};const getMainWorkflowRun=async e=>{var t,r,n;const s=(t=process.env.GITHUB_API_URL)!==null&&t!==void 0?t:"https://api.github.com";const o=requireEnv("GITHUB_REPOSITORY");const a=requireEnv("GITHUB_TOKEN");const c=await fetch(`${s}/repos/${o}/actions/workflows/${i}/runs?head_sha=${e}&per_page=5`,{headers:{authorization:`Bearer ${a}`,accept:"application/vnd.github+json"}});if(!c.ok){throw new Error(`listing ${i} runs failed: ${c.status} ${await c.text()}`)}const u=await c.json();return(n=(r=u.workflow_runs)===null||r===void 0?void 0:r[0])!==null&&n!==void 0?n:null};const githubQueueCheckJob=async()=>{await ensureGitSafeDirectory();const e=await(0,s.git)("rev-parse","HEAD");const t=await getMainWorkflowRun(e);if(!t){console.log(`no main workflow run found for ${e} — releasing right away`);(0,o.appendStepSummary)(`â„šī¸ No main workflow run found for \`${e}\` — releasing right away.`);setStepOutput("queued","false");return}if(t.status==="completed"){if(t.conclusion==="success"){console.log(`main workflow for ${e} succeeded — releasing right away`);(0,o.appendStepSummary)(`✅ The main workflow for \`${e}\` succeeded — releasing right away.`);setStepOutput("queued","false");return}(0,o.appendStepSummary)(`❌ Not releasing: the ${(0,o.workflowLink)(i,"main workflow")} run for \`${e}\` concluded **${t.conclusion}**. `+`Fix the pipeline, or re-run with the force checkbox to release anyway.`);fail(`the main workflow for ${e} concluded '${t.conclusion}' — `+`fix the pipeline, or force the release to release anyway`)}await(0,s.git)("push","origin",`+${e}:${c}`);const r=t.status.replace(/_/g," ");console.log(`main workflow for ${e} is ${r} — release queued: `+`the 'release on green' workflow creates the release as soon as the run succeeds`);(0,o.appendStepSummary)(`âŗ **Release queued** for \`${e}\` — the ${(0,o.workflowLink)(i,"main workflow")} run is still ${r}. `+`${(0,o.workflowLink)(a,"release on green")} creates the release as soon as it succeeds.`);setStepOutput("queued","true")};t.githubQueueCheckJob=githubQueueCheckJob;const githubQueuedGuardJob=async(e,t)=>{var r;await ensureGitSafeDirectory();const n=await(0,s.git)("ls-remote","origin",c);const i=(r=n.split(/\s+/)[0])!==null&&r!==void 0?r:"";if(!i){console.log("no release queued — nothing to do");(0,o.appendStepSummary)("No release queued — nothing to do.");setStepOutput("release","false");return}if(i!==e){console.log(`queued release is for ${i}, this run is for ${e} — leaving the queue untouched`);(0,o.appendStepSummary)(`Queued release is for \`${i}\`, this run is for \`${e}\` — leaving the queue untouched.`);setStepOutput("release","false");return}await(0,s.git)("push","origin",`:${c}`);if(t!=="success"){(0,o.appendStepSummary)(`❌ Queued release for \`${e}\` **not executed**: the main workflow concluded **${t}**. `+`Fix the pipeline and queue again via the 🚀 create release workflow.`);fail(`queued release not executed: the main workflow concluded '${t}' — `+`fix the pipeline and queue the release again`)}console.log(`main workflow for ${e} succeeded — releasing`);(0,o.appendStepSummary)(`✅ Main workflow for \`${e}\` succeeded — running the queued release.`);setStepOutput("release","true")};t.githubQueuedGuardJob=githubQueuedGuardJob},881:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createReleaseEntry=void 0;const post=async(e,t,r)=>{const n=await fetch(e,{method:"POST",headers:{"content-type":"application/json",...t},body:JSON.stringify(r)});if(!n.ok){throw new Error(`POST ${e} failed: ${n.status} ${await n.text()}`)}};const createGitlabReleaseEntry=async(e,t)=>{const r=process.env.GL_TOKEN;const n=process.env.CI_API_V4_URL;const s=process.env.CI_PROJECT_ID;if(!r||!n||!s){console.warn("no GL_TOKEN / gitlab api context — skipping the release entry (the tag is pushed)");return}await post(`${n}/projects/${s}/releases`,{"PRIVATE-TOKEN":r},{tag_name:e,description:t});console.log(`created the gitlab release entry for ${e}`)};const createGithubReleaseEntry=async(e,t)=>{var r;const n=process.env.GITHUB_TOKEN;const s=(r=process.env.GITHUB_API_URL)!==null&&r!==void 0?r:"https://api.github.com";const o=process.env.GITHUB_REPOSITORY;if(!n||!o){console.warn("no GITHUB_TOKEN / repository context — skipping the release entry (the tag is pushed)");return}await post(`${s}/repos/${o}/releases`,{authorization:`Bearer ${n}`,accept:"application/vnd.github+json"},{tag_name:e,name:e,body:t});console.log(`created the github release entry for ${e}`)};const createReleaseEntry=async(e,t)=>{try{if(process.env.GITHUB_ACTIONS==="true"){await createGithubReleaseEntry(e,t)}else{await createGitlabReleaseEntry(e,t)}}catch(t){console.warn(`âš ī¸ could not create the release entry for ${e}: ${t}\n`+"the release itself is done (commit, tag and changelog are pushed) — "+"create the entry by hand if you need it")}};t.createReleaseEntry=createReleaseEntry},1177:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.getLastReleaseTag=t.ensureReleaseHistory=t.gitWithEnv=t.git=void 0;const n=r(5317);const s=r(9023);const o=(0,s.promisify)(n.execFile);const git=async(...e)=>{const{stdout:t}=await o("git",e);return t.trim()};t.git=git;const gitWithEnv=async(e,...t)=>{const{stdout:r}=await o("git",t,{env:{...process.env,...e}});return r.trim()};t.gitWithEnv=gitWithEnv;const ensureReleaseHistory=async()=>{const e=await(0,t.git)("rev-parse","--is-shallow-repository").catch((()=>"false"));try{if(e==="true"){await(0,t.git)("fetch","--quiet","--unshallow","--tags","origin")}else{await(0,t.git)("fetch","--quiet","--tags","origin")}}catch(e){console.warn(`could not fetch tags from origin (${e}) — version derivation may be wrong on a shallow clone`)}};t.ensureReleaseHistory=ensureReleaseHistory;const getLastReleaseTag=async()=>{try{return await(0,t.git)("describe","--tags","--abbrev=0","--match","v[0-9]*")}catch(e){return null}};t.getLastReleaseTag=getLastReleaseTag},4074:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.workflowLink=t.appendStepSummary=void 0;const n=r(9896);const appendStepSummary=e=>{const t=process.env.GITHUB_STEP_SUMMARY;if(!t){return}(0,n.appendFileSync)(t,e+"\n")};t.appendStepSummary=appendStepSummary;const workflowLink=(e,t)=>{var r;const n=(r=process.env.GITHUB_SERVER_URL)!==null&&r!==void 0?r:"https://github.com";const s=process.env.GITHUB_REPOSITORY;if(!s){return t}return`[${t}](${n}/${s}/actions/workflows/${e})`};t.workflowLink=workflowLink},2759:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.evaluateDocument=t.makeTemplate=void 0;const s=n(r(6743));const o=s.default;const i="✅";const a="❌";const c=`${i}/${a}`;const u="@...";const l=[["Responsible",c,"Description","Note","More Information"]].concat(o.map((e=>[Array(e.responsibles).fill(u).join(", "),c,e.description,"",e.more])));function makeTable(e){const t=calculateColumnWidths(e);return`\n${makeRow(e[0],t," ")}\n${makeRow(e[0].map((()=>"")),t,"-")}\n${e.slice(1).map((e=>makeRow(e,t," "))).join("\n")}\n`}function calculateColumnWidths(e){const t=e[0].length;return Array.from({length:t},((e,t)=>t)).map((t=>Math.max(...e.map((e=>e[t].length)))))}function makeRow(e,t,r){return`| ${e.map(((e,n)=>e.padEnd(t[n],r))).join(" | ")} |`}function makeTemplate(){return`\n# Security Audit Report\n\nA security audit report document is a comprehensive assessment of an application's security posture, containing security topics that auditors can mark to indicate the state of various security aspects.\n\nIt serves as a structured guide for security team to evaluate different security factors such as authentication, authorization, data encryption, input validation, and more.\n\n## General Information\n\n- Project Owner is @...\n- Dev team:\n - @...\n - @...\n - @...\n\n## Project Security\n\n${makeTable(l)}\n\n`}t.makeTemplate=makeTemplate;function evaluateDocument(e){var t,r;const n=(r=(t=e.match(/^\s*\|.*?\|\s*$/gm))===null||t===void 0?void 0:t.map((e=>e.trim())))!==null&&r!==void 0?r:[];const s=n.map((e=>e.split("|").map((e=>e.trim())))).slice(2);const a=new Set(o.map((e=>e.description)));const l=s.map((e=>{const t=e[1].split(", ");const r=e[2];const n=e[3];const s=e[4];const o=!a.has(n);const l=!o&&!r.includes(c)&&!t.some((e=>e.includes(u)));const p=!o&&l&&r.includes(i);return{responsibles:t,answer:r,description:n,note:s,isUnknown:o,isAnswered:l,isSecured:p}}));const p=o.length;const d=l.filter((e=>e.isAnswered)).length;const f=l.filter((e=>e.isSecured)).length;const h=l.filter((e=>e.isUnknown)).length;const g=Math.round(f/p*100);return{topics:l,score:{rating:g,totalTopics:p,answeredTopics:d,securedTopics:f,unknownTopics:h}}}t.evaluateDocument=evaluateDocument},6289:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.createSecurityAuditMergeRequest=t.SECURITY_AUDIT_FILE_NAME=void 0;const n=r(9226);const s=r(2759);function makeDatedBranchName(e){const t=(new Date).toISOString().slice(0,-5).replaceAll(/[:.T]/g,"-");return`${e}-${t}`}const o="Draft: chore(security): add security audit document";t.SECURITY_AUDIT_FILE_NAME="SECURITY.md";async function createSecurityAuditMergeRequest({projectId:e,mainBranch:r,userId:i,api:a}){const c=(await n.Result.wrapAsync((()=>a.MergeRequests.all({state:"opened",wip:"yes",labels:"security-audit"})))).mapErr((()=>`could not search for existing merge requests`));if(c.isErr())return c;const u=c.value[0];if(u)return(0,n.Err)(`open merge request with security audit already exists: ${u.web_url}`);const l=n.Result.wrap((()=>(0,s.makeTemplate)())).mapErr((()=>"could not make security audit template document"));if(l.isErr())return l;const p=(await n.Result.wrapAsync((()=>a.Branches.create(e,makeDatedBranchName("chore/security-audit"),r)))).mapErr((e=>{console.log(e);return"could not create branch"}));if(p.isErr())return p;const d=(await n.Result.wrapAsync((()=>a.Commits.create(e,p.value.name,"chore(security): add empty security audit document template",[{action:"create",filePath:t.SECURITY_AUDIT_FILE_NAME,content:l.value,encoding:"text"}])))).mapErr((()=>"could not create commit"));if(d.isErr())return d;const f=(await n.Result.wrapAsync((()=>a.MergeRequests.create(e,p.value.name,r,o,{description:`Please follow and update security audit document in \`${t.SECURITY_AUDIT_FILE_NAME}\`.`,assigneeId:i,squash:true,labels:"security-audit",removeSourceBranch:true})))).mapErr((()=>"could not create merge request"));return f}t.createSecurityAuditMergeRequest=createSecurityAuditMergeRequest},8725:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.makeSecurityAuditOverview=t.evaluateSecurityAudit=void 0;const n=r(9226);const s=r(6928);const o=r(1943);const i=r(6289);const a=r(2759);async function evaluateSecurityAudit({path:e}){return(await n.Result.wrapAsync((async()=>{const t=(0,s.join)(e,i.SECURITY_AUDIT_FILE_NAME);const r=await(0,o.readFile)(t);const n=r.toString("utf-8");return(0,a.evaluateDocument)(n)}))).mapErr((e=>`could not evaluate ${i.SECURITY_AUDIT_FILE_NAME}: ${e}`))}t.evaluateSecurityAudit=evaluateSecurityAudit;function makeSecurityAuditOverview(e){const ratingToEmo=e=>e<33?"đŸŸĨ":e<66?"🟨":"🟩";return`Project security posture overview:\n 🧐 Total topics: ${e.score.totalTopics}\n 🔒 Secured topics: ${e.score.securedTopics}\n đŸ“ĸ Answered topics: ${e.score.answeredTopics}\n ❔ Unknown topics: ${e.score.unknownTopics}\n 📊 Rating: ${ratingToEmo(e.score.rating)} ${e.score.rating}/100`}t.makeSecurityAuditOverview=makeSecurityAuditOverview},6175:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});t.getGitlabHostUrl=void 0;const n=r(6884);const getGitlabHostUrl=async(e="origin")=>{const t=process.env.CI_SERVER_URL;if(t){return t.replace(/\/+$/,"")}const{gitRemoteHost:r}=await(0,n.getGitRemoteHostAndPath)(e);return`https://${r}`};t.getGitlabHostUrl=getGitlabHostUrl},492:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:true});var n=r(2146);function _interopDefault(e){return e&&e.__esModule?e:{default:e}}var s=_interopDefault(n);const o=/\s*---([^]*?)\n\s*---(\s*(?:\n|$)[^]*)/;const i=`---\n"package-name": patch\n---`;const a=["major","minor","patch","none"];function truncate(e,t=200){return e.length>t?e.slice(0,t)+"...":e}function validateReleases(e,t){for(const r of e){if(typeof r.name!=="string"||r.name.trim()===""){throw new Error(`could not parse changeset - invalid package name in frontmatter.\n`+`Expected a non-empty string for package name, but got: ${JSON.stringify(r.name)}\n`+`Changeset contents:\n${truncate(t)}`)}if(typeof r.type!=="string"){throw new Error(`could not parse changeset - invalid release type for package "${r.name}".\n`+`Expected a string for release type, but got: ${typeof r.type}\n`+`Changeset contents:\n${truncate(t)}`)}if(!a.includes(r.type)){throw new Error(`could not parse changeset - invalid version type ${JSON.stringify(r.type)} for package "${r.name}".\n`+`Valid version types are: ${a.join(", ")}\n`+`Changeset contents:\n${truncate(t)}`)}}}function parseChangesetFile(e){const t=e.trim();if(!t){throw new Error(`could not parse changeset - file is empty.\n`+`Changesets must have frontmatter with package names and version types.\n`+`Example:\n${i}\n\nYour changeset summary here.`)}const r=o.exec(e);if(!r){throw new Error(`could not parse changeset - missing or invalid frontmatter.\n`+`Changesets must start with frontmatter delimited by "---".\n`+`Example:\n${i}\n\nYour changeset summary here.\n`+`Received content:\n${truncate(t)}`)}let[,n,a]=r;let c=a.trim();let u;let l;try{l=s["default"].load(n)}catch(e){throw new Error(`could not parse changeset - invalid YAML in frontmatter.\n`+`The frontmatter between the "---" delimiters must be valid YAML.\n`+`YAML error: ${e instanceof Error?e.message:String(e)}\n`+`Frontmatter content:\n${n}`)}if(l){if(typeof l!=="object"||Array.isArray(l)){throw new Error(`could not parse changeset - frontmatter must be an object mapping package names to version types.\n`+`Expected format:\n${i}\n`+`Received:\n${n}`)}u=Object.entries(l).map((([e,t])=>({name:e,type:t})))}else{u=[]}validateReleases(u,e);return{releases:u,summary:c}}t["default"]=parseChangesetFile},5182:(e,t,r)=>{"use strict";var n=r(8126);var s=r(6308);var o=r(891);function _interopDefault(e){return e&&e.__esModule?e:{default:e}}var i=_interopDefault(o);function appendFormFromObject(e){const t=new FormData;Object.entries(e).forEach((([e,r])=>{if(!r)return;if(Array.isArray(r))t.append(e,r[0],r[1]);else t.append(e,r)}));return t}function endpoint(e,...t){return t.reduce(((t,r,n)=>t+encodeURIComponent(r)+e[n+1]),e[0])}function parseLinkHeader(e){const t={};const r=/<([^>]+)>; rel="([^"]+)"/g;let n;while(n=r.exec(e)){const[,e,r]=n;t[r]=e}return t}function reformatObjectOptions(e,t,r=false){const n=r?s.decamelizeKeys(e):e;return i.default.stringify({[t]:n},{encode:false}).split("&").reduce(((e,t)=>{const[r,n]=t.split("=");e[r]=n;return e}),{})}function packageResponse(e,t){return t?{data:e.body,status:e.status,headers:e.headers}:e.body}function getStream(e,t){return packageResponse(e,t)}function getSingle(e,t,r){const{status:n,headers:o}=t;let{body:i}=t;if(e)i=s.camelizeKeys(i);return packageResponse({body:i,status:n,headers:o},r)}async function getManyMore(e,t,r,n,i,a){const{sudo:c,showExpanded:u,maxPages:l,pagination:p,page:d,perPage:f,idAfter:h,orderBy:g,sort:m}=i;if(e)n.body=s.camelizeKeys(n?.body);const y=[...a||[],...n.body];const v=l&&f?y.length/+f<l:true;const{next:$=""}=parseLinkHeader(n.headers.link);if(!(d&&(a||[]).length===0)&&$&&v){const n=o.parse($.split("?")[1]);const i={...s.camelizeKeys(n)};const a={...i,maxPages:l,sudo:c,showExpanded:u};const p=await t(r,{searchParams:i,sudo:c});return getManyMore(e,t,r,p,a,y)}if(!u)return y;const b=p==="keyset"?{idAfter:h?+h:null,perPage:f?+f:null,orderBy:g,sort:m}:{total:parseInt(n.headers["x-total"],10),next:parseInt(n.headers["x-next-page"],10)||null,current:parseInt(n.headers["x-page"],10)||1,previous:parseInt(n.headers["x-prev-page"],10)||null,perPage:parseInt(n.headers["x-per-page"],10),totalPages:parseInt(n.headers["x-total-pages"],10)};return{data:y,paginationInfo:b}}function get(){return async(e,t,r)=>{const{asStream:n,sudo:s,showExpanded:o,maxPages:i,...a}=r||{};const c=e.queryTimeout?AbortSignal.timeout(e.queryTimeout):void 0;const u=await e.requester.get(t,{searchParams:a,sudo:s,asStream:n,signal:c});const l=e.camelize||false;if(n)return getStream(u,o);if(!Array.isArray(u.body))return getSingle(l,u,o);const p={sudo:s,showExpanded:o,maxPages:i,...a};return getManyMore(l,((t,r)=>e.requester.get(t,{...r,signal:c})),t,u,p)}}function post(){return async(e,t,{searchParams:r,isForm:n,sudo:o,showExpanded:i,...a}={})=>{const c=n?appendFormFromObject(a):a;const u=await e.requester.post(t,{searchParams:r,body:c,sudo:o,signal:e.queryTimeout?AbortSignal.timeout(e.queryTimeout):void 0});if(e.camelize)u.body=s.camelizeKeys(u.body);return packageResponse(u,i)}}function put(){return async(e,t,{searchParams:r,isForm:n,sudo:o,showExpanded:i,...a}={})=>{const c=n?appendFormFromObject(a):a;const u=await e.requester.put(t,{body:c,searchParams:r,sudo:o,signal:e.queryTimeout?AbortSignal.timeout(e.queryTimeout):void 0});if(e.camelize)u.body=s.camelizeKeys(u.body);return packageResponse(u,i)}}function patch(){return async(e,t,{searchParams:r,isForm:n,sudo:o,showExpanded:i,...a}={})=>{const c=n?appendFormFromObject(a):a;const u=await e.requester.patch(t,{body:c,searchParams:r,sudo:o,signal:e.queryTimeout?AbortSignal.timeout(e.queryTimeout):void 0});if(e.camelize)u.body=s.camelizeKeys(u.body);return packageResponse(u,i)}}function del(){return async(e,t,{sudo:r,showExpanded:n,searchParams:s,...o}={})=>{const i=await e.requester.delete(t,{body:o,searchParams:s,sudo:r,signal:e.queryTimeout?AbortSignal.timeout(e.queryTimeout):void 0});return packageResponse(i,n)}}var a={post:post,put:put,patch:patch,get:get,del:del};var c=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/cluster_agents`,t)}allTokens(e,t,r){return a.get()(this,endpoint`projects/${e}/cluster_agents/${t}/tokens`,r)}createToken(e,t,r,n){return a.get()(this,endpoint`projects/${e}/cluster_agents/${t}/tokens`,{name:r,...n})}show(e,t,r){return a.get()(this,endpoint`projects/${e}/cluster_agents/${t}`,r)}showToken(e,t,r,n){return a.get()(this,endpoint`projects/${e}/cluster_agents/${t}/tokens/${r}`,n)}register(e,t,r){return a.post()(this,endpoint`projects/${e}/cluster_agents`,{name:t,...r})}removeToken(e,t,r,n){return a.del()(this,endpoint`projects/${e}/cluster_agents/${t}/tokens/${r}`,n)}unregister(e,t,r){return a.del()(this,endpoint`projects/${e}/cluster_agents/${t}`,r)}};var u=class extends n.BaseResource{allMetricImages(e,t,r){return a.get()(this,endpoint`projects/${e}/alert_management_alerts/${t}/metric_images`,r)}editMetricImage(e,t,r,n){return a.put()(this,endpoint`projects/${e}/alert_management_alerts/${t}/metric_images/${r}`,n)}removeMetricImage(e,t,r,n){return a.del()(this,endpoint`projects/${e}/alert_management_alerts/${t}/metric_images/${r}`,n)}uploadMetricImage(e,t,r,n){return a.post()(this,endpoint`projects/${e}/alert_management_alerts/${t}/metric_images`,{isForm:true,file:[r.content,r.filename],...n})}};var l=class extends n.BaseResource{show(e){return a.get()(this,"application/appearence",e)}edit({logo:e,pwaIcon:t,...r}={}){if(e||t){const n={...r,isForm:true};if(e)n.logo=[e.content,e.filename];if(t)n.pwaIcon=[t.content,t.filename];return a.put()(this,"application/appearence",n)}return a.put()(this,"application/appearence",r)}};var p=class extends n.BaseResource{show(e){return a.get()(this,"application/plan_limits",e)}edit(e,t={}){const{ciPipelineSize:r,ciActiveJobs:n,ciActivePipelines:s,ciProjectSubscriptions:o,ciPipelineSchedules:i,ciNeedsSizeLimit:c,ciRegisteredGroupRunners:u,ciRegisteredProjectRunners:l,conanMaxFileSize:p,genericPackagesMaxFileSize:d,helmMaxFileSize:f,mavenMaxFileSize:h,npmMaxFileSize:g,nugetMaxFileSize:m,pypiMaxFileSize:y,terraformModuleMaxFileSize:v,storageSizeLimit:$,...b}=t;return a.put()(this,"application/plan_limits",{...b,searchParams:{planName:e,ciPipelineSize:r,ciActiveJobs:n,ciActivePipelines:s,ciProjectSubscriptions:o,ciPipelineSchedules:i,ciNeedsSizeLimit:c,ciRegisteredGroupRunners:u,ciRegisteredProjectRunners:l,conanMaxFileSize:p,genericPackagesMaxFileSize:d,helmMaxFileSize:f,mavenMaxFileSize:h,npmMaxFileSize:g,nugetMaxFileSize:m,pypiMaxFileSize:y,terraformModuleMaxFileSize:v,storageSizeLimit:$}})}};var d=class extends n.BaseResource{all(e){return a.get()(this,"applications",e)}create(e,t,r,n){return a.post()(this,"applications",{name:e,redirectUri:t,scopes:r,...n})}remove(e,t){return a.del()(this,`applications/${e}`,t)}};var f=class extends n.BaseResource{show(e){return a.get()(this,"application/settings",e)}edit(e){return a.put()(this,"application/settings",e)}};var h=class extends n.BaseResource{show(e){return a.get()(this,"application/statistics",e)}};function url({projectId:e,groupId:t}={}){let r="";if(e)r=endpoint`projects/${e}/`;else if(t)r=endpoint`groups/${t}/`;return`${r}audit_events`}var g=class extends n.BaseResource{all({projectId:e,groupId:t,...r}={}){const n=url({projectId:e,groupId:t});return a.get()(this,n,r)}show(e,{projectId:t,groupId:r,...n}={}){const s=url({projectId:t,groupId:r});return a.get()(this,`${s}/${e}`,n)}};var m=class extends n.BaseResource{show(e,t){return a.get()(this,"avatar",{email:e,...t})}};var y=class extends n.BaseResource{all(e){return a.get()(this,"broadcast_messages",e)}create(e){return a.post()(this,"broadcast_messages",e)}edit(e,t){return a.put()(this,`broadcast_messages/${e}`,t)}remove(e,t){return a.del()(this,`broadcast_messages/${e}`,t)}show(e,t){return a.get()(this,`broadcast_messages/${e}`,t)}};var v=class extends n.BaseResource{createAccessToken(e){return a.post()(this,"code_suggestions/tokens",e)}generateCompletion(e){return a.post()(this,"code_suggestions/completions",e)}};var $=class extends n.BaseResource{create(e,t){return a.post()(this,endpoint`projects/${e}/packages/composer`,t)}download(e,t,r,n){return a.get()(this,endpoint`projects/${e}/packages/composer/archives/${t}`,{searchParams:{sha:r},...n})}showMetadata(e,t,r){let n;if(r&&r.sha){n=endpoint`groups/${e}/-/packages/composer/${t}$${r.sha}`}else{n=endpoint`groups/${e}/-/packages/composer/p2/${t}`}return a.get()(this,n,r)}showPackages(e,t,r){return a.get()(this,endpoint`groups/${e}/-/packages/composer/p/${t}`,r)}showBaseRepository(e,t){const r={...this};if(t&&t.composerVersion==="2"){r.headers["User-Agent"]="Composer/2"}return a.get()(r,endpoint`groups/${e}/-/packages/composer/packages`,t)}};function url2(e){return e?endpoint`projects/${e}/packages/conan/v1`:"packages/conan/v1"}var b=class extends n.BaseResource{authenticate({projectId:e,...t}={}){return a.get()(this,`${url2(e)}/users/authenticate`,t)}checkCredentials({projectId:e,...t}={}){const r=url2(e);return a.get()(this,`${r}/users/check_credentials`,t)}downloadPackageFile(e,t,r,n,s,o,i,c,{projectId:u,...l}={}){const p=url2(u);return a.get()(this,`${p}/conans/${e}/${t}/${r}/${n}/${o}/package/${s}/${i}/${c}`,l)}downloadRecipeFile(e,t,r,n,s,o,{projectId:i,...c}={}){const u=url2(i);return a.get()(this,`${u}/conans/${e}/${t}/${r}/${n}/${s}/export/${o}`,c)}showPackageUploadUrls(e,t,r,n,s,{projectId:o,...i}={}){const c=url2(o);return a.get()(this,`${c}/conans/${e}/${t}/${r}/${n}/packages/${s}/upload_urls`,i)}showPackageDownloadUrls(e,t,r,n,s,{projectId:o,...i}={}){const c=url2(o);return a.get()(this,`${c}/conans/${e}/${t}/${r}/${n}/packages/${s}/download_urls`,i)}showPackageManifest(e,t,r,n,s,{projectId:o,...i}={}){const c=url2(o);return a.get()(this,`${c}/conans/${e}/${t}/${r}/${n}/packages/${s}/digest`,i)}showPackageSnapshot(e,t,r,n,s,{projectId:o,...i}={}){const c=url2(o);return a.get()(this,`${c}/conans/${e}/${t}/${r}/${n}/packages/${s}`,i)}ping({projectId:e,...t}={}){return a.post()(this,`${url2(e)}/ping`,t)}showRecipeUploadUrls(e,t,r,n,{projectId:s,...o}={}){const i=url2(s);return a.get()(this,`${i}/conans/${e}/${t}/${r}/${n}/upload_urls`,o)}showRecipeDownloadUrls(e,t,r,n,{projectId:s,...o}={}){const i=url2(s);return a.get()(this,`${i}/conans/${e}/${t}/${r}/${n}/download_urls`,o)}showRecipeManifest(e,t,r,n,{projectId:s,...o}={}){const i=url2(s);return a.get()(this,`${i}/conans/${e}/${t}/${r}/${n}/digest`,o)}showRecipeSnapshot(e,t,r,n,{projectId:s,...o}={}){const i=url2(s);return a.get()(this,`${i}/conans/${e}/${t}/${r}/${n}`,o)}removePackageFile(e,t,r,n,{projectId:s,...o}={}){const i=url2(s);return a.get()(this,`${i}/conans/${e}/${t}/${r}/${n}`,o)}search({projectId:e,...t}={}){const r=url2(e);return a.get()(this,`${r}/conans/search`,t)}uploadPackageFile(e,t,r,n,s,o,i,c,u){const l=url2();return a.get()(this,`${l}/files/${t}/${r}/${n}/${s}/${i}/package/${o}/${c}/${e.filename}`,{isForm:true,...u,file:[e.content,e.filename]})}uploadRecipeFile(e,t,r,n,s,o,i){const c=url2();return a.get()(this,`${c}/files/${t}/${r}/${n}/${s}/${o}/export/${e.filename}`,{isForm:true,...i,file:[e.content,e.filename]})}};var w=class extends n.BaseResource{create(e,t,r,{environmentId:n,clusterId:s,...o}={}){let i;if(n)i=endpoint`environments/${n}/metrics_dashboard/annotations`;else if(s)i=endpoint`clusters/${s}/metrics_dashboard/annotations`;else throw new Error("Missing required argument. Please supply a environmentId or a cluserId in the options parameter.");return a.post()(this,i,{dashboardPath:e,startingAt:t,description:r,...o})}};function url3({projectId:e,groupId:t}={}){if(e)return endpoint`/projects/${e}/packages/debian`;if(t)return endpoint`/groups/${t}/-/packages/debian`;throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter")}var _=class extends n.BaseResource{downloadBinaryFileIndex(e,t,r,{projectId:n,groupId:s,...o}){const i=url3({projectId:n,groupId:s});return a.get()(this,`${i}/dists/${e}/${t}/binary-${r}/Packages`,o)}downloadDistributionReleaseFile(e,{projectId:t,groupId:r,...n}){const s=url3({projectId:t,groupId:r});return a.get()(this,`${s}/dists/${e}/Release`,n)}downloadSignedDistributionReleaseFile(e,{projectId:t,groupId:r,...n}){const s=url3({projectId:t,groupId:r});return a.get()(this,`${s}/dists/${e}/InRelease`,n)}downloadReleaseFileSignature(e,{projectId:t,groupId:r,...n}){const s=url3({projectId:t,groupId:r});return a.get()(this,`${s}/dists/${e}/Release.gpg`,n)}downloadPackageFile(e,t,r,n,s,o,i){return a.get()(this,endpoint`projects/${e}/packages/debian/pool/${t}/${r}/${n}/${s}/${o}`,i)}uploadPackageFile(e,t,r){return a.put()(this,endpoint`projects/${e}/packages/debian/${t.filename}`,{isForm:true,...r,file:[t.content,t.filename]})}};var S=class extends n.BaseResource{remove(e,t){return a.post()(this,`groups/${e}/dependency_proxy/cache`,t)}};var A=class extends n.BaseResource{all({projectId:e,userId:t,...r}={}){let n;if(e){n=endpoint`projects/${e}/deploy_keys`}else if(t){n=endpoint`users/${t}/project_deploy_keys`}else{n="deploy_keys"}return a.get()(this,n,r)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/deploy_keys`,{title:t,key:r,...n})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/deploy_keys/${t}`,r)}enable(e,t,r){return a.post()(this,endpoint`projects/${e}/deploy_keys/${t}/enable`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/deploy_keys/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/deploy_keys/${t}`,r)}};var j=class extends n.BaseResource{all({projectId:e,groupId:t,...r}={}){let n;if(e)n=endpoint`projects/${e}/deploy_tokens`;else if(t)n=endpoint`groups/${t}/deploy_tokens`;else n="deploy_tokens";return a.get()(this,n,r)}create(e,t,{projectId:r,groupId:n,...s}={}){let o;if(r)o=endpoint`projects/${r}/deploy_tokens`;else if(n)o=endpoint`groups/${n}/deploy_tokens`;else{throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter.")}return a.post()(this,o,{name:e,scopes:t,...s})}remove(e,{projectId:t,groupId:r,...n}={}){let s;if(t)s=endpoint`projects/${t}/deploy_tokens/${e}`;else if(r)s=endpoint`groups/${r}/deploy_tokens/${e}`;else{throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter.")}return a.del()(this,s,n)}show(e,{projectId:t,groupId:r,...n}={}){let s;if(t)s=endpoint`projects/${t}/deploy_tokens/${e}`;else if(r)s=endpoint`groups/${r}/deploy_tokens/${e}`;else{throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter.")}return a.get()(this,s,n)}};var R=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/access_requests`,t)}request(e,t){return a.post()(this,endpoint`${e}/access_requests`,t)}approve(e,t,r){return a.post()(this,endpoint`${e}/access_requests/${t}/approve`,r)}deny(e,t,r){return a.del()(this,endpoint`${e}/access_requests/${t}`,r)}};var x=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/access_tokens`,t)}create(e,t,r,n){return a.post()(this,endpoint`${e}/access_tokens`,{name:t,scopes:r,...n})}revoke(e,t,r){return a.del()(this,endpoint`${e}/access_tokens/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`${e}/access_tokens/${t}`,r)}};function url4(e,t,r,n){const[s,o]=[e,r].map(encodeURIComponent);const i=[s,t,o];i.push("award_emoji");if(n)i.push(n);return i.join("/")}var k=class extends n.BaseResource{resourceType2;constructor(e,t,r){super({prefixUrl:e,...r});this.resourceType2=t}all(e,t,r){return a.get()(this,url4(e,this.resourceType2,t),r)}award(e,t,r,n){return a.post()(this,url4(e,this.resourceType2,t),{name:r,...n})}remove(e,t,r,n){return a.del()(this,url4(e,this.resourceType2,t,r),n)}show(e,t,r,n){return a.get()(this,url4(e,this.resourceType2,t,r),n)}};function url5(e,t,r,n,s){const[o,i]=[e,r].map(encodeURIComponent);const a=[o,t,i];a.push("notes");a.push(n);a.push("award_emoji");if(s)a.push(s);return a.join("/")}var I=class extends n.BaseResource{resourceType;constructor(e,t){super({prefixUrl:"projects",...t});this.resourceType=e}all(e,t,r,n){return a.get()(this,url5(e,this.resourceType,t,r),n)}award(e,t,r,n,s){return a.post()(this,url5(e,this.resourceType,t,r),{name:n,...s})}remove(e,t,r,n,s){return a.del()(this,url5(e,this.resourceType,t,r,n),s)}show(e,t,r,n,s){return a.get()(this,url5(e,this.resourceType,t,r,n),s)}};var P=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}add(e,t,r,n){return a.post()(this,endpoint`${e}/badges`,{linkUrl:t,imageUrl:r,...n})}all(e,t){return a.get()(this,endpoint`${e}/badges`,t)}edit(e,t,r){return a.put()(this,endpoint`${e}/badges/${t}`,r)}preview(e,t,r,n){return a.get()(this,endpoint`${e}/badges/render`,{linkUrl:t,imageUrl:r,...n})}remove(e,t,r){return a.del()(this,endpoint`${e}/badges/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`${e}/badges/${t}`,r)}};var C=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/custom_attributes`,t)}remove(e,t,r){return a.del()(this,endpoint`${e}/custom_attributes/${t}`,r)}set(e,t,r,n){return a.put()(this,endpoint`${e}/custom_attributes/${t}`,{value:r,...n})}show(e,t,r){return a.get()(this,endpoint`${e}/custom_attributes/${t}`,r)}};var T=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t,r){return a.get()(this,endpoint`${e}/dora/metrics`,{metric:t,...r})}};var O=class extends n.BaseResource{resource2Type;constructor(e,t,r){super({prefixUrl:e,...r});this.resource2Type=t}addNote(e,t,r,n,s,o){return a.post()(this,endpoint`${e}/${this.resource2Type}/${t}/discussions/${r}/notes`,{...o,body:s,noteId:n})}all(e,t,r){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/discussions`,r)}create(e,t,r,{position:n,...s}={}){const o={...s,body:r};if(n){Object.assign(o,reformatObjectOptions(n,"position",true));o.isForm=true}return a.post()(this,endpoint`${e}/${this.resource2Type}/${t}/discussions`,o)}editNote(e,t,r,n,s){return a.put()(this,endpoint`${e}/${this.resource2Type}/${t}/discussions/${r}/notes/${n}`,s)}removeNote(e,t,r,n,s){return a.del()(this,endpoint`${e}/${this.resource2Type}/${t}/discussions/${r}/notes/${n}`,s)}show(e,t,r,n){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/discussions/${r}`,n)}};var M=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/boards`,t)}allLists(e,t,r){return a.get()(this,endpoint`${e}/boards/${t}/lists`,r)}create(e,t,r){return a.post()(this,endpoint`${e}/boards`,{name:t,...r})}createList(e,t,r){return a.post()(this,endpoint`${e}/boards/${t}/lists`,r)}edit(e,t,r){return a.put()(this,endpoint`${e}/boards/${t}`,r)}editList(e,t,r,n,s){return a.put()(this,endpoint`${e}/boards/${t}/lists/${r}`,{position:n,...s})}remove(e,t,r){return a.del()(this,endpoint`${e}/boards/${t}`,r)}removeList(e,t,r,n){return a.del()(this,endpoint`${e}/boards/${t}/lists/${r}`,n)}show(e,t,r){return a.get()(this,endpoint`${e}/boards/${t}`,r)}showList(e,t,r,n){return a.get()(this,endpoint`${e}/boards/${t}/lists/${r}`,n)}};var N=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/labels`,t)}create(e,t,r,n){return a.post()(this,endpoint`${e}/labels`,{name:t,color:r,...n})}edit(e,t,r){if(!r?.newName&&!r?.color)throw new Error("Missing required argument. Please supply a color or a newName in the options parameter.");return a.put()(this,endpoint`${e}/labels/${t}`,r)}promote(e,t,r){return a.put()(this,endpoint`${e}/labels/${t}/promote`,r)}remove(e,t,r){return a.del()(this,endpoint`${e}/labels/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`${e}/labels/${t}`,r)}subscribe(e,t,r){return a.post()(this,endpoint`${e}/issues/${t}/subscribe`,r)}unsubscribe(e,t,r){return a.post()(this,endpoint`${e}/issues/${t}/unsubscribe`,r)}};var L=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}add(e,t,r,n){return a.post()(this,endpoint`${e}/members`,{userId:String(t),accessLevel:r,...n})}all(e,{includeInherited:t,...r}={}){let n=endpoint`${e}/members`;if(t)n+="/all";return a.get()(this,n,r)}edit(e,t,r,n){return a.put()(this,endpoint`${e}/members/${t}`,{accessLevel:r,...n})}show(e,t,{includeInherited:r,...n}={}){const[s,o]=[e,t].map(encodeURIComponent);const i=[s,"members"];if(r)i.push("all");i.push(o);return a.get()(this,i.join("/"),n)}remove(e,t,r){return a.del()(this,endpoint`${e}/members/${t}`,r)}};var B=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/milestones`,t)}allAssignedIssues(e,t,r){return a.get()(this,endpoint`${e}/milestones/${t}/issues`,r)}allAssignedMergeRequests(e,t,r){return a.get()(this,endpoint`${e}/milestones/${t}/merge_requests`,r)}allBurndownChartEvents(e,t,r){return a.get()(this,endpoint`${e}/milestones/${t}/burndown_events`,r)}create(e,t,r){return a.post()(this,endpoint`${e}/milestones`,{title:t,...r})}edit(e,t,r){return a.put()(this,endpoint`${e}/milestones/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`${e}/milestones/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`${e}/milestones/${t}`,r)}};var D=class extends n.BaseResource{resource2Type;constructor(e,t,r){super({prefixUrl:e,...r});this.resource2Type=t}all(e,t,r){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/notes`,r)}create(e,t,r,n){return a.post()(this,endpoint`${e}/${this.resource2Type}/${t}/notes`,{body:r,...n})}edit(e,t,r,n){return a.put()(this,endpoint`${e}/${this.resource2Type}/${t}/notes/${r}`,n)}remove(e,t,r,n){return a.del()(this,endpoint`${e}/${this.resource2Type}/${t}/notes/${r}`,n)}show(e,t,r,n){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/notes/${r}`,n)}};var U=class extends n.BaseResource{constructor(e,t){super({prefixUrl:["templates",e].join("/"),...t})}all(e){process.emitWarning('This API will be deprecated as of Gitlabs v5 API. Please make the switch to "ProjectTemplates".',"DeprecationWarning");return a.get()(this,"",e)}show(e,t){process.emitWarning('This API will be deprecated as of Gitlabs v5 API. Please make the switch to "ProjectTemplates".',"DeprecationWarning");return a.get()(this,encodeURIComponent(e),t)}};var G=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/variables`,t)}create(e,t,r,n){return a.post()(this,endpoint`${e}/variables`,{key:t,value:r,...n})}edit(e,t,r,n){return a.put()(this,endpoint`${e}/variables/${t}`,{value:r,...n})}show(e,t,r){return a.get()(this,endpoint`${e}/variables/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`${e}/variables/${t}`,r)}};var q=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/wikis`,t)}create(e,t,r,n){return a.post()(this,endpoint`${e}/wikis`,{content:t,title:r,...n})}edit(e,t,r){return a.put()(this,endpoint`${e}/wikis/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`${e}/wikis/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`${e}/wikis/${t}`,r)}uploadAttachment(e,t,r){return a.post()(this,endpoint`${e}/wikis/attachments`,{...r,isForm:true,file:[t.content,t.filename]})}};var H=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}add(e,t,r){return a.post()(this,endpoint`${e}/hooks`,{url:t,...r})}all(e,t){return a.get()(this,endpoint`${e}/hooks`,t)}edit(e,t,r,n){return a.put()(this,endpoint`${e}/hooks/${t}`,{url:r,...n})}remove(e,t,r){return a.del()(this,endpoint`${e}/hooks/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`${e}/hooks/${t}`,r)}};var K=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}create(e,t){return a.post()(this,endpoint`${e}/push_rule`,t)}edit(e,t){return a.put()(this,endpoint`${e}/push_rule`,t)}remove(e,t){return a.del()(this,endpoint`${e}/push_rule`,t)}show(e,t){return a.get()(this,endpoint`${e}/push_rule`,t)}};var Y=class extends n.BaseResource{resourceType;resourceTypeSingular;constructor(e,t){super(t);this.resourceType=e;this.resourceTypeSingular=e.substring(0,e.length-1)}all(e){const t=e?.[`${this.resourceTypeSingular}Id`];const r=t?endpoint`${this.resourceType}/${t}/repository_storage_moves`:`${this.resourceTypeSingular}_repository_storage_moves`;return a.get()(this,r,e)}show(e,t){const r=t?.[`${this.resourceTypeSingular}Id`];const n=r?endpoint`${this.resourceType}/${r}/repository_storage_moves`:`${this.resourceTypeSingular}_repository_storage_moves`;return a.get()(this,`${n}/${e}`,t)}schedule(e,t){const r=t?.[`${this.resourceTypeSingular}Id`];const n=r?endpoint`${this.resourceType}/${r}/repository_storage_moves`:`${this.resourceTypeSingular}_repository_storage_moves`;return a.post()(this,n,{sourceStorageName:e,...t})}};var W=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}add(e,t,r){if(!r?.email&&!r?.userId)throw new Error("Missing required argument. Please supply a email or a userId in the options parameter.");return a.post()(this,endpoint`${e}/invitations`,{accessLevel:t,...r})}all(e,t){return a.get()(this,endpoint`${e}/invitations`,t)}edit(e,t,r){return a.put()(this,endpoint`${e}/invitations/${t}`,r)}remove(e,t,r){return a.put()(this,endpoint`${e}/invitations/${t}`,r)}};var z=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,endpoint`${e}/iterations`,t)}};var V=class extends n.BaseResource{constructor(e,t){super({prefixUrl:e,...t})}all(e,t){return a.get()(this,`${e}/protected_environments`,t)}create(e,t,r,n){return a.post()(this,`${e}/protected_environments`,{name:t,deployAccessLevel:r,...n})}edit(e,t,r){return a.put()(this,`${e}/protected_environments/${t}`,r)}show(e,t,r){return a.get()(this,`${e}/protected_environments/${t}`,r)}remove(e,t,r){return a.del()(this,`${e}/protected_environments/${t}`,r)}};var Q=class extends n.BaseResource{resource2Type;constructor(e,t,r){super({prefixUrl:e,...r});this.resource2Type=t}all(e,t,r){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_iteration_events`,r)}show(e,t,r,n){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_iteration_events/${r}`,n)}};var J=class extends n.BaseResource{resource2Type;constructor(e,t,r){super({prefixUrl:e,...r});this.resource2Type=t}all(e,t,r){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_label_events`,r)}show(e,t,r,n){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_label_events/${r}`,n)}};var X=class extends n.BaseResource{resource2Type;constructor(e,t,r){super({prefixUrl:e,...r});this.resource2Type=t}all(e,t,r){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_milestone_events`,r)}show(e,t,r,n){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_milestone_events/${r}`,n)}};var Z=class extends n.BaseResource{resource2Type;constructor(e,t,r){super({prefixUrl:e,...r});this.resource2Type=t}all(e,t,r){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_state_events`,r)}show(e,t,r,n){return a.get()(this,endpoint`${e}/${this.resource2Type}/${t}/resource_state_events/${r}`,n)}};var ee=class extends U{constructor(e){super("dockerfiles",e)}};var te=class extends n.BaseResource{all({projectId:e,userId:t,...r}={}){let n;if(e)n=endpoint`projects/${e}/events`;else if(t)n=endpoint`users/${t}/events`;else n="events";return a.get()(this,n,r)}};var re=class extends n.BaseResource{all(e){return a.get()(this,"experiments",e)}};var ne=class extends n.BaseResource{all(e){return a.get()(this,"geo_nodes",e)}allStatuses(e){return a.get()(this,"geo_nodes/statuses",e)}allFailures(e){return a.get()(this,"geo_nodes/current/failures",e)}create(e,t,r){return a.post()(this,"geo_nodes",{name:e,url:t,...r})}edit(e,t){return a.put()(this,`geo_nodes/${e}`,t)}repair(e,t){return a.post()(this,`geo_nodes/${e}/repair`,t)}remove(e,t){return a.del()(this,`geo_nodes/${e}`,t)}show(e,t){return a.get()(this,`geo_nodes/${e}`,t)}showStatus(e,t){return a.get()(this,`geo_nodes/${e}/status`,t)}};var se=class extends n.BaseResource{all(e){return a.get()(this,"geo_sites",e)}allStatuses(e){return a.get()(this,"geo_sites/statuses",e)}allFailures(e){return a.get()(this,"geo_sites/current/failures",e)}create(e,t,r){return a.post()(this,"geo_sites",{name:e,url:t,...r})}edit(e,t){return a.put()(this,`geo_sites/${e}`,t)}repair(e,t){return a.post()(this,`geo_sites/${e}/repair`,t)}remove(e,t){return a.del()(this,`geo_sites/${e}`,t)}show(e,t){return a.get()(this,`geo_sites/${e}`,t)}showStatus(e,t){return a.get()(this,`geo_sites/${e}/status`,t)}};var oe=class extends U{constructor(e){super("gitignores",e)}};var ie=class extends U{constructor(e){super("gitlab_ci_ymls",e)}};var ae=class extends n.BaseResource{importGithubRepository(e,t,r,n){return a.post()(this,"import/github",{personalAccessToken:e,repoId:t,targetNamespace:r,...n})}cancelGithubRepositoryImport(e,t){return a.post()(this,"import/github/cancel",{projectId:e,...t})}importGithubGists(e,t){return a.post()(this,"import/github/gists",{personalAccessToken:e,...t})}importBitbucketServerRepository(e,t,r,n,s,o){return a.post()(this,"import/bitbucket_server",{bitbucketServerUrl:e,bitbucketServerUsername:t,personalAccessToken:r,bitbucketServerProject:n,bitbucketServerRepo:s,...o})}};var ce=class extends n.BaseResource{all(e){return a.get()(this,"admin/ci/variables",e)}create(e,t,r){return a.post()(this,"admin/ci/variables",{key:e,value:t,...r})}edit(e,t,r){return a.put()(this,endpoint`admin/ci/variables/${e}`,{value:t,...r})}show(e,t){return a.get()(this,endpoint`admin/ci/variables/${e}`,t)}remove(e,t){return a.get()(this,endpoint`admin/ci/variables/${e}`,t)}};var ue=class extends n.BaseResource{show({keyId:e,fingerprint:t,...r}={}){let n;if(e)n=`keys/${e}`;else if(t)n=`keys?fingerprint=${t}`;else{throw new Error("Missing required argument. Please supply a fingerprint or a keyId in the options parameter")}return a.get()(this,n,r)}};var le=class extends n.BaseResource{add(e,t){return a.post()(this,"license",{searchParams:{license:e},...t})}all(e){return a.get()(this,"licenses",e)}show(e){return a.get()(this,"license",e)}remove(e,t){return a.del()(this,`license/${e}`,t)}recalculateBillableUsers(e,t){return a.put()(this,`license/${e}/refresh_billable_users`,t)}};var pe=class extends U{constructor(e){super("Licenses",e)}};var de=class extends n.BaseResource{check(e,t){return a.get()(this,endpoint`projects/${e}/ci/lint`,t)}lint(e,t,r){return a.post()(this,endpoint`projects/${e}/ci/lint`,{...r,content:t})}};var fe=class extends n.BaseResource{render(e,t){return a.post()(this,"markdown",{text:e,...t})}};var he=class extends n.BaseResource{downloadPackageFile(e,t,{projectId:r,groupId:n,...s}){let o=endpoint`packages/maven/${e}/${t}`;if(r)o=endpoint`projects/${r}/${o}`;else if(n)o=endpoint`groups/${n}/-/${o}`;return a.get()(this,o,s)}uploadPackageFile(e,t,r,n){return a.put()(this,endpoint`projects/${e}/packages/maven/${t}/${r.filename}`,{isForm:true,...n,file:[r.content,r.filename]})}};var ge=class extends n.BaseResource{show(e){return a.get()(this,"metadata",e)}};var me=class extends n.BaseResource{all(e){return a.get()(this,"bulk_imports",e)}create(e,t,r){return a.post()(this,"bulk_imports",{configuration:e,entities:t,...r})}allEntities({bulkImportId:e,...t}={}){const r=e?endpoint`bulk_imports/${e}/entities`:"bulk_imports/entities";return a.get()(this,r,t)}show(e,t){return a.get()(this,`bulk_imports/${e}`,t)}showEntity(e,t,r){return a.get()(this,`bulk_imports/${e}/entities/${t}`,r)}};var ye=class extends n.BaseResource{all(e){return a.get()(this,"namespaces",e)}exists(e,t){return a.get()(this,endpoint`namespaces/${e}/exists`,t)}show(e,t){return a.get()(this,endpoint`namespaces/${e}`,t)}};function url6({projectId:e,groupId:t}={}){let r="";if(e)r=endpoint`projects/${e}/`;if(t)r=endpoint`groups/${t}/`;return`${r}notification_settings`}var ve=class extends n.BaseResource{edit({groupId:e,projectId:t,...r}={}){const n=url6({groupId:e,projectId:t});return a.put()(this,n,r)}show({groupId:e,projectId:t,...r}={}){const n=url6({groupId:e,projectId:t});return a.get()(this,n,r)}};function url7(e){return e?endpoint`/projects/${e}/packages/npm`:"packages/npm"}var $e=class extends n.BaseResource{downloadPackageFile(e,t,r,n){return a.get()(this,endpoint`projects/${e}/packages/npm/${t}/-/${r}`,n)}removeDistTag(e,t,r){const n=url7(r?.projectId);return a.del()(this,`${n}/-/package/${e}/dist-tags/${t}`,r)}setDistTag(e,t,r){const n=url7(r?.projectId);return a.put()(this,`${n}/-/package/${e}/dist-tags/${t}`,r)}showDistTags(e,t){const r=url7(t?.projectId);return a.get()(this,`${r}/-/package/${e}/dist-tags`,t)}showMetadata(e,t){const r=url7(t?.projectId);return a.get()(this,`${r}/${e}`,t)}uploadPackageFile(e,t,r,n,s){return a.put()(this,endpoint`projects/${e}/packages/npm/${t}`,{...s,versions:r,...n})}};function url8({projectId:e,groupId:t}={}){if(e)return endpoint`/projects/${e}/packages/nuget`;if(t)return endpoint`/groups/${t}/-/packages/nuget`;throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter")}var be=class extends n.BaseResource{downloadPackageFile(e,t,r,n,s){return a.get()(this,endpoint`projects/${e}/packages/nuget/download/${t}/${r}/${n}`,s)}search(e,{projectId:t,groupId:r,...n}){const s=url8({projectId:t,groupId:r});return a.get()(this,`${s}/query`,{q:e,...n})}showMetadata(e,{projectId:t,groupId:r,...n}){const s=url8({projectId:t,groupId:r});return a.get()(this,`${s}/metadata/${e}/index`,n)}showPackageIndex(e,t,r){return a.get()(this,endpoint`projects/${e}/packages/nuget/download/${t}/index`,r)}showServiceIndex({projectId:e,groupId:t,...r}){const n=url8({projectId:e,groupId:t});return a.get()(this,`${n}/index`,r)}showVersionMetadata(e,t,{projectId:r,groupId:n,...s}){const o=url8({projectId:r,groupId:n});return a.get()(this,`${o}/metadata/${e}/${t}`,s)}uploadPackageFile(e,t,r,n,s){return a.put()(this,endpoint`projects/${e}/packages/nuget`,{isForm:true,...s,packageName:t,packageVersion:r,file:[n.content,n.filename]})}uploadSymbolPackage(e,t,r,n,s){return a.put()(this,endpoint`projects/${e}/packages/nuget/symbolpackage`,{isForm:true,...s,packageName:t,packageVersion:r,file:[n.content,n.filename]})}};var we=class extends n.BaseResource{all(e){return a.get()(this,"personal_access_tokens",e)}create(e,t,r,n){return a.post()(this,endpoint`users/${e}/personal_access_tokens`,{name:t,scopes:r,...n})}remove({tokenId:e,...t}={}){const r=e?endpoint`personal_access_tokens/${e}`:"personal_access_tokens/self";return a.del()(this,r,t)}rotate(e,t){return a.post()(this,endpoint`personal_access_tokens/${e}/rotate`,t)}show({tokenId:e,...t}={}){const r=e?endpoint`personal_access_tokens/${e}`:"personal_access_tokens/self";return a.get()(this,r,t)}};var _e=class extends n.BaseResource{downloadPackageFile(e,t,{projectId:r,groupId:n,...s}={}){let o;if(r){o=endpoint`projects/${r}/packages/pypi/files/${e}/${t}`}else if(n){o=endpoint`groups/${n}/packages/pypi/files/${e}/${t}`}else{throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter")}return a.get()(this,o,s)}showPackageDescriptor(e,{projectId:t,groupId:r,...n}){let s;if(t){s=endpoint`projects/${t}/packages/pypi/simple/${e}`}else if(r){s=endpoint`groups/${r}/packages/pypi/simple/${e}`}else{throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter")}return a.get()(this,s,n)}uploadPackageFile(e,t,r){return a.put()(this,endpoint`projects/${e}/packages/pypi`,{...r,isForm:true,file:[t.content,t.filename]})}};var Ee=class extends n.BaseResource{allDependencies(e,t){return a.get()(this,endpoint`projects/${e}/packages/rubygems/api/v1/dependencies`,t)}downloadGemFile(e,t,r){return a.get()(this,endpoint`projects/${e}/packages/rubygems/gems/${t}`,r)}uploadGemFile(e,t,r){return a.post()(this,`projects/${e}/packages/rubygems/api/v1/gems`,{isForm:true,...r,file:[t.content,t.filename]})}};var Se=class extends n.BaseResource{all(e,t,r){const{projectId:n,groupId:s,...o}=r||{};let i;if(n)i=endpoint`projects/${n}/`;else if(s)i=endpoint`groups/${s}/`;else i="";return a.get()(this,`${i}search`,{scope:e,search:t,...o})}};var Ae=class extends n.BaseResource{all(e){return a.get()(this,"admin/search/migrations",e)}show(e,t){return a.get()(this,endpoint`admin/search/migrations/${e}`,t)}};var je=class extends n.BaseResource{create(e){return a.post()(this,endpoint`service_accounts`,e)}};var Re=class extends n.BaseResource{showMetricDefinitions(e){return a.get()(this,"usage_data/metric_definitions",e)}showServicePingSQLQueries(e){return a.get()(this,"usage_data/queries",e)}showUsageDataNonSQLMetrics(e){return a.get()(this,"usage_data/non_sql_metrics",e)}};var xe=class extends n.BaseResource{queueMetrics(){return a.get()(this,"sidekiq/queue_metrics")}processMetrics(){return a.get()(this,"sidekiq/process_metrics")}jobStats(){return a.get()(this,"sidekiq/job_stats")}compoundMetrics(){return a.get()(this,"sidekiq/compound_metrics")}};var ke=class extends n.BaseResource{remove(e,t){return a.get()(this,endpoint`admin/sidekiq/queues/${e}`,t)}};var Ie=class extends Y{constructor(e){super("snippets",e)}};var Pe=class extends n.BaseResource{all({public:e,...t}={}){const r=e?"snippets/public":"snippets";return a.get()(this,r,t)}create(e,t){return a.post()(this,"snippets",{title:e,...t})}edit(e,t){return a.put()(this,`snippets/${e}`,t)}remove(e,t){return a.del()(this,`snippets/${e}`,t)}show(e,t){return a.get()(this,`snippets/${e}`,t)}showContent(e,t){return a.get()(this,`snippets/${e}/raw`,t)}showRepositoryFileContent(e,t,r,n){return a.get()(this,endpoint`snippets/${e}/files/${t}/${r}/raw`,n)}showUserAgentDetails(e,t){return a.get()(this,`snippets/${e}/user_agent_detail`,t)}};var Ce=class extends n.BaseResource{edit(e,t){return a.put()(this,`suggestions/${e}/apply`,t)}editBatch(e,t){return a.put()(this,`suggestions/batch_apply`,{...t,ids:e})}};var Te=class extends n.BaseResource{all(e){return a.get()(this,"hooks",e)}add(e,t){return this.create(e,t)}create(e,t){return a.post()(this,"hooks",{url:e,...t})}test(e,t){return a.post()(this,`hooks/${e}`,t)}remove(e,t){return a.del()(this,`hooks/${e}`,t)}show(e,t){return a.post()(this,`hooks/${e}`,t)}};var Oe=class extends n.BaseResource{all(e){return a.get()(this,"todos",e)}done({todoId:e,...t}={}){let r="todos";if(e)r+=`/${e}`;return a.post()(this,`${r}/mark_as_done`,t)}};var Me=class extends n.BaseResource{all(e){return a.get()(this,"topics",e)}create(e,{avatar:t,...r}={}){const n={name:e,...r};if(t){n.isForm=true;n.file=[t.content,t.filename]}return a.post()(this,"topics",n)}edit(e,{avatar:t,...r}={}){const n={...r};if(t){n.isForm=true;n.file=[t.content,t.filename]}return a.put()(this,`topics/${e}`,n)}merge(e,t,r){return a.post()(this,`topics/merge`,{sourceTopicId:e,targetTopicId:t,...r})}remove(e,t){return a.del()(this,`topics/${e}`,t)}show(e,t){return a.get()(this,`topics/${e}`,t)}};var Ne=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/repository/branches`,t)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/repository/branches`,{branch:t,ref:r,...n})}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/repository/branches/${t}`,r)}removeMerged(e,t){return a.del()(this,endpoint`projects/${e}/repository/merged_branches`,t)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/branches/${t}`,r)}};var Le=class extends O{constructor(e){super("projects","repository/commits",e)}};var Fe=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/repository/commits`,t)}allComments(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}/comments`,r)}allDiscussions(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}/discussions`,r)}allMergeRequests(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}/merge_requests`,r)}allReferences(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}/refs`,r)}allStatuses(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}/statuses`,r)}cherryPick(e,t,r,n){return a.post()(this,endpoint`projects/${e}/repository/commits/${t}/cherry_pick`,{branch:r,...n})}create(e,t,r,n=[],s={}){return a.post()(this,endpoint`projects/${e}/repository/commits`,{branch:t,commitMessage:r,actions:n,...s})}createComment(e,t,r,n){return a.post()(this,endpoint`projects/${e}/repository/commits/${t}/comments`,{note:r,...n})}editStatus(e,t,r,n){return a.post()(this,endpoint`projects/${e}/statuses/${t}`,{state:r,...n})}revert(e,t,r,n){return a.post()(this,endpoint`projects/${e}/repository/commits/${t}/revert`,{...n,branch:r})}show(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}`,r)}showDiff(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}/diff`,r)}showGPGSignature(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/commits/${t}/signature`,r)}};var Be=class extends n.BaseResource{allRepositories({groupId:e,projectId:t,...r}={}){let n;if(e)n=endpoint`groups/${e}/registry/repositories`;else if(t)n=endpoint`projects/${t}/registry/repositories`;else throw new Error("Missing required argument. Please supply a groupId or a projectId in the options parameter.");return a.get()(this,n,r)}allTags(e,t,r){return a.get()(this,endpoint`projects/${e}/registry/repositories/${t}/tags`,r)}editRegistryVisibility(e,t){return a.get()(this,endpoint`projects/${e}`,t)}removeRepository(e,t,r){return a.del()(this,endpoint`projects/${e}/registry/repositories/${t}`,r)}removeTag(e,t,r,n){return a.del()(this,endpoint`projects/${e}/registry/repositories/${t}/tags/${r}`,n)}removeTags(e,t,r,n){return a.del()(this,endpoint`projects/${e}/registry/repositories/${t}/tags`,{nameRegexDelete:r,...n})}showRepository(e,t){return a.get()(this,endpoint`registry/repositories/${e}`,t)}showTag(e,t,r,n){return a.get()(this,endpoint`projects/${e}/registry/repositories/${t}/tags/${r}`,n)}};var De=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/deployments`,t)}allMergeRequests(e,t,r){return a.get()(this,endpoint`projects/${e}/deployments/${t}/merge_requests`,r)}create(e,t,r,n,s,o){return a.post()(this,endpoint`projects/${e}/deployments`,{environment:t,sha:r,ref:n,tag:s,...o})}edit(e,t,r,n){return a.put()(this,endpoint`projects/${e}/deployments/${t}`,{...n,status:r})}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/deployments/${t}`,r)}setApproval(e,t,r,n){return a.post()(this,endpoint`projects/${e}/deployments/${t}/approval`,{...n,status:r})}show(e,t,r){return a.get()(this,endpoint`projects/${e}/deployments/${t}`,r)}};var Ue=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/environments`,t)}create(e,t,r){return a.post()(this,endpoint`projects/${e}/environments`,{name:t,...r})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/environments/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/environments/${t}`,r)}removeReviewApps(e,t){return a.del()(this,endpoint`projects/${e}/environments/review_apps`,t)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/environments/${t}`,r)}stop(e,t,r){return a.post()(this,endpoint`projects/${e}/environments/${t}/stop`,r)}stopStale(e,t,r){return a.post()(this,endpoint`projects/${e}/environments/stop_stale`,{searchParams:{before:t},...r})}};var Ge=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/error_tracking/client_keys`,t)}create(e,t){return a.post()(this,endpoint`projects/${e}/error_tracking/client_keys`,t)}remove(e,t){return a.del()(this,endpoint`projects/${e}/error_tracking/client_keys`,t)}};var qe=class extends n.BaseResource{create(e,t,r,n){return a.put()(this,endpoint`projects/${e}/error_tracking/settings`,{searchParams:{active:t,integrated:r},...n})}edit(e,t,{integrated:r,...n}={}){return a.patch()(this,endpoint`projects/${e}/error_tracking/settings`,{searchParams:{active:t,integrated:r},...n})}show(e,t){return a.get()(this,endpoint`projects/${e}/error_tracking/settings`,t)}};var He=class extends n.BaseResource{all(e,t){const{mergerequestIId:r,...n}=t||{};let s=endpoint`projects/${e}`;if(r){s+=endpoint`/merge_requests/${r}/status_checks`}else{s+="/external_status_checks"}return a.get()(this,s,n)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/external_status_checks`,{name:t,externalUrl:r,...n})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/external_status_checks/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/external_status_checks/${t}`,r)}set(e,t,r,n,s){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/status_check_responses`,{sha:r,externalStatusCheckId:n,...s})}};var Ke=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/feature_flags`,t)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/feature_flags`,{name:t,version:r,...n})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/feature_flags/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/feature_flags/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/feature_flags/${t}`,r)}};var Ye=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/feature_flags_user_lists`,t)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/feature_flags_user_lists`,{name:t,userXids:r,...n})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/feature_flags_user_lists/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/feature_flags_user_lists/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/feature_flags_user_lists/${t}`,r)}};var We=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/freeze_periods`,t)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/freeze_periods`,{freezeStart:t,freezeEnd:r,...n})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/freeze_periods/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/freeze_periods/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/freeze_periods/${t}`,r)}};var ze=class extends n.BaseResource{remove(e,t){return a.del()(this,endpoint`projects/${e}/pages`,t)}};var Ve=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`projects/${e}/packages/go/${t}/@v/list`,r)}showVersionMetadata(e,t,r,n){return a.get()(this,endpoint`projects/${e}/packages/go/${t}/@v/${r}.info`,n)}downloadModuleFile(e,t,r,n){return a.get()(this,endpoint`projects/${e}/packages/go/${t}/@v/${r}.mod`,n)}downloadModuleSource(e,t,r,n){return a.get()(this,endpoint`projects/${e}/packages/go/${t}/@v/${r}.zip`,n)}};var Qe=class extends n.BaseResource{downloadChartIndex(e,t,r){return a.get()(this,endpoint`projects/${e}/packages/helm/${t}/index.yaml`,r)}downloadChart(e,t,r,n){return a.get()(this,endpoint`projects/${e}/packages/helm/${t}/charts/${r}.tgz`,n)}import(e,t,r,n){return a.post()(this,endpoint`projects/${e}/packages/helm/api/${t}/charts`,{isForm:true,...n,chart:[r.content,r.filename]})}};var Je=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/integrations`,t)}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/integrations/${t}`,r)}disable(e,t,r){return a.del()(this,endpoint`projects/${e}/integrations/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/integrations/${t}`,r)}};var Xe=class extends k{constructor(e){super("projects","issues",e)}};var Ze=class extends O{constructor(e){super("projects","issues",e)}};var et=class extends Q{constructor(e){super("projects","issues",e)}};var tt=class extends J{constructor(e){super("projects","issues",e)}};var rt=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`projects/${e}/issues/${t}/links`,r)}create(e,t,r,n,s){return a.post()(this,endpoint`projects/${e}/issues/${t}/links`,{targetProjectId:r,targetIssueIid:n,...s})}remove(e,t,r,n){return a.del()(this,endpoint`projects/${e}/issues/${t}/links/${r}`,n)}};var nt=class extends X{constructor(e){super("projects","issues",e)}};var st=class extends I{constructor(e){super("issues",e)}};var ot=class extends D{constructor(e){super("projects","issues",e)}};var it=class extends n.BaseResource{addSpentTime(e,t,r,n){return a.post()(this,endpoint`projects/${e}/issues/${t}/add_spent_time`,{duration:r,...n})}addTimeEstimate(e,t,r,n){return a.post()(this,endpoint`projects/${e}/issues/${t}/time_estimate`,{duration:r,...n})}all({projectId:e,groupId:t,...r}={}){let n;if(e)n=endpoint`projects/${e}/issues`;else if(t)n=endpoint`groups/${t}/issues`;else n="issues";return a.get()(this,n,r)}allMetricImages(e,t,r){return a.get()(this,endpoint`projects/${e}/issues/${t}/metric_images`,r)}allParticipants(e,t,r){return a.get()(this,endpoint`projects/${e}/issues/${t}/participants`,r)}allRelatedMergeRequests(e,t,r){return a.get()(this,endpoint`projects/${e}/issues/${t}/related_merge_requests`,r)}create(e,t,r){return a.post()(this,endpoint`projects/${e}/issues`,{...r,title:t})}createTodo(e,t,r){return a.post()(this,endpoint`projects/${e}/issues/${t}/todo`,r)}clone(e,t,r,n){return a.post()(this,endpoint`projects/${e}/issues/${t}/clone`,{toProjectId:r,...n})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/issues/${t}`,r)}editMetricImage(e,t,r,n){return a.put()(this,endpoint`projects/${e}/issues/${t}/metric_images/${r}`,n)}move(e,t,r,n){return a.post()(this,endpoint`projects/${e}/issues/${t}/move`,{toProjectId:r,...n})}promote(e,t,r,n){return a.post()(this,endpoint`projects/${e}/issues/${t}/notes`,{searchParams:{body:`${r} \n /promote`},...n})}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/issues/${t}`,r)}removeMetricImage(e,t,r,n){return a.del()(this,endpoint`projects/${e}/issues/${t}/metric_images/${r}`,n)}reorder(e,t,r){return a.put()(this,endpoint`projects/${e}/issues/${t}/reorder`,r)}resetSpentTime(e,t,r){return a.post()(this,endpoint`projects/${e}/issues/${t}/reset_spent_time`,r)}resetTimeEstimate(e,t,r){return a.post()(this,endpoint`projects/${e}/issues/${t}/reset_time_estimate`,r)}show(e,{projectId:t,...r}={}){const n=t?endpoint`projects/${t}/issues/${e}`:`issues/${e}`;return a.get()(this,n,r)}subscribe(e,t,r){return a.post()(this,endpoint`projects/${e}/issues/${t}/subscribe`,r)}allClosedByMergeRequestst(e,t,r){return a.get()(this,endpoint`projects/${e}/issues/${t}/closed_by`,r)}showTimeStats(e,t,r){return a.get()(this,endpoint`projects/${e}/issues/${t}/time_stats`,r)}unsubscribe(e,t,r){return a.post()(this,endpoint`projects/${e}/issues/${t}/unsubscribe`,r)}uploadMetricImage(e,t,r,n){return a.post()(this,endpoint`projects/${e}/issues/${t}/metric_images`,{isForm:true,...n,file:[r.content,r.filename]})}showUserAgentDetails(e,t,r){return a.get()(this,endpoint`projects/${e}/issues/${t}/user_agent_details`,r)}};var at=class extends n.BaseResource{all({projectId:e,groupId:t,...r}={}){let n;if(e)n=endpoint`projects/${e}/issues_statistics`;else if(t)n=endpoint`groups/${t}/issues_statistics`;else n="issues_statistics";return a.get()(this,n,r)}};var ct=class extends Z{constructor(e){super("projects","issues",e)}};var ut=class extends Z{constructor(e){super("projects","issues",e)}};function generateDownloadPathForJob(e,t,r){let n=endpoint`projects/${e}/jobs/${t}/artifacts`;if(r)n+=`/${r}`;return n}function generateDownloadPath(e,t,r){let n=endpoint`projects/${e}/jobs/artifacts/${t}`;if(r){n+=endpoint`/raw/${r}`}else{n+=endpoint`/download`}return n}var lt=class extends n.BaseResource{downloadArchive(e,{jobId:t,artifactPath:r,ref:n,...s}={}){let o;if(t)o=generateDownloadPathForJob(e,t,r);else if(s?.job&&n)o=generateDownloadPath(e,n,r);else throw new Error("Missing one of the required parameters. See typing documentation for available arguments.");return a.get()(this,o,s)}keep(e,t,r){return a.post()(this,endpoint`projects/${e}/jobs/${t}/artifacts/keep`,r)}remove(e,{jobId:t,...r}={}){let n;if(t){n=endpoint`projects/${e}/jobs/${t}/artifacts`}else{n=endpoint`projects/${e}/artifacts`}return a.del()(this,n,r)}};var pt=class extends n.BaseResource{all(e,{pipelineId:t,...r}={}){const n=t?endpoint`projects/${e}/pipelines/${t}/jobs`:endpoint`projects/${e}/jobs`;return a.get()(this,n,r)}allPipelineBridges(e,t,r){return a.get()(this,endpoint`projects/${e}/pipelines/${t}/bridges`,r)}cancel(e,t,r){return a.post()(this,endpoint`projects/${e}/jobs/${t}/cancel`,r)}erase(e,t,r){return a.post()(this,endpoint`projects/${e}/jobs/${t}/erase`,r)}play(e,t,r){return a.post()(this,endpoint`projects/${e}/jobs/${t}/play`,r)}retry(e,t,r){return a.post()(this,endpoint`projects/${e}/jobs/${t}/retry`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/jobs/${t}`,r)}showConnectedJob(e){if(!this.headers["job-token"])throw new Error('Missing required header "job-token"');return a.get()(this,"job",e)}showConnectedJobK8Agents(e){if(!this.headers["job-token"])throw new Error('Missing required header "job-token"');return a.get()(this,"job/allowed_agents",e)}showLog(e,t,r){return a.get()(this,endpoint`projects/${e}/jobs/${t}/trace`,r)}};var dt=class extends n.BaseResource{allApprovalRules(e,{mergerequestIId:t,...r}={}){let n;if(t){n=endpoint`projects/${e}/merge_requests/${t}/approval_rules`}else{n=endpoint`projects/${e}/approval_rules`}return a.get()(this,n,r)}approve(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/approve`,r)}createApprovalRule(e,t,r,{mergerequestIId:n,...s}={}){let o;if(n){o=endpoint`projects/${e}/merge_requests/${n}/approval_rules`}else{o=endpoint`projects/${e}/approval_rules`}return a.post()(this,o,{name:t,approvalsRequired:r,...s})}editApprovalRule(e,t,r,n,{mergerequestIId:s,...o}={}){let i;if(s){i=endpoint`projects/${e}/merge_requests/${s}/approval_rules/${t}`}else{i=endpoint`projects/${e}/approval_rules/${t}`}return a.put()(this,i,{name:r,approvalsRequired:n,...o})}editConfiguration(e,t){return a.post()(this,endpoint`projects/${e}/approvals`,t)}removeApprovalRule(e,t,{mergerequestIId:r,...n}={}){let s;if(r){s=endpoint`projects/${e}/merge_requests/${r}/approval_rules/${t}`}else{s=endpoint`projects/${e}/approval_rules/${t}`}return a.del()(this,s,n)}showApprovalRule(e,t,r){return a.get()(this,endpoint`projects/${e}/approval_rules/${t}`,r)}showApprovalState(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/approval_state`,r)}showConfiguration(e,{mergerequestIId:t,...r}={}){let n;if(t){n=endpoint`projects/${e}/merge_requests/${t}/approvals`}else{n=endpoint`projects/${e}/approvals`}return a.get()(this,n,r)}unapprove(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/unapprove`,r)}};var ft=class extends k{constructor(e){super("projects","merge_requests",e)}};var ht=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/context_commits`,r)}create(e,t,{mergerequestIId:r,...n}={}){const s=endpoint`projects/${e}/merge_requests`;const o=r?`${s}/${r}/context_commits`:s;return a.post()(this,o,{commits:t,...n})}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/merge_requests/${t}/context_commits`,r)}};var gt=class extends O{constructor(e){super("projects","merge_requests",e)}resolve(e,t,r,n,s){return a.put()(this,endpoint`${e}/merge_requests/${t}/discussions/${r}`,{searchParams:{resolved:n},...s})}};var mt=class extends J{constructor(e){super("projects","merge_requests",e)}};var yt=class extends X{constructor(e){super("projects","merge_requests",e)}};var vt=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/draft_notes`,r)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/draft_notes`,{...n,note:r})}edit(e,t,r,n){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/draft_notes/${r}`,n)}publish(e,t,r,n){return a.put()(this,endpoint`projects/${e}/merge_requests/${t}/draft_notes/${r}/publish`,n)}publishBulk(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/draft_notes/bulk_publish`,r)}remove(e,t,r,n){return a.del()(this,endpoint`projects/${e}/merge_requests/${t}/draft_notes/${r}`,n)}show(e,t,r,n){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/draft_notes/${r}`,n)}};var $t=class extends D{constructor(e){super("projects","merge_requests",e)}};var bt=class extends I{constructor(e){super("merge_requests",e)}};var wt=class extends n.BaseResource{accept(e,t,r){return this.merge(e,t,r)}addSpentTime(e,t,r,n){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/add_spent_time`,{duration:r,...n})}all({projectId:e,groupId:t,...r}={}){let n="";if(e){n=endpoint`projects/${e}/`}else if(t){n=endpoint`groups/${t}/`}return a.get()(this,`${n}merge_requests`,r)}allDiffs(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/diffs`,r)}allCommits(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/commits`,r)}allDiffVersions(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/versions`,r)}allIssuesClosed(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/closes_issues`,r)}allParticipants(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/participants`,r)}allPipelines(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/pipelines`,r)}cancelOnPipelineSuccess(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/cancel_merge_when_pipeline_succeeds`,r)}create(e,t,r,n,s){return a.post()(this,endpoint`projects/${e}/merge_requests`,{sourceBranch:t,targetBranch:r,title:n,...s})}createPipeline(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/pipelines`,r)}createTodo(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/todo`,r)}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/merge_requests/${t}`,r)}merge(e,t,r){return a.put()(this,endpoint`projects/${e}/merge_requests/${t}/merge`,r)}mergeToDefault(e,t,r){return a.put()(this,endpoint`projects/${e}/merge_requests/${t}/merge_ref`,r)}rebase(e,t,r){return a.put()(this,endpoint`projects/${e}/merge_requests/${t}/rebase`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/merge_requests/${t}`,r)}resetSpentTime(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/reset_spent_time`,r)}resetTimeEstimate(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/reset_time_estimate`,r)}setTimeEstimate(e,t,r,n){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/time_estimate`,{duration:r,...n})}show(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}`,r)}showChanges(e,t,r){process.emitWarning('This endpoint was deprecated in Gitlab API 15.7 and will be removed in API v5. Please use the "allDiffs" function instead.',"DeprecationWarning");return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/changes`,r)}showDiffVersion(e,t,r,n){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/versions/${r}`,n)}showTimeStats(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_requests/${t}/time_stats`,r)}subscribe(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/subscribe`,r)}unsubscribe(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_requests/${t}/unsubscribe`,r)}};var _t=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/merge_trains`,t)}showStatus(e,t,r){return a.get()(this,endpoint`projects/${e}/merge_trains/merge_requests/${t}`,r)}addMergeRequest(e,t,r){return a.post()(this,endpoint`projects/${e}/merge_trains/merge_requests/${t}`,r)}};var Et=class extends n.BaseResource{publish(e,t,r,n,{contentType:s,...o}={}){return a.put()(this,endpoint`projects/${e}/packages/generic/${t}/${r}/${n.filename}`,{isForm:true,file:[n.content,n.filename],...o})}download(e,t,r,n,s){return a.get()(this,endpoint`projects/${e}/packages/generic/${t}/${r}/${n}`,s)}};var St=class extends n.BaseResource{all({projectId:e,groupId:t,...r}={}){let n;if(e)n=endpoint`projects/${e}/packages`;else if(t)n=endpoint`groups/${t}/packages`;else{throw new Error("Missing required argument. Please supply a projectId or a groupId in the options parameter.")}return a.get()(this,n,r)}allFiles(e,t,r){return a.get()(this,endpoint`projects/${e}/packages/${t}/package_files`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/packages/${t}`,r)}removeFile(e,t,r,n){return a.del()(this,endpoint`projects/${e}/packages/${t}/package_files/${r}`,n)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/packages/${t}`,r)}};var At=class extends n.BaseResource{all({projectId:e,...t}={}){const r=e?endpoint`projects/${e}/`:"";return a.get()(this,`${r}pages/domains`,t)}create(e,t,r){return a.post()(this,endpoint`projects/${e}/pages/domains`,{domain:t,...r})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/pages/domains/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/pages/domains/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/pages/domains/${t}`,r)}};var jt=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/pipelines`,t)}allVariables(e,t,r){return a.get()(this,endpoint`projects/${e}/pipelines/${t}/variables`,r)}cancel(e,t,r){return a.post()(this,endpoint`projects/${e}/pipelines/${t}/cancel`,r)}create(e,t,r){return a.post()(this,endpoint`projects/${e}/pipeline`,{ref:t,...r})}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/pipelines/${t}`,r)}retry(e,t,r){return a.post()(this,endpoint`projects/${e}/pipelines/${t}/retry`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/pipelines/${t}`,r)}showTestReport(e,t,r){return a.get()(this,endpoint`projects/${e}/pipelines/${t}/test_report`,r)}showTestReportSummary(e,t,r){return a.get()(this,endpoint`projects/${e}/pipelines/${t}/test_report_summary`,r)}};var Rt=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/pipeline_schedules`,t)}allTriggeredPipelines(e,t,r){return a.get()(this,endpoint`projects/${e}/pipeline_schedules/${t}/pipelines`,r)}create(e,t,r,n,s){return a.post()(this,endpoint`projects/${e}/pipeline_schedules`,{description:t,ref:r,cron:n,...s})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/pipeline_schedules/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/pipeline_schedules/${t}`,r)}run(e,t,r){return a.post()(this,endpoint`projects/${e}/pipeline_schedules/${t}/play`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/pipeline_schedules/${t}`,r)}takeOwnership(e,t,r){return a.post()(this,endpoint`projects/${e}/pipeline_schedules/${t}/take_ownership`,r)}};var xt=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`projects/${e}/pipeline_schedules/${t}/variables`,r)}create(e,t,r,n,s){return a.post()(this,endpoint`projects/${e}/pipeline_schedules/${t}/variables`,{...s,key:r,value:n})}edit(e,t,r,n,s){return a.put()(this,endpoint`projects/${e}/pipeline_schedules/${t}/variables/${r}`,{...s,value:n})}remove(e,t,r,n){return a.del()(this,endpoint`projects/${e}/pipeline_schedules/${t}/variables/${r}`,n)}};var kt=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/triggers`,t)}create(e,t,r){return a.post()(this,endpoint`projects/${e}/triggers`,{description:t,...r})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/triggers/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/triggers/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/triggers/${t}`,r)}trigger(e,t,r,{variables:n,...s}={}){const o={...s,searchParams:{token:r,ref:t}};if(n){o.isForm=true;Object.assign(o,reformatObjectOptions(n,"variables"))}return a.post()(this,endpoint`projects/${e}/trigger/pipeline`,o)}};var It=class extends n.BaseResource{allFunnels(e,t){return a.get()(this,endpoint`projects/${e}/product_analytics/funnels`,t)}load(e,t){return a.post()(this,endpoint`projects/${e}/product_analytics/request/load`,t)}dryRun(e,t){return a.post()(this,endpoint`projects/${e}/product_analytics/request/dry-run`,t)}showMetadata(e,t){return a.get()(this,endpoint`projects/${e}/product_analytics/request/meta`,t)}};var Pt=class extends R{constructor(e){super("projects",e)}};var Ct=class extends x{constructor(e){super("projects",e)}};var Tt=class extends n.BaseResource{all(e){return a.get()(this,"project_aliases",e)}create(e,t,r){return a.post()(this,"project_aliases",{name:t,projectId:e,...r})}edit(e,t){return a.post()(this,`project_aliases/${e}`,t)}remove(e,t){return a.del()(this,`project_aliases/${e}`,t)}};var Ot=class extends P{constructor(e){super("projects",e)}};var Mt=class extends C{constructor(e){super("projects",e)}};var Nt=class extends T{constructor(e){super("projects",e)}};var Lt=class extends H{constructor(e){super("projects",e)}};var Ft=class extends n.BaseResource{download(e,t){return a.get()(this,endpoint`projects/${e}/export/download`,t)}import(e,t,r){return a.post()(this,"projects/import",{isForm:true,...r,file:[e.content,e.filename],path:t})}importRemote(e,t,r){return a.post()(this,"projects/remote-import",{...r,path:t,url:e})}importRemoteS3(e,t,r,n,s,o,i){return a.post()(this,"projects/remote-import",{...i,accessKeyId:e,bucketName:t,fileKey:r,path:n,region:s,secretAccessKey:o})}showExportStatus(e,t){return a.get()(this,endpoint`projects/${e}/export`,t)}showImportStatus(e,t){return a.get()(this,endpoint`projects/${e}/import`,t)}scheduleExport(e,t,r){return a.post()(this,endpoint`projects/${e}/export`,{...r,upload:t})}};var Bt=class extends W{constructor(e){super("projects",e)}};var Dt=class extends M{constructor(e){super("projects",e)}};var Ut=class extends z{constructor(e){super("project",e)}};var Gt=class extends N{constructor(e){super("projects",e)}};var qt=class extends L{constructor(e){super("projects",e)}};var Ht=class extends B{constructor(e){super("projects",e)}promote(e,t,r){return a.post()(this,endpoint`${e}/milestones/${t}/promote`,r)}};var Kt=class extends V{constructor(e){super("groups",e)}};var Yt=class extends K{constructor(e){super("projects",e)}};var Wt=class extends n.BaseResource{download(e,t,r){return a.get()(this,endpoint`projects/${e}/export_relations/download`,{relation:t,...r})}showExportStatus(e,t){return a.get()(this,endpoint`projects/${e}/export_relations/status`,t)}scheduleExport(e,t){return a.post()(this,endpoint`projects/${e}/export_relations`,t)}};var zt=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/releases`,t)}create(e,t){return a.post()(this,endpoint`projects/${e}/releases`,t)}createEvidence(e,t,r){return a.post()(this,endpoint`projects/${e}/releases/${t}/evidence`,r)}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/releases/${t}`,r)}download(e,t,r,n){return a.get()(this,endpoint`projects/${e}/releases/${t}/downloads/${r}`,n)}downloadLatest(e,t,r){return a.get()(this,endpoint`projects/${e}/releases/permalink/latest/downloads/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/releases/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/releases/${t}`,r)}showLatest(e,t){return a.get()(this,endpoint`projects/${e}/releases/permalink/latest`,t)}showLatestEvidence(e,t){return a.get()(this,endpoint`projects/${e}/releases/permalink/latest/evidence`,t)}};var Vt=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/remote_mirrors`,t)}createPullMirror(e,t,r,n){return a.post()(this,endpoint`projects/${e}/mirror/pull`,{importUrl:t,mirror:r,...n})}createPushMirror(e,t,r){return a.post()(this,endpoint`projects/${e}/remote_mirrors`,{url:t,...r})}edit(e,t,r){return a.post()(this,endpoint`projects/${e}/remote_mirrors/${t}`,r)}remove(e,t){return a.del()(this,`project_aliases/${e}`,t)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/remote_mirrors/${t}`,r)}};var Qt=class extends Y{constructor(e){super("projects",e)}};var Jt=class extends n.BaseResource{all({userId:e,starredOnly:t,...r}={}){let n;if(e&&t)n=endpoint`users/${e}/starred_projects`;else if(e)n=endpoint`users/${e}/projects`;else n="projects";return a.get()(this,n,r)}allTransferLocations(e,t){return a.get()(this,endpoint`projects/${e}/transfer_locations`,t)}allUsers(e,t){return a.get()(this,endpoint`projects/${e}/users`,t)}allGroups(e,t){return a.get()(this,endpoint`projects/${e}/groups`,t)}allSharableGroups(e,t){return a.get()(this,endpoint`projects/${e}/share_locations`,t)}allForks(e,t){return a.get()(this,endpoint`projects/${e}/forks`,t)}allStarrers(e,t){return a.get()(this,endpoint`projects/${e}/starrers`,t)}allStoragePaths(e,t){return a.get()(this,endpoint`projects/${e}/storage`,t)}archive(e,t){return a.post()(this,endpoint`projects/${e}/archive`,t)}create({userId:e,avatar:t,...r}={}){const n=e?`projects/user/${e}`:"projects";if(t){return a.post()(this,n,{...r,isForm:true,avatar:[t.content,t.filename]})}return a.post()(this,n,{...r,avatar:t})}createForkRelationship(e,t,r){return a.post()(this,endpoint`projects/${e}/fork/${t}`,r)}createPullMirror(e,t,r,n){return a.post()(this,endpoint`projects/${e}/mirror/pull`,{importUrl:t,mirror:r,...n})}downloadSnapshot(e,t){return a.get()(this,endpoint`projects/${e}/snapshot`,t)}edit(e,{avatar:t,...r}={}){const n=endpoint`projects/${e}`;if(t){return a.put()(this,n,{...r,isForm:true,avatar:[t.content,t.filename]})}return a.put()(this,n,{...r,avatar:t})}fork(e,t){return a.post()(this,endpoint`projects/${e}/fork`,t)}housekeeping(e,t){return a.post()(this,endpoint`projects/${e}/housekeeping`,t)}importProjectMembers(e,t,r){return a.post()(this,endpoint`projects/${e}/import_project_members/${t}`,r)}remove(e,t){return a.del()(this,endpoint`projects/${e}`,t)}removeForkRelationship(e,t){return a.del()(this,endpoint`projects/${e}/fork`,t)}removeAvatar(e,t){return a.put()(this,endpoint`projects/${e}`,{...t,avatar:""})}restore(e,t){return a.post()(this,endpoint`projects/${e}/restore`,t)}search(e,t){return a.get()(this,"projects",{search:e,...t})}share(e,t,r,n){return a.post()(this,endpoint`projects/${e}/share`,{groupId:t,groupAccess:r,...n})}show(e,t){return a.get()(this,endpoint`projects/${e}`,t)}showLanguages(e,t){return a.get()(this,endpoint`projects/${e}/languages`,t)}showPullMirror(e,t){return a.get()(this,endpoint`projects/${e}/mirror/pull`,t)}star(e,t){return a.post()(this,endpoint`projects/${e}/star`,t)}transfer(e,t,r){return a.put()(this,endpoint`projects/${e}/transfer`,{...r,namespace:t})}unarchive(e,t){return a.post()(this,endpoint`projects/${e}/unarchive`,t)}unshare(e,t,r){return a.del()(this,endpoint`projects/${e}/share/${t}`,r)}unstar(e,t){return a.post()(this,endpoint`projects/${e}/unstar`,t)}uploadForReference(e,t,r){return a.post()(this,endpoint`projects/${e}/uploads`,{...r,isForm:true,file:[t.content,t.filename]})}uploadAvatar(e,t,r){return a.put()(this,endpoint`projects/${e}`,{...r,isForm:true,avatar:[t.content,t.filename]})}};var Xt=class extends k{constructor(e){super("projects","snippets",e)}};var Zt=class extends O{constructor(e){super("projects","snippets",e)}};var er=class extends D{constructor(e){super("projects","snippets",e)}};var tr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/snippets`,t)}create(e,t,r){return a.post()(this,endpoint`projects/${e}/snippets`,{title:t,...r})}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/snippets/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/snippets/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/snippets/${t}`,r)}showContent(e,t,r){return a.get()(this,endpoint`projects/${e}/snippets/${t}/raw`,r)}showRepositoryFileContent(e,t,r,n,s){return a.get()(this,endpoint`projects/${e}/snippets/${t}/files/${r}/${n}/raw`,s)}showUserAgentDetails(e,t,r){return a.get()(this,endpoint`projects/${e}/snippets/${t}/user_agent_detail`,r)}};var rr=class extends n.BaseResource{show(e,t){return a.get()(this,endpoint`projects/${e}/statistics`,t)}};var nr=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`projects/${e}/templates/${t}`,r)}show(e,t,r,n){return a.get()(this,endpoint`projects/${e}/templates/${t}/${r}`,n)}};var sr=class extends G{constructor(e){super("projects",e)}};var or=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/vulnerabilities`,t)}create(e,t,r){return a.post()(this,endpoint`projects/${e}/vulnerabilities`,{...r,searchParams:{findingId:t}})}};var ir=class extends q{constructor(e){super("projects",e)}};var ar=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/protected_branches`,t)}create(e,t,r){const{sudo:n,showExpanded:s,...o}=r||{};return a.post()(this,endpoint`projects/${e}/protected_branches`,{searchParams:{...o,name:t},sudo:n,showExpanded:s})}protect(e,t,r){return this.create(e,t,r)}edit(e,t,r){return a.patch()(this,endpoint`projects/${e}/protected_branches/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/protected_branches/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/protected_branches/${t}`,r)}unprotect(e,t,r){return this.remove(e,t,r)}};var cr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/protected_tags`,t)}create(e,t,r){const{sudo:n,showExpanded:s,...o}=r||{};return a.post()(this,endpoint`projects/${e}/protected_tags`,{searchParams:{name:t,...o},sudo:n,showExpanded:s})}protect(e,t,r){return this.create(e,t,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/protected_tags/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/protected_tags/${t}`,r)}unprotect(e,t,r){return this.remove(e,t,r)}};var ur=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`projects/${e}/releases/${t}/assets/links`,r)}create(e,t,r,n,s){return a.post()(this,endpoint`projects/${e}/releases/${t}/assets/links`,{name:r,url:n,...s})}edit(e,t,r,n){return a.put()(this,endpoint`projects/${e}/releases/${t}/assets/links/${r}`,n)}remove(e,t,r,n){return a.del()(this,endpoint`projects/${e}/releases/${t}/assets/links/${r}`,n)}show(e,t,r,n){return a.get()(this,endpoint`projects/${e}/releases/${t}/assets/links/${r}`,n)}};var lr=class extends n.BaseResource{allContributors(e,t){return a.get()(this,endpoint`projects/${e}/repository/contributors`,t)}allRepositoryTrees(e,t){return a.get()(this,endpoint`projects/${e}/repository/tree`,t)}compare(e,t,r,n){return a.get()(this,endpoint`projects/${e}/repository/compare`,{from:t,to:r,...n})}editChangelog(e,t,r){return a.post()(this,endpoint`projects/${e}/repository/changelog`,{...r,version:t})}mergeBase(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/merge_base`,{...r,refs:t})}showArchive(e,{fileType:t="tar.gz",...r}={}){return a.get()(this,endpoint`projects/${e}/repository/archive.${t}`,r)}showBlob(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/blobs/${t}`,r)}showBlobRaw(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/blobs/${t}/raw`,r)}showChangelog(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/changelog`,{...r,version:t})}};var pr=class extends n.BaseResource{allFileBlames(e,t,r,n){return a.get()(this,endpoint`projects/${e}/repository/files/${t}/blame`,{ref:r,...n})}create(e,t,r,n,s,o){return a.post()(this,endpoint`projects/${e}/repository/files/${t}`,{branch:r,content:n,commitMessage:s,...o})}edit(e,t,r,n,s,o){return a.put()(this,endpoint`projects/${e}/repository/files/${t}`,{branch:r,content:n,commitMessage:s,...o})}remove(e,t,r,n,s){return a.del()(this,endpoint`projects/${e}/repository/files/${t}`,{branch:r,commitMessage:n,...s})}show(e,t,r,n){return a.get()(this,endpoint`projects/${e}/repository/files/${t}`,{ref:r,...n})}showRaw(e,t,r,n){return a.get()(this,endpoint`projects/${e}/repository/files/${t}/raw`,{ref:r,...n})}};var dr=class extends n.BaseResource{edit(e,t,r,n,s){return a.put()(this,endpoint`projects/${e}/repository/submodules/${t}`,{branch:r,commitSha:n,...s})}};var fr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/resource_groups`,t)}edit(e,t,r){return a.put()(this,endpoint`projects/${e}/resource_groups/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/resource_groups/${t}`,r)}allUpcomingJobs(e,t){return a.get()(this,endpoint`projects/${e}/resource_groups/upcoming_jobs`,t)}};var hr=class extends n.BaseResource{all({projectId:e,groupId:t,owned:r,...n}={}){let s;if(e)s=endpoint`projects/${e}/runners`;else if(t)s=endpoint`groups/${t}/runners`;else if(r)s="runners";else s="runners/all";return a.get()(this,s,n)}allJobs(e,t){return a.get()(this,`runners/${e}/jobs`,t)}create(e,t){return a.post()(this,`runners`,{token:e,...t})}edit(e,t){return a.put()(this,`runners/${e}`,t)}enable(e,t,r){return a.post()(this,endpoint`projects/${e}/runners`,{runnerId:t,...r})}disable(e,t,r){return a.del()(this,endpoint`projects/${e}/runners/${t}`,r)}register(e,t){return this.create(e,t)}remove({runnerId:e,token:t,...r}){let n;if(e)n=`runners/${e}`;else if(t){n="runners"}else throw new Error("Missing required argument. Please supply a runnerId or a token in the options parameter");return a.del()(this,n,{token:t,...r})}resetRegistrationToken({runnerId:e,token:t,...r}={}){let n;if(e)n=endpoint`runners/${e}/reset_registration_token`;else if(t)n="runners/reset_registration_token";else{throw new Error("Missing either runnerId or token parameters")}return a.post()(this,n,{token:t,...r})}show(e,t){return a.get()(this,`runners/${e}`,t)}verify(e){return a.post()(this,`runners/verify`,e)}};var gr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/secure_files`,t)}create(e,t,r,n){return a.post()(this,`projects/${e}/secure_files`,{isForm:true,...n,file:[r.content,r.filename],name:t})}download(e,t,r){return a.get()(this,endpoint`projects/${e}/secure_files/${t}/download`,r)}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/secure_files/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/secure_files/${t}`,r)}};var mr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`projects/${e}/repository/tags`,t)}create(e,t,r,n){return a.post()(this,endpoint`projects/${e}/repository/tags`,{searchParams:{tagName:t,ref:r},...n})}remove(e,t,r){return a.del()(this,endpoint`projects/${e}/repository/tags/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/tags/${t}`,r)}showSignature(e,t,r){return a.get()(this,endpoint`projects/${e}/repository/tags/${t}/signature`,r)}};var yr=class extends n.BaseResource{create(e,t,r){return a.get()(this,endpoint`projects/${e}/metrics/user_starred_dashboards`,{dashboardPath:t,...r})}remove(e,t){return a.del()(this,endpoint`projects/${e}/metrics/user_starred_dashboards`,t)}};var vr=class extends k{constructor(e){super("epics","issues",e)}};var $r=class extends O{constructor(e){super("groups","epics",e)}};var br=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`groups/${e}/epics/${t}/issues`,r)}assign(e,t,r,n){return a.post()(this,endpoint`groups/${e}/epics/${t}/issues/${r}`,n)}edit(e,t,r,n){return a.put()(this,endpoint`groups/${e}/epics/${t}/issues/${r}`,n)}remove(e,t,r,n){return a.del()(this,endpoint`groups/${e}/epics/${t}/issues/${r}`,n)}};var wr=class extends J{constructor(e){super("groups","epic",e)}};var _r=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`groups/${e}/epics/${t}/links`,r)}assign(e,t,r,n){return a.post()(this,endpoint`groups/${e}/epics/${t}/links/${r}`,n)}create(e,t,r,n){return a.post()(this,endpoint`groups/${e}/epics/${t}/links`,{searchParams:{title:r},...n})}reorder(e,t,r,n){return a.put()(this,endpoint`groups/${e}/epics/${t}/links/${r}`,n)}unassign(e,t,r,n){return a.del()(this,endpoint`groups/${e}/epics/${t}/links/${r}`,n)}};var Er=class extends D{constructor(e){super("groups","epics",e)}};var Sr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`groups/${e}/epics`,t)}create(e,t,r){return a.post()(this,endpoint`groups/${e}/epics`,{title:t,...r})}createTodo(e,t,r){return a.post()(this,endpoint`groups/${e}/epics/${t}/todos`,r)}edit(e,t,r){return a.put()(this,endpoint`groups/${e}/epics/${t}`,r)}remove(e,t,r){return a.del()(this,endpoint`groups/${e}/epics/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`groups/${e}/epics/${t}`,r)}};var Ar=class extends R{constructor(e){super("groups",e)}};var jr=class extends x{constructor(e){super("groups",e)}};var Rr=class extends n.BaseResource{showIssuesCount(e,t){return a.get()(this,"analytics/group_activity/issues_count",{searchParams:{groupPath:e},...t})}showMergeRequestsCount(e,t){return a.get()(this,"analytics/group_activity/merge_requests_count",{searchParams:{groupPath:e},...t})}showNewMembersCount(e,t){return a.get()(this,"analytics/group_activity/new_members_count",{searchParams:{groupPath:e},...t})}};var xr=class extends P{constructor(e){super("groups",e)}};var kr=class extends C{constructor(e){super("groups",e)}};var Ir=class extends T{constructor(e){super("groups",e)}};var Pr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`groups/${e}/epic_boards`,t)}allLists(e,t,r){return a.get()(this,endpoint`groups/${e}/epic_boards/${t}/lists`,r)}show(e,t,r){return a.get()(this,endpoint`groups/${e}/epic_boards/${t}`,r)}showList(e,t,r,n){return a.get()(this,endpoint`groups/${e}/epic_boards/${t}/lists/${r}`,n)}};var Cr=class extends H{constructor(e){super("groups",e)}};var Tr=class extends n.BaseResource{download(e,t){return a.get()(this,endpoint`groups/${e}/export/download`,t)}import(e,t,{parentId:r,name:n,...s}){return a.post()(this,"groups/import",{isForm:true,...s,file:[e.content,e.filename],path:t,name:n||t.split("/").at(0),parentId:r})}scheduleExport(e,t){return a.post()(this,endpoint`groups/${e}/export`,t)}};var Or=class extends W{constructor(e){super("groups",e)}};var Mr=class extends M{constructor(e){super("groups",e)}};var Nr=class extends z{constructor(e){super("groups",e)}};var Lr=class extends N{constructor(e){super("groups",e)}};var Fr=class extends n.BaseResource{add(e,t,r,n){return a.post()(this,endpoint`groups/${e}/ldap_group_links`,{groupAccess:t,provider:r,...n})}all(e,t){return a.get()(this,endpoint`groups/${e}/ldap_group_links`,t)}remove(e,t,r){return a.del()(this,endpoint`groups/${e}/ldap_group_links`,{provider:t,...r})}sync(e,t){return a.post()(this,endpoint`groups/${e}/ldap_sync`,t)}};var Br=class extends L{constructor(e){super("groups",e)}allBillable(e,t){return a.get()(this,endpoint`${e}/billable_members`,t)}allPending(e,t){return a.get()(this,endpoint`${e}/pending_members`,t)}allBillableMemberships(e,t,r){return a.get()(this,endpoint`${e}/billable_members/${t}/memberships`,r)}approve(e,t,r){return a.put()(this,endpoint`${e}/members/${t}/approve`,r)}approveAll(e,t){return a.put()(this,endpoint`${e}/members/approve_all`,t)}removeBillable(e,t,r){return a.del()(this,endpoint`${e}/billable_members/${t}`,r)}removeOverrideFlag(e,t,r){return a.del()(this,endpoint`${e}/members/${t}/override`,r)}setOverrideFlag(e,t,r){return a.post()(this,endpoint`${e}/members/${t}/override`,r)}};var Dr=class extends n.BaseResource{add(e,t,r){return a.post()(this,endpoint`groups/${e}/members`,{baseAccessLevel:t,...r})}all(e,t){return a.get()(this,endpoint`groups/${e}/member_roles`,t)}remove(e,t,r){return a.del()(this,endpoint`groups/${e}/member_roles/${t}`,r)}};var Ur=class extends B{constructor(e){super("groups",e)}};var Gr=class extends V{constructor(e){super("groups",e)}};var qr=class extends K{constructor(e){super("groups",e)}};var Hr=class extends n.BaseResource{download(e,t,r){return a.get()(this,endpoint`groups/${e}/export_relations/download`,{searchParams:{relation:t},...r})}exportStatus(e,t){return a.get()(this,endpoint`groups/${e}/export_relations`,t)}scheduleExport(e,t){return a.post()(this,endpoint`groups/${e}/export_relations`,t)}};var Kr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`groups/${e}/releases`,t)}};var Yr=class extends Y{constructor(e){super("groups",e)}};var Wr=class extends n.BaseResource{all(e){return a.get()(this,"groups",e)}allDescendantGroups(e,t){return a.get()(this,endpoint`groups/${e}/descendant_groups`,t)}allProjects(e,t){return a.get()(this,endpoint`groups/${e}/projects`,t)}allSharedProjects(e,t){return a.get()(this,endpoint`groups/${e}/projects/shared`,t)}allSubgroups(e,t){return a.get()(this,endpoint`groups/${e}/subgroups`,t)}allProvisionedUsers(e,t){return a.get()(this,endpoint`groups/${e}/provisioned_users`,t)}allTransferLocations(e,t){return a.get()(this,endpoint`groups/${e}/transfer_locations`,t)}create(e,t,{avatar:r,...n}={}){if(r){return a.post()(this,"groups",{...n,isForm:true,avatar:[r.content,r.filename],name:e,path:t})}return a.post()(this,"groups",{name:e,path:t,...n})}downloadAvatar(e,t){return a.get()(this,endpoint`groups/${e}/avatar`,t)}edit(e,{avatar:t,...r}={}){if(t){return a.post()(this,endpoint`groups/${e}`,{...r,isForm:true,avatar:[t.content,t.filename]})}return a.put()(this,endpoint`groups/${e}`,r)}remove(e,t){return a.del()(this,endpoint`groups/${e}`,t)}removeAvatar(e,t){return a.put()(this,endpoint`groups/${e}`,{...t,avatar:""})}restore(e,t){return a.post()(this,endpoint`groups/${e}/restore`,t)}search(e,t){return a.get()(this,"groups",{search:e,...t})}share(e,t,r,n){return a.post()(this,endpoint`groups/${e}/share`,{groupId:t,groupAccess:r,...n})}show(e,t){return a.get()(this,endpoint`groups/${e}`,t)}transfer(e,t){return a.post()(this,endpoint`groups/${e}/transfer`,t)}transferProject(e,t,r){return a.post()(this,endpoint`groups/${e}/projects/${t}`,r)}unshare(e,t,r){return a.del()(this,endpoint`groups/${e}/share/${t}`,r)}uploadAvatar(e,t,{filename:r,...n}={}){return a.put()(this,endpoint`groups/${e}/avatar`,{isForm:true,...n,file:[t,r]})}};var zr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`groups/${e}/saml/identities`,t)}edit(e,t,r){return a.patch()(this,endpoint`groups/${e}/saml/${t}`,r)}};var Vr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`groups/${e}/saml_group_links`,t)}create(e,t,r,n){return a.post()(this,endpoint`groups/${e}/saml_group_links`,{accessLevel:r,samlGroupName:t,...n})}remove(e,t,r){return a.del()(this,endpoint`groups/${e}/saml_group_links/${t}`,r)}show(e,t,r){return a.get()(this,endpoint`groups/${e}/saml_group_links/${t}`,r)}};var Qr=class extends n.BaseResource{all(e,t){return a.get()(this,endpoint`groups/${e}/scim/identities`,t)}edit(e,t,r){return a.patch()(this,endpoint`groups/${e}/scim/${t}`,r)}};var Jr=class extends n.BaseResource{create(e,t){return a.post()(this,endpoint`groups/${e}/service_accounts`,t)}addPersonalAccessToken(e,t,r){return a.post()(this,endpoint`groups/${e}/service_accounts/${t}`,r)}rotatePersonalAccessToken(e,t,r,n){return a.post()(this,endpoint`groups/${e}/service_accounts/${t}/personal_access_tokens/${r}/rotate`,n)}};var Xr=class extends G{constructor(e){super("groups",e)}};var Zr=class extends q{constructor(e){super("groups",e)}};var en=class extends n.BaseResource{all(e,t,r){return a.get()(this,endpoint`groups/${e}/epics/${t}/related_epics`,r)}create(e,t,r,n,s){return a.post()(this,endpoint`groups/${e}/epics/${t}/related_epics`,{searchParams:{targetGroupId:n,targetEpicIid:r},...s})}remove(e,t,r,n){return a.del()(this,endpoint`groups/${e}/epics/${t}/related_epics/${r}`,n)}};var tn=class extends C{constructor(e){super("users",e)}};var url9=e=>e?`users/${e}/emails`:"user/emails";var rn=class extends n.BaseResource{add(e,t){return this.create(e,t)}all({userId:e,...t}={}){return a.get()(this,url9(e),t)}create(e,{userId:t,...r}={}){return a.post()(this,url9(t),{email:e,...r})}show(e,t){return a.get()(this,`user/emails/${e}`,t)}remove(e,{userId:t,...r}={}){return a.del()(this,`${url9(t)}/${e}`,r)}};var url10=e=>e?`users/${e}/gpg_keys`:"user/gpg_keys";var nn=class extends n.BaseResource{add(e,t){return this.create(e,t)}all({userId:e,...t}={}){return a.get()(this,url10(e),t)}create(e,{userId:t,...r}={}){return a.post()(this,url10(t),{key:e,...r})}show(e,{userId:t,...r}={}){return a.get()(this,`${url10(t)}/${e}`,r)}remove(e,{userId:t,...r}={}){return a.del()(this,`${url10(t)}/${e}`,r)}};var sn=class extends n.BaseResource{all(e,t){return a.get()(this,`users/${e}/impersonation_tokens`,t)}create(e,t,r,n){return a.post()(this,`users/${e}/impersonation_tokens`,{name:t,scopes:r,...n})}show(e,t,r){return a.get()(this,`users/${e}/impersonation_tokens/${t}`,r)}remove(e,t,r){return a.del()(this,`users/${e}/impersonation_tokens/${t}`,r)}revoke(e,t,r){return this.remove(e,t,r)}};var on=class extends n.BaseResource{activate(e,t){return a.post()(this,endpoint`users/${e}/activate`,t)}all(e){return a.get()(this,"users",e)}allActivities(e){return a.get()(this,"user/activities",e)}allEvents(e,t){return a.get()(this,endpoint`users/${e}/events`,t)}allFollowers(e,t){return a.get()(this,endpoint`users/${e}/followers`,t)}allFollowing(e,t){return a.get()(this,endpoint`users/${e}/following`,t)}allMemberships(e,t){return a.get()(this,endpoint`users/${e}/memberships`,t)}allProjects(e,t){return a.get()(this,endpoint`users/${e}/projects`,t)}allContributedProjects(e,t){return a.get()(this,endpoint`users/${e}/contributed_projects`,t)}allStarredProjects(e,t){return a.get()(this,endpoint`users/${e}/starred_projects`,t)}approve(e,t){return a.post()(this,endpoint`users/${e}/approve`,t)}ban(e,t){return a.post()(this,endpoint`users/${e}/ban`,t)}block(e,t){return a.post()(this,endpoint`users/${e}/block`,t)}create(e){return a.post()(this,"users",e)}createPersonalAccessToken(e,t,r,n){return a.post()(this,endpoint`users/${e}/personal_access_tokens`,{name:t,scopes:r,...n})}createCIRunner(e,t){return a.post()(this,"user/runners",{...t,runnerType:e})}deactivate(e,t){return a.post()(this,endpoint`users/${e}/deactivate`,t)}disableTwoFactor(e,t){return a.patch()(this,endpoint`users/${e}/disable_two_factor`,t)}edit(e,t){return a.put()(this,endpoint`users/${e}`,t)}editStatus(e){return a.put()(this,"user/status",e)}editCurrentUserPreferences(e,t,r){return a.put()(this,"user/preferences",{viewDiffsFileByFile:e,showWhitespaceInDiffs:t,...r})}follow(e,t){return a.post()(this,endpoint`users/${e}/follow`,t)}reject(e,t){return a.post()(this,endpoint`users/${e}/reject`,t)}show(e,t){return a.get()(this,endpoint`users/${e}`,t)}showCount(e){return a.get()(this,"user_counts",e)}showAssociationsCount(e,t){return a.get()(this,`users/${e}/associations_count`,t)}showCurrentUser(e){return a.get()(this,"user",e)}showCurrentUserPreferences(e){return a.get()(this,"user/preferences",e)}showStatus({iDOrUsername:e,...t}={}){let r;if(e)r=`users/${e}/status`;else r="user/status";return a.get()(this,r,t)}remove(e,t){return a.del()(this,endpoint`users/${e}`,t)}removeAuthenticationIdentity(e,t,r){return a.del()(this,endpoint`users/${e}/identities/${t}`,r)}unban(e,t){return a.post()(this,endpoint`users/${e}/unban`,t)}unblock(e,t){return a.post()(this,endpoint`users/${e}/unblock`,t)}unfollow(e,t){return a.post()(this,endpoint`users/${e}/unfollow`,t)}};var url11=e=>e?`users/${e}/keys`:"user/keys";var an=class extends n.BaseResource{add(e,t,r){return this.create(e,t,r)}all({userId:e,...t}={}){return a.get()(this,url11(e),t)}create(e,t,{userId:r,...n}={}){return a.post()(this,url11(r),{title:e,key:t,...n})}show(e,{userId:t,...r}={}){return a.get()(this,`${url11(t)}/${e}`,r)}remove(e,{userId:t,...r}={}){return a.del()(this,`${url11(t)}/${e}`,r)}};var cn={Agents:c,AlertManagement:u,ApplicationAppearance:l,ApplicationPlanLimits:p,Applications:d,ApplicationSettings:f,ApplicationStatistics:h,AuditEvents:g,Avatar:m,BroadcastMessages:y,CodeSuggestions:v,Composer:$,Conan:b,DashboardAnnotations:w,Debian:_,DependencyProxy:S,DeployKeys:A,DeployTokens:j,DockerfileTemplates:ee,Events:te,Experiments:re,GeoNodes:ne,GeoSites:se,GitignoreTemplates:oe,GitLabCIYMLTemplates:ie,Import:ae,InstanceLevelCICDVariables:ce,Keys:ue,License:le,LicenseTemplates:pe,Lint:de,Markdown:fe,Maven:he,Metadata:ge,Migrations:me,Namespaces:ye,NotificationSettings:ve,NPM:$e,NuGet:be,PersonalAccessTokens:we,PyPI:_e,RubyGems:Ee,Search:Se,SearchAdmin:Ae,ServiceAccounts:je,ServiceData:Re,SidekiqMetrics:xe,SidekiqQueues:ke,SnippetRepositoryStorageMoves:Ie,Snippets:Pe,Suggestions:Ce,SystemHooks:Te,TodoLists:Oe,Topics:Me,Branches:Ne,CommitDiscussions:Le,Commits:Fe,ContainerRegistry:Be,Deployments:De,Environments:Ue,ErrorTrackingClientKeys:Ge,ErrorTrackingSettings:qe,ExternalStatusChecks:He,FeatureFlags:Ke,FeatureFlagUserLists:Ye,FreezePeriods:We,GitlabPages:ze,GoProxy:Ve,Helm:Qe,Integrations:Je,IssueAwardEmojis:Xe,IssueDiscussions:Ze,IssueIterationEvents:et,IssueLabelEvents:tt,IssueLinks:rt,IssueMilestoneEvents:nt,IssueNoteAwardEmojis:st,IssueNotes:ot,Issues:it,IssuesStatistics:at,IssueStateEvents:ct,IssueWeightEvents:ut,JobArtifacts:lt,Jobs:pt,MergeRequestApprovals:dt,MergeRequestAwardEmojis:ft,MergeRequestContextCommits:ht,MergeRequestDiscussions:gt,MergeRequestLabelEvents:mt,MergeRequestMilestoneEvents:yt,MergeRequestDraftNotes:vt,MergeRequestNotes:$t,MergeRequestNoteAwardEmojis:bt,MergeRequests:wt,MergeTrains:_t,PackageRegistry:Et,Packages:St,PagesDomains:At,Pipelines:jt,PipelineSchedules:Rt,PipelineScheduleVariables:xt,PipelineTriggerTokens:kt,ProductAnalytics:It,ProjectAccessRequests:Pt,ProjectAccessTokens:Ct,ProjectAliases:Tt,ProjectBadges:Ot,ProjectCustomAttributes:Mt,ProjectDORA4Metrics:Nt,ProjectHooks:Lt,ProjectImportExports:Ft,ProjectInvitations:Bt,ProjectIssueBoards:Dt,ProjectIterations:Ut,ProjectLabels:Gt,ProjectMembers:qt,ProjectMilestones:Ht,ProjectProtectedEnvironments:Kt,ProjectPushRules:Yt,ProjectRelationsExport:Wt,ProjectReleases:zt,ProjectRemoteMirrors:Vt,ProjectRepositoryStorageMoves:Qt,Projects:Jt,ProjectSnippetAwardEmojis:Xt,ProjectSnippetDiscussions:Zt,ProjectSnippetNotes:er,ProjectSnippets:tr,ProjectStatistics:rr,ProjectTemplates:nr,ProjectVariables:sr,ProjectVulnerabilities:or,ProjectWikis:ir,ProtectedBranches:ar,ProtectedTags:cr,ReleaseLinks:ur,Repositories:lr,RepositoryFiles:pr,RepositorySubmodules:dr,ResourceGroups:fr,Runners:hr,SecureFiles:gr,Tags:mr,UserStarredMetricsDashboard:yr,EpicAwardEmojis:vr,EpicDiscussions:$r,EpicIssues:br,EpicLabelEvents:wr,EpicLinks:_r,EpicNotes:Er,Epics:Sr,GroupAccessRequests:Ar,GroupAccessTokens:jr,GroupActivityAnalytics:Rr,GroupBadges:xr,GroupCustomAttributes:kr,GroupDORA4Metrics:Ir,GroupEpicBoards:Pr,GroupHooks:Cr,GroupImportExports:Tr,GroupInvitations:Or,GroupIssueBoards:Mr,GroupIterations:Nr,GroupLabels:Lr,GroupLDAPLinks:Fr,GroupMembers:Br,GroupMemberRoles:Dr,GroupMilestones:Ur,GroupProtectedEnvironments:Gr,GroupPushRules:qr,GroupRelationExports:Hr,GroupReleases:Kr,GroupRepositoryStorageMoves:Yr,Groups:Wr,GroupSAMLIdentities:zr,GroupSAMLLinks:Vr,GroupSCIMIdentities:Qr,GroupServiceAccounts:Jr,GroupVariables:Xr,GroupWikis:Zr,LinkedEpics:en,UserCustomAttributes:tn,UserEmails:rn,UserGPGKeys:nn,UserImpersonationTokens:sn,Users:on,UserSSHKeys:an};var un=class extends n.BaseResource{constructor(e){super(e);Object.keys(cn).forEach((t=>{this[t]=new cn[t](e)}))}};var ln=(e=>{e[e["NO_ACCESS"]=0]="NO_ACCESS";e[e["MINIMAL_ACCESS"]=5]="MINIMAL_ACCESS";e[e["GUEST"]=10]="GUEST";e[e["REPORTER"]=20]="REPORTER";e[e["DEVELOPER"]=30]="DEVELOPER";e[e["MAINTAINER"]=40]="MAINTAINER";e[e["OWNER"]=50]="OWNER";e[e["ADMIN"]=60]="ADMIN";return e})(ln||{});t.AccessLevel=ln;t.Agents=c;t.AlertManagement=u;t.ApplicationAppearance=l;t.ApplicationPlanLimits=p;t.ApplicationSettings=f;t.ApplicationStatistics=h;t.Applications=d;t.AuditEvents=g;t.Avatar=m;t.Branches=Ne;t.BroadcastMessages=y;t.CodeSuggestions=v;t.CommitDiscussions=Le;t.Commits=Fe;t.Composer=$;t.Conan=b;t.ContainerRegistry=Be;t.DashboardAnnotations=w;t.Debian=_;t.DependencyProxy=S;t.DeployKeys=A;t.DeployTokens=j;t.Deployments=De;t.DockerfileTemplates=ee;t.Environments=Ue;t.EpicAwardEmojis=vr;t.EpicDiscussions=$r;t.EpicIssues=br;t.EpicLabelEvents=wr;t.EpicLinks=_r;t.EpicNotes=Er;t.Epics=Sr;t.ErrorTrackingClientKeys=Ge;t.ErrorTrackingSettings=qe;t.Events=te;t.Experiments=re;t.ExternalStatusChecks=He;t.FeatureFlagUserLists=Ye;t.FeatureFlags=Ke;t.FreezePeriods=We;t.GeoNodes=ne;t.GeoSites=se;t.GitLabCIYMLTemplates=ie;t.GitignoreTemplates=oe;t.Gitlab=un;t.GitlabPages=ze;t.GoProxy=Ve;t.GroupAccessRequests=Ar;t.GroupAccessTokens=jr;t.GroupActivityAnalytics=Rr;t.GroupBadges=xr;t.GroupCustomAttributes=kr;t.GroupDORA4Metrics=Ir;t.GroupEpicBoards=Pr;t.GroupHooks=Cr;t.GroupImportExports=Tr;t.GroupInvitations=Or;t.GroupIssueBoards=Mr;t.GroupIterations=Nr;t.GroupLDAPLinks=Fr;t.GroupLabels=Lr;t.GroupMemberRoles=Dr;t.GroupMembers=Br;t.GroupMilestones=Ur;t.GroupProtectedEnvironments=Gr;t.GroupPushRules=qr;t.GroupRelationExports=Hr;t.GroupReleases=Kr;t.GroupRepositoryStorageMoves=Yr;t.GroupSAMLIdentities=zr;t.GroupSAMLLinks=Vr;t.GroupSCIMIdentities=Qr;t.GroupServiceAccounts=Jr;t.GroupVariables=Xr;t.GroupWikis=Zr;t.Groups=Wr;t.Helm=Qe;t.Import=ae;t.InstanceLevelCICDVariables=ce;t.Integrations=Je;t.IssueAwardEmojis=Xe;t.IssueDiscussions=Ze;t.IssueIterationEvents=et;t.IssueLabelEvents=tt;t.IssueLinks=rt;t.IssueMilestoneEvents=nt;t.IssueNoteAwardEmojis=st;t.IssueNotes=ot;t.IssueStateEvents=ct;t.IssueWeightEvents=ut;t.Issues=it;t.IssuesStatistics=at;t.JobArtifacts=lt;t.Jobs=pt;t.Keys=ue;t.License=le;t.LicenseTemplates=pe;t.LinkedEpics=en;t.Lint=de;t.Markdown=fe;t.Maven=he;t.MergeRequestApprovals=dt;t.MergeRequestAwardEmojis=ft;t.MergeRequestContextCommits=ht;t.MergeRequestDiscussions=gt;t.MergeRequestDraftNotes=vt;t.MergeRequestLabelEvents=mt;t.MergeRequestMilestoneEvents=yt;t.MergeRequestNoteAwardEmojis=bt;t.MergeRequestNotes=$t;t.MergeRequests=wt;t.MergeTrains=_t;t.Metadata=ge;t.Migrations=me;t.NPM=$e;t.Namespaces=ye;t.NotificationSettings=ve;t.NuGet=be;t.PackageRegistry=Et;t.Packages=St;t.PagesDomains=At;t.PersonalAccessTokens=we;t.PipelineScheduleVariables=xt;t.PipelineSchedules=Rt;t.PipelineTriggerTokens=kt;t.Pipelines=jt;t.ProductAnalytics=It;t.ProjectAccessRequests=Pt;t.ProjectAccessTokens=Ct;t.ProjectAliases=Tt;t.ProjectBadges=Ot;t.ProjectCustomAttributes=Mt;t.ProjectDORA4Metrics=Nt;t.ProjectHooks=Lt;t.ProjectImportExports=Ft;t.ProjectInvitations=Bt;t.ProjectIssueBoards=Dt;t.ProjectIterations=Ut;t.ProjectLabels=Gt;t.ProjectMembers=qt;t.ProjectMilestones=Ht;t.ProjectProtectedEnvironments=Kt;t.ProjectPushRules=Yt;t.ProjectRelationsExport=Wt;t.ProjectReleases=zt;t.ProjectRemoteMirrors=Vt;t.ProjectRepositoryStorageMoves=Qt;t.ProjectSnippetAwardEmojis=Xt;t.ProjectSnippetDiscussions=Zt;t.ProjectSnippetNotes=er;t.ProjectSnippets=tr;t.ProjectStatistics=rr;t.ProjectTemplates=nr;t.ProjectVariables=sr;t.ProjectVulnerabilities=or;t.ProjectWikis=ir;t.Projects=Jt;t.ProtectedBranches=ar;t.ProtectedTags=cr;t.PyPI=_e;t.ReleaseLinks=ur;t.Repositories=lr;t.RepositoryFiles=pr;t.RepositorySubmodules=dr;t.ResourceGroups=fr;t.RubyGems=Ee;t.Runners=hr;t.Search=Se;t.SearchAdmin=Ae;t.SecureFiles=gr;t.ServiceAccounts=je;t.ServiceData=Re;t.SidekiqMetrics=xe;t.SidekiqQueues=ke;t.SnippetRepositoryStorageMoves=Ie;t.Snippets=Pe;t.Suggestions=Ce;t.SystemHooks=Te;t.Tags=mr;t.TodoLists=Oe;t.Topics=Me;t.UserCustomAttributes=tn;t.UserEmails=rn;t.UserGPGKeys=nn;t.UserImpersonationTokens=sn;t.UserSSHKeys=an;t.UserStarredMetricsDashboard=yr;t.Users=on},8126:(e,t,r)=>{"use strict";var n=r(891);var s=r(6308);var o=r(9490);var i=r(6674);function _interopDefault(e){return e&&e.__esModule?e:{default:e}}var a=_interopDefault(i);function formatQuery(e={}){const t=s.decamelizeKeys(e);return n.stringify(t,{arrayFormat:"brackets"})}async function defaultOptionsHandler(e,{body:t,searchParams:r,sudo:n,signal:o,asStream:i=false,method:a="GET"}={}){const{headers:c,authHeaders:u,url:l}=e;const p={...c};const d={method:a,asStream:i,signal:o,prefixUrl:l};d.headers=p;if(n)d.headers.sudo=`${n}`;if(t){if(t instanceof FormData){d.body=t}else{d.body=JSON.stringify(s.decamelizeKeys(t));d.headers["content-type"]="application/json"}}const[f,h]=Object.entries(u)[0];d.headers[f]=await h();const g=formatQuery(r);if(g)d.searchParams=g;return Promise.resolve(d)}function createRateLimiters(e={}){const t={};Object.entries(e).forEach((([e,r])=>{if(typeof r==="number")t[e]=o.RateLimit(r,{timeUnit:6e4});else t[e]={method:r.method.toUpperCase(),limit:o.RateLimit(r.limit,{timeUnit:6e4})}}));return t}function createRequesterFn(e,t){const r=["get","post","put","patch","delete"];return n=>{const s={};const o=createRateLimiters(n.rateLimits);r.forEach((r=>{s[r]=async(s,i)=>{const a=await defaultOptionsHandler(n,{...i,method:r.toUpperCase()});const c=await e(n,a);return t(s,{...c,rateLimiters:o})}}));return s}}function extendClass(e,t){return class extends e{constructor(...e){const[r,...n]=e;super({...t,...r},...n)}}}function presetResourceArguments(e,t={}){const r={};Object.entries(e).filter((([,e])=>typeof e==="function")).forEach((([e,n])=>{r[e]=extendClass(n,t)}));return r}function getMatchingRateLimiter(e,t={},r="GET"){const n=Object.keys(t).sort().reverse();const s=n.find((t=>a.default.isMatch(e,t)));const i=s&&t[s];if(i&&typeof i!=="object"){return i}if(i&&i.method.toUpperCase()===r.toUpperCase()){return i.limit}return o.RateLimit(3e3,{timeUnit:6e4})}function getDynamicToken(e){return e instanceof Function?e():Promise.resolve(e)}var c=Object.freeze({"**":3e3,"projects/import":6,"projects/*/export":6,"projects/*/download":1,"groups/import":6,"groups/*/export":6,"groups/*/download":1,"projects/*/issues/*/notes":{method:"post",limit:300},"projects/*/snippets/*/notes":{method:"post",limit:300},"projects/*/merge_requests/*/notes":{method:"post",limit:300},"groups/*/epics/*/notes":{method:"post",limit:300},"projects/*/repository/archive*":5,"projects/*/jobs":600,"projects/*/members":60,"groups/*/members":60});var u=class{url;requester;queryTimeout;headers;authHeaders;camelize;rejectUnauthorized;constructor({sudo:e,profileToken:t,camelize:r,requesterFn:n,profileMode:s="execution",host:o="https://gitlab.com",prefixUrl:i="",rejectUnauthorized:a=true,queryTimeout:u=3e5,rateLimits:l=c,...p}){if(!n)throw new ReferenceError("requesterFn must be passed");this.url=[o,"api","v4",i].join("/");this.headers={};this.authHeaders={};this.rejectUnauthorized=a;this.camelize=r;this.queryTimeout=u;if("oauthToken"in p)this.authHeaders.authorization=async()=>{const e=await getDynamicToken(p.oauthToken);return`Bearer ${e}`};else if("jobToken"in p)this.authHeaders["job-token"]=async()=>getDynamicToken(p.jobToken);else if("token"in p)this.authHeaders["private-token"]=async()=>getDynamicToken(p.token);else{throw new ReferenceError("A token, oauthToken or jobToken must be passed")}if(t){this.headers["X-Profile-Token"]=t;this.headers["X-Profile-Mode"]=s}if(e)this.headers.Sudo=`${e}`;this.requester=n({...this,rateLimits:l})}};var l=class extends Error{constructor(e,t){super(e,t);this.name="GitbeakerRequestError"}};var p=class extends Error{constructor(e){super(e);this.name="GitbeakerTimeoutError"}};var d=class extends Error{constructor(e){super(e);this.name="GitbeakerTimeoutError"}};t.BaseResource=u;t.GitbeakerRequestError=l;t.GitbeakerRetryError=d;t.GitbeakerTimeoutError=p;t.createRateLimiters=createRateLimiters;t.createRequesterFn=createRequesterFn;t.defaultOptionsHandler=defaultOptionsHandler;t.formatQuery=formatQuery;t.getMatchingRateLimiter=getMatchingRateLimiter;t.presetResourceArguments=presetResourceArguments},3532:(e,t,r)=>{"use strict";var n=r(5182);var s=r(8126);function _interopNamespace(e){if(e&&e.__esModule)return e;var t=Object.create(null);if(e){Object.keys(e).forEach((function(r){if(r!=="default"){var n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:true,get:function(){return e[r]}})}}))}t.default=e;return Object.freeze(t)}var o=_interopNamespace(n);async function defaultOptionsHandler(e,t){const n={...t};if(e.url.includes("https")&&e.rejectUnauthorized!=null&&e.rejectUnauthorized===false){if(typeof window!=="object"){const{Agent:e}=await Promise.resolve().then(r.t.bind(r,5692,23));n.agent=new e({rejectUnauthorized:false})}}return n}async function processBody(e){const t=(e.headers.get("content-type")||"").split(";")[0].trim();if(t==="application/json"){return e.json().then((e=>e||{}))}if(t.startsWith("text/")){return e.text().then((e=>e||""))}return e.blob()}function delay(e){return new Promise((t=>{setTimeout(t,e)}))}async function parseResponse(e,t=false){const{status:r,headers:n}=e;const s=Object.fromEntries(n.entries());let o;if(t){o=e.body}else{o=r===204?null:await processBody(e)}return{body:o,headers:s,status:r}}async function throwFailedRequestError(e,t){const r=await t.text();const n=t.headers.get("Content-Type");let o="API Request Error";if(n?.includes("application/json")){const e=JSON.parse(r);o=JSON.stringify(e.error||e.message,null,2)}else{o=r}throw new s.GitbeakerRequestError(t.statusText,{cause:{description:o,request:e,response:t}})}function getConditionalMode(e){if(e.includes("repository/archive"))return"same-origin";return void 0}async function defaultRequestHandler(e,t){const r=[429,502];const n=10;const{prefixUrl:o,asStream:i,searchParams:a,rateLimiters:c,method:u,...l}=t||{};const p=s.getMatchingRateLimiter(e,c,u);let d;if(o)d=o.endsWith("/")?o:`${o}/`;const f=new URL(e,d);f.search=a||"";const h=getConditionalMode(e);for(let e=0;e<n;e+=1){const t=new Request(f,{...l,method:u,mode:h});await p();const n=await fetch(t).catch((e=>{if(e.name==="TimeoutError"||e.name==="AbortError"){throw new s.GitbeakerTimeoutError("Query timeout was reached")}throw e}));if(n.ok)return parseResponse(n,i);if(!r.includes(n.status))await throwFailedRequestError(t,n);await delay(2**e*.25);continue}throw new s.GitbeakerRetryError(`Could not successfully complete this request due to Error 429. Check the applicable rate limits for this endpoint.`)}var i=s.createRequesterFn(defaultOptionsHandler,defaultRequestHandler);var{AccessLevel:a,...c}=o;var u=s.presetResourceArguments(c,{requesterFn:i});var l=a;var{Agents:p,AlertManagement:d,ApplicationAppearance:f,ApplicationPlanLimits:h,Applications:g,ApplicationSettings:m,ApplicationStatistics:y,AuditEvents:v,Avatar:$,BroadcastMessages:b,CodeSuggestions:w,Composer:_,Conan:S,DashboardAnnotations:A,Debian:j,DependencyProxy:R,DeployKeys:x,DeployTokens:k,DockerfileTemplates:I,Events:P,Experiments:C,GeoNodes:T,GeoSites:O,GitignoreTemplates:M,GitLabCIYMLTemplates:N,Import:L,InstanceLevelCICDVariables:B,Keys:D,License:U,LicenseTemplates:G,Lint:q,Markdown:H,Maven:K,Metadata:Y,Migrations:W,Namespaces:z,NotificationSettings:V,NPM:Q,NuGet:J,PersonalAccessTokens:X,PyPI:Z,RubyGems:ee,Search:te,SearchAdmin:re,ServiceAccounts:ne,ServiceData:se,SidekiqMetrics:oe,SidekiqQueues:ie,SnippetRepositoryStorageMoves:ae,Snippets:ce,Suggestions:ue,SystemHooks:le,TodoLists:pe,Topics:de,Branches:fe,CommitDiscussions:he,Commits:ge,ContainerRegistry:me,Deployments:ye,Environments:ve,ErrorTrackingClientKeys:$e,ErrorTrackingSettings:be,ExternalStatusChecks:we,FeatureFlags:_e,FeatureFlagUserLists:Ee,FreezePeriods:Se,GitlabPages:Ae,GoProxy:je,Helm:Re,Integrations:xe,IssueAwardEmojis:ke,IssueDiscussions:Ie,IssueIterationEvents:Pe,IssueLabelEvents:Ce,IssueLinks:Te,IssueMilestoneEvents:Oe,IssueNoteAwardEmojis:Me,IssueNotes:Ne,Issues:Le,IssuesStatistics:Fe,IssueStateEvents:Be,IssueWeightEvents:De,JobArtifacts:Ue,Jobs:Ge,MergeRequestApprovals:qe,MergeRequestAwardEmojis:He,MergeRequestContextCommits:Ke,MergeRequestDiscussions:Ye,MergeRequestLabelEvents:We,MergeRequestMilestoneEvents:ze,MergeRequestDraftNotes:Ve,MergeRequestNotes:Qe,MergeRequestNoteAwardEmojis:Je,MergeRequests:Xe,MergeTrains:Ze,PackageRegistry:et,Packages:tt,PagesDomains:rt,Pipelines:nt,PipelineSchedules:st,PipelineScheduleVariables:ot,PipelineTriggerTokens:it,ProductAnalytics:at,ProjectAccessRequests:ct,ProjectAccessTokens:ut,ProjectAliases:lt,ProjectBadges:pt,ProjectCustomAttributes:dt,ProjectDORA4Metrics:ft,ProjectHooks:ht,ProjectImportExports:gt,ProjectInvitations:mt,ProjectIssueBoards:yt,ProjectIterations:vt,ProjectLabels:$t,ProjectMembers:bt,ProjectMilestones:wt,ProjectProtectedEnvironments:_t,ProjectPushRules:Et,ProjectRelationsExport:St,ProjectReleases:At,ProjectRemoteMirrors:jt,ProjectRepositoryStorageMoves:Rt,Projects:xt,ProjectSnippetAwardEmojis:kt,ProjectSnippetDiscussions:It,ProjectSnippetNotes:Pt,ProjectSnippets:Ct,ProjectStatistics:Tt,ProjectTemplates:Ot,ProjectVariables:Mt,ProjectVulnerabilities:Nt,ProjectWikis:Lt,ProtectedBranches:Ft,ProtectedTags:Bt,ReleaseLinks:Dt,Repositories:Ut,RepositoryFiles:Gt,RepositorySubmodules:qt,ResourceGroups:Ht,Runners:Kt,SecureFiles:Yt,Tags:Wt,UserStarredMetricsDashboard:zt,EpicAwardEmojis:Vt,EpicDiscussions:Qt,EpicIssues:Jt,EpicLabelEvents:Xt,EpicLinks:Zt,EpicNotes:er,Epics:tr,GroupAccessRequests:rr,GroupAccessTokens:nr,GroupActivityAnalytics:sr,GroupBadges:or,GroupCustomAttributes:ir,GroupDORA4Metrics:ar,GroupEpicBoards:cr,GroupHooks:ur,GroupImportExports:lr,GroupInvitations:pr,GroupIssueBoards:dr,GroupIterations:fr,GroupLabels:hr,GroupLDAPLinks:gr,GroupMembers:mr,GroupMemberRoles:yr,GroupMilestones:vr,GroupProtectedEnvironments:$r,GroupPushRules:br,GroupRelationExports:wr,GroupReleases:_r,GroupRepositoryStorageMoves:Er,Groups:Sr,GroupSAMLIdentities:Ar,GroupSAMLLinks:jr,GroupSCIMIdentities:Rr,GroupServiceAccounts:xr,GroupVariables:kr,GroupWikis:Ir,LinkedEpics:Pr,UserCustomAttributes:Cr,UserEmails:Tr,UserGPGKeys:Or,UserImpersonationTokens:Mr,Users:Nr,UserSSHKeys:Lr,Gitlab:Fr}=u;t.AccessLevel=l;t.Agents=p;t.AlertManagement=d;t.ApplicationAppearance=f;t.ApplicationPlanLimits=h;t.ApplicationSettings=m;t.ApplicationStatistics=y;t.Applications=g;t.AuditEvents=v;t.Avatar=$;t.Branches=fe;t.BroadcastMessages=b;t.CodeSuggestions=w;t.CommitDiscussions=he;t.Commits=ge;t.Composer=_;t.Conan=S;t.ContainerRegistry=me;t.DashboardAnnotations=A;t.Debian=j;t.DependencyProxy=R;t.DeployKeys=x;t.DeployTokens=k;t.Deployments=ye;t.DockerfileTemplates=I;t.Environments=ve;t.EpicAwardEmojis=Vt;t.EpicDiscussions=Qt;t.EpicIssues=Jt;t.EpicLabelEvents=Xt;t.EpicLinks=Zt;t.EpicNotes=er;t.Epics=tr;t.ErrorTrackingClientKeys=$e;t.ErrorTrackingSettings=be;t.Events=P;t.Experiments=C;t.ExternalStatusChecks=we;t.FeatureFlagUserLists=Ee;t.FeatureFlags=_e;t.FreezePeriods=Se;t.GeoNodes=T;t.GeoSites=O;t.GitLabCIYMLTemplates=N;t.GitignoreTemplates=M;t.Gitlab=Fr;t.GitlabPages=Ae;t.GoProxy=je;t.GroupAccessRequests=rr;t.GroupAccessTokens=nr;t.GroupActivityAnalytics=sr;t.GroupBadges=or;t.GroupCustomAttributes=ir;t.GroupDORA4Metrics=ar;t.GroupEpicBoards=cr;t.GroupHooks=ur;t.GroupImportExports=lr;t.GroupInvitations=pr;t.GroupIssueBoards=dr;t.GroupIterations=fr;t.GroupLDAPLinks=gr;t.GroupLabels=hr;t.GroupMemberRoles=yr;t.GroupMembers=mr;t.GroupMilestones=vr;t.GroupProtectedEnvironments=$r;t.GroupPushRules=br;t.GroupRelationExports=wr;t.GroupReleases=_r;t.GroupRepositoryStorageMoves=Er;t.GroupSAMLIdentities=Ar;t.GroupSAMLLinks=jr;t.GroupSCIMIdentities=Rr;t.GroupServiceAccounts=xr;t.GroupVariables=kr;t.GroupWikis=Ir;t.Groups=Sr;t.Helm=Re;t.Import=L;t.InstanceLevelCICDVariables=B;t.Integrations=xe;t.IssueAwardEmojis=ke;t.IssueDiscussions=Ie;t.IssueIterationEvents=Pe;t.IssueLabelEvents=Ce;t.IssueLinks=Te;t.IssueMilestoneEvents=Oe;t.IssueNoteAwardEmojis=Me;t.IssueNotes=Ne;t.IssueStateEvents=Be;t.IssueWeightEvents=De;t.Issues=Le;t.IssuesStatistics=Fe;t.JobArtifacts=Ue;t.Jobs=Ge;t.Keys=D;t.License=U;t.LicenseTemplates=G;t.LinkedEpics=Pr;t.Lint=q;t.Markdown=H;t.Maven=K;t.MergeRequestApprovals=qe;t.MergeRequestAwardEmojis=He;t.MergeRequestContextCommits=Ke;t.MergeRequestDiscussions=Ye;t.MergeRequestDraftNotes=Ve;t.MergeRequestLabelEvents=We;t.MergeRequestMilestoneEvents=ze;t.MergeRequestNoteAwardEmojis=Je;t.MergeRequestNotes=Qe;t.MergeRequests=Xe;t.MergeTrains=Ze;t.Metadata=Y;t.Migrations=W;t.NPM=Q;t.Namespaces=z;t.NotificationSettings=V;t.NuGet=J;t.PackageRegistry=et;t.Packages=tt;t.PagesDomains=rt;t.PersonalAccessTokens=X;t.PipelineScheduleVariables=ot;t.PipelineSchedules=st;t.PipelineTriggerTokens=it;t.Pipelines=nt;t.ProductAnalytics=at;t.ProjectAccessRequests=ct;t.ProjectAccessTokens=ut;t.ProjectAliases=lt;t.ProjectBadges=pt;t.ProjectCustomAttributes=dt;t.ProjectDORA4Metrics=ft;t.ProjectHooks=ht;t.ProjectImportExports=gt;t.ProjectInvitations=mt;t.ProjectIssueBoards=yt;t.ProjectIterations=vt;t.ProjectLabels=$t;t.ProjectMembers=bt;t.ProjectMilestones=wt;t.ProjectProtectedEnvironments=_t;t.ProjectPushRules=Et;t.ProjectRelationsExport=St;t.ProjectReleases=At;t.ProjectRemoteMirrors=jt;t.ProjectRepositoryStorageMoves=Rt;t.ProjectSnippetAwardEmojis=kt;t.ProjectSnippetDiscussions=It;t.ProjectSnippetNotes=Pt;t.ProjectSnippets=Ct;t.ProjectStatistics=Tt;t.ProjectTemplates=Ot;t.ProjectVariables=Mt;t.ProjectVulnerabilities=Nt;t.ProjectWikis=Lt;t.Projects=xt;t.ProtectedBranches=Ft;t.ProtectedTags=Bt;t.PyPI=Z;t.ReleaseLinks=Dt;t.Repositories=Ut;t.RepositoryFiles=Gt;t.RepositorySubmodules=qt;t.ResourceGroups=Ht;t.RubyGems=ee;t.Runners=Kt;t.Search=te;t.SearchAdmin=re;t.SecureFiles=Yt;t.ServiceAccounts=ne;t.ServiceData=se;t.SidekiqMetrics=oe;t.SidekiqQueues=ie;t.SnippetRepositoryStorageMoves=ae;t.Snippets=ce;t.Suggestions=ue;t.SystemHooks=le;t.Tags=Wt;t.TodoLists=pe;t.Topics=de;t.UserCustomAttributes=Cr;t.UserEmails=Tr;t.UserGPGKeys=Or;t.UserImpersonationTokens=Mr;t.UserSSHKeys=Lr;t.UserStarredMetricsDashboard=zt;t.Users=Nr},9490:function(e,t,r){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:true});t.RateLimit=t.Sema=void 0;const s=n(r(4434));function arrayMove(e,t,r,n,s){for(let o=0;o<s;++o){r[o+n]=e[o+t];e[o+t]=void 0}}function pow2AtLeast(e){e=e>>>0;e=e-1;e=e|e>>1;e=e|e>>2;e=e|e>>4;e=e|e>>8;e=e|e>>16;return e+1}function getCapacity(e){return pow2AtLeast(Math.min(Math.max(16,e),1073741824))}class Deque{constructor(e){this._capacity=getCapacity(e);this._length=0;this._front=0;this.arr=[]}push(e){const t=this._length;this.checkCapacity(t+1);const r=this._front+t&this._capacity-1;this.arr[r]=e;this._length=t+1;return t+1}pop(){const e=this._length;if(e===0){return void 0}const t=this._front+e-1&this._capacity-1;const r=this.arr[t];this.arr[t]=void 0;this._length=e-1;return r}shift(){const e=this._length;if(e===0){return void 0}const t=this._front;const r=this.arr[t];this.arr[t]=void 0;this._front=t+1&this._capacity-1;this._length=e-1;return r}get length(){return this._length}checkCapacity(e){if(this._capacity<e){this.resizeTo(getCapacity(this._capacity*1.5+16))}}resizeTo(e){const t=this._capacity;this._capacity=e;const r=this._front;const n=this._length;if(r+n>t){const e=r+n&t-1;arrayMove(this.arr,0,this.arr,t,e)}}}class ReleaseEmitter extends s.default{}function isFn(e){return typeof e==="function"}function defaultInit(){return"1"}class Sema{constructor(e,{initFn:t=defaultInit,pauseFn:r,resumeFn:n,capacity:s=10}={}){if(isFn(r)!==isFn(n)){throw new Error("pauseFn and resumeFn must be both set for pausing")}this.nrTokens=e;this.free=new Deque(e);this.waiting=new Deque(s);this.releaseEmitter=new ReleaseEmitter;this.noTokens=t===defaultInit;this.pauseFn=r;this.resumeFn=n;this.paused=false;this.releaseEmitter.on("release",(e=>{const t=this.waiting.shift();if(t){t.resolve(e)}else{if(this.resumeFn&&this.paused){this.paused=false;this.resumeFn()}this.free.push(e)}}));for(let r=0;r<e;r++){this.free.push(t())}}tryAcquire(){return this.free.pop()}async acquire(){let e=this.tryAcquire();if(e!==void 0){return e}return new Promise(((e,t)=>{if(this.pauseFn&&!this.paused){this.paused=true;this.pauseFn()}this.waiting.push({resolve:e,reject:t})}))}release(e){this.releaseEmitter.emit("release",this.noTokens?"1":e)}drain(){const e=new Array(this.nrTokens);for(let t=0;t<this.nrTokens;t++){e[t]=this.acquire()}return Promise.all(e)}nrWaiting(){return this.waiting.length}}t.Sema=Sema;function RateLimit(e,{timeUnit:t=1e3,uniformDistribution:r=false}={}){const n=new Sema(r?1:e);const s=r?t/e:t;return async function rl(){await n.acquire();setTimeout((()=>n.release()),s)}}t.RateLimit=RateLimit},8671:(e,t,r)=>{"use strict";const n=r(3062);const s=r(4898);const o=r(5331);const i=r(168);const braces=(e,t={})=>{let r=[];if(Array.isArray(e)){for(const n of e){const e=braces.create(n,t);if(Array.isArray(e)){r.push(...e)}else{r.push(e)}}}else{r=[].concat(braces.create(e,t))}if(t&&t.expand===true&&t.nodupes===true){r=[...new Set(r)]}return r};braces.parse=(e,t={})=>i(e,t);braces.stringify=(e,t={})=>{if(typeof e==="string"){return n(braces.parse(e,t),t)}return n(e,t)};braces.compile=(e,t={})=>{if(typeof e==="string"){e=braces.parse(e,t)}return s(e,t)};braces.expand=(e,t={})=>{if(typeof e==="string"){e=braces.parse(e,t)}let r=o(e,t);if(t.noempty===true){r=r.filter(Boolean)}if(t.nodupes===true){r=[...new Set(r)]}return r};braces.create=(e,t={})=>{if(e===""||e.length<3){return[e]}return t.expand!==true?braces.compile(e,t):braces.expand(e,t)};e.exports=braces},4898:(e,t,r)=>{"use strict";const n=r(9730);const s=r(2474);const compile=(e,t={})=>{const walk=(e,r={})=>{const o=s.isInvalidBrace(r);const i=e.invalid===true&&t.escapeInvalid===true;const a=o===true||i===true;const c=t.escapeInvalid===true?"\\":"";let u="";if(e.isOpen===true){return c+e.value}if(e.isClose===true){console.log("node.isClose",c,e.value);return c+e.value}if(e.type==="open"){return a?c+e.value:"("}if(e.type==="close"){return a?c+e.value:")"}if(e.type==="comma"){return e.prev.type==="comma"?"":a?e.value:"|"}if(e.value){return e.value}if(e.nodes&&e.ranges>0){const r=s.reduce(e.nodes);const o=n(...r,{...t,wrap:false,toRegex:true,strictZeros:true});if(o.length!==0){return r.length>1&&o.length>1?`(${o})`:o}}if(e.nodes){for(const t of e.nodes){u+=walk(t,e)}}return u};return walk(e)};e.exports=compile},1778:e=>{"use strict";e.exports={MAX_LENGTH:1e4,CHAR_0:"0",CHAR_9:"9",CHAR_UPPERCASE_A:"A",CHAR_LOWERCASE_A:"a",CHAR_UPPERCASE_Z:"Z",CHAR_LOWERCASE_Z:"z",CHAR_LEFT_PARENTHESES:"(",CHAR_RIGHT_PARENTHESES:")",CHAR_ASTERISK:"*",CHAR_AMPERSAND:"&",CHAR_AT:"@",CHAR_BACKSLASH:"\\",CHAR_BACKTICK:"`",CHAR_CARRIAGE_RETURN:"\r",CHAR_CIRCUMFLEX_ACCENT:"^",CHAR_COLON:":",CHAR_COMMA:",",CHAR_DOLLAR:"$",CHAR_DOT:".",CHAR_DOUBLE_QUOTE:'"',CHAR_EQUAL:"=",CHAR_EXCLAMATION_MARK:"!",CHAR_FORM_FEED:"\f",CHAR_FORWARD_SLASH:"/",CHAR_HASH:"#",CHAR_HYPHEN_MINUS:"-",CHAR_LEFT_ANGLE_BRACKET:"<",CHAR_LEFT_CURLY_BRACE:"{",CHAR_LEFT_SQUARE_BRACKET:"[",CHAR_LINE_FEED:"\n",CHAR_NO_BREAK_SPACE:" ",CHAR_PERCENT:"%",CHAR_PLUS:"+",CHAR_QUESTION_MARK:"?",CHAR_RIGHT_ANGLE_BRACKET:">",CHAR_RIGHT_CURLY_BRACE:"}",CHAR_RIGHT_SQUARE_BRACKET:"]",CHAR_SEMICOLON:";",CHAR_SINGLE_QUOTE:"'",CHAR_SPACE:" ",CHAR_TAB:"\t",CHAR_UNDERSCORE:"_",CHAR_VERTICAL_LINE:"|",CHAR_ZERO_WIDTH_NOBREAK_SPACE:"\ufeff"}},5331:(e,t,r)=>{"use strict";const n=r(9730);const s=r(3062);const o=r(2474);const append=(e="",t="",r=false)=>{const n=[];e=[].concat(e);t=[].concat(t);if(!t.length)return e;if(!e.length){return r?o.flatten(t).map((e=>`{${e}}`)):t}for(const s of e){if(Array.isArray(s)){for(const e of s){n.push(append(e,t,r))}}else{for(let e of t){if(r===true&&typeof e==="string")e=`{${e}}`;n.push(Array.isArray(e)?append(s,e,r):s+e)}}}return o.flatten(n)};const expand=(e,t={})=>{const r=t.rangeLimit===undefined?1e3:t.rangeLimit;const walk=(e,i={})=>{e.queue=[];let a=i;let c=i.queue;while(a.type!=="brace"&&a.type!=="root"&&a.parent){a=a.parent;c=a.queue}if(e.invalid||e.dollar){c.push(append(c.pop(),s(e,t)));return}if(e.type==="brace"&&e.invalid!==true&&e.nodes.length===2){c.push(append(c.pop(),["{}"]));return}if(e.nodes&&e.ranges>0){const i=o.reduce(e.nodes);if(o.exceedsLimit(...i,t.step,r)){throw new RangeError("expanded array length exceeds range limit. Use options.rangeLimit to increase or disable the limit.")}let a=n(...i,t);if(a.length===0){a=s(e,t)}c.push(append(c.pop(),a));e.nodes=[];return}const u=o.encloseBrace(e);let l=e.queue;let p=e;while(p.type!=="brace"&&p.type!=="root"&&p.parent){p=p.parent;l=p.queue}for(let t=0;t<e.nodes.length;t++){const r=e.nodes[t];if(r.type==="comma"&&e.type==="brace"){if(t===1)l.push("");l.push("");continue}if(r.type==="close"){c.push(append(c.pop(),l,u));continue}if(r.value&&r.type!=="open"){l.push(append(l.pop(),r.value));continue}if(r.nodes){walk(r,e)}}return l};return o.flatten(walk(e))};e.exports=expand},168:(e,t,r)=>{"use strict";const n=r(3062);const{MAX_LENGTH:s,CHAR_BACKSLASH:o,CHAR_BACKTICK:i,CHAR_COMMA:a,CHAR_DOT:c,CHAR_LEFT_PARENTHESES:u,CHAR_RIGHT_PARENTHESES:l,CHAR_LEFT_CURLY_BRACE:p,CHAR_RIGHT_CURLY_BRACE:d,CHAR_LEFT_SQUARE_BRACKET:f,CHAR_RIGHT_SQUARE_BRACKET:h,CHAR_DOUBLE_QUOTE:g,CHAR_SINGLE_QUOTE:m,CHAR_NO_BREAK_SPACE:y,CHAR_ZERO_WIDTH_NOBREAK_SPACE:v}=r(1778);const parse=(e,t={})=>{if(typeof e!=="string"){throw new TypeError("Expected a string")}const r=t||{};const $=typeof r.maxLength==="number"?Math.min(s,r.maxLength):s;if(e.length>$){throw new SyntaxError(`Input length (${e.length}), exceeds max characters (${$})`)}const b={type:"root",input:e,nodes:[]};const w=[b];let _=b;let S=b;let A=0;const j=e.length;let R=0;let x=0;let k;const advance=()=>e[R++];const push=e=>{if(e.type==="text"&&S.type==="dot"){S.type="text"}if(S&&S.type==="text"&&e.type==="text"){S.value+=e.value;return}_.nodes.push(e);e.parent=_;e.prev=S;S=e;return e};push({type:"bos"});while(R<j){_=w[w.length-1];k=advance();if(k===v||k===y){continue}if(k===o){push({type:"text",value:(t.keepEscaping?k:"")+advance()});continue}if(k===h){push({type:"text",value:"\\"+k});continue}if(k===f){A++;let e;while(R<j&&(e=advance())){k+=e;if(e===f){A++;continue}if(e===o){k+=advance();continue}if(e===h){A--;if(A===0){break}}}push({type:"text",value:k});continue}if(k===u){_=push({type:"paren",nodes:[]});w.push(_);push({type:"text",value:k});continue}if(k===l){if(_.type!=="paren"){push({type:"text",value:k});continue}_=w.pop();push({type:"text",value:k});_=w[w.length-1];continue}if(k===g||k===m||k===i){const e=k;let r;if(t.keepQuotes!==true){k=""}while(R<j&&(r=advance())){if(r===o){k+=r+advance();continue}if(r===e){if(t.keepQuotes===true)k+=r;break}k+=r}push({type:"text",value:k});continue}if(k===p){x++;const e=S.value&&S.value.slice(-1)==="$"||_.dollar===true;const t={type:"brace",open:true,close:false,dollar:e,depth:x,commas:0,ranges:0,nodes:[]};_=push(t);w.push(_);push({type:"open",value:k});continue}if(k===d){if(_.type!=="brace"){push({type:"text",value:k});continue}const e="close";_=w.pop();_.close=true;push({type:e,value:k});x--;_=w[w.length-1];continue}if(k===a&&x>0){if(_.ranges>0){_.ranges=0;const e=_.nodes.shift();_.nodes=[e,{type:"text",value:n(_)}]}push({type:"comma",value:k});_.commas++;continue}if(k===c&&x>0&&_.commas===0){const e=_.nodes;if(x===0||e.length===0){push({type:"text",value:k});continue}if(S.type==="dot"){_.range=[];S.value+=k;S.type="range";if(_.nodes.length!==3&&_.nodes.length!==5){_.invalid=true;_.ranges=0;S.type="text";continue}_.ranges++;_.args=[];continue}if(S.type==="range"){e.pop();const t=e[e.length-1];t.value+=S.value+k;S=t;_.ranges--;continue}push({type:"dot",value:k});continue}push({type:"text",value:k})}do{_=w.pop();if(_.type!=="root"){_.nodes.forEach((e=>{if(!e.nodes){if(e.type==="open")e.isOpen=true;if(e.type==="close")e.isClose=true;if(!e.nodes)e.type="text";e.invalid=true}}));const e=w[w.length-1];const t=e.nodes.indexOf(_);e.nodes.splice(t,1,..._.nodes)}}while(w.length>0);push({type:"eos"});return b};e.exports=parse},3062:(e,t,r)=>{"use strict";const n=r(2474);e.exports=(e,t={})=>{const stringify=(e,r={})=>{const s=t.escapeInvalid&&n.isInvalidBrace(r);const o=e.invalid===true&&t.escapeInvalid===true;let i="";if(e.value){if((s||o)&&n.isOpenOrClose(e)){return"\\"+e.value}return e.value}if(e.value){return e.value}if(e.nodes){for(const t of e.nodes){i+=stringify(t)}}return i};return stringify(e)}},2474:(e,t)=>{"use strict";t.isInteger=e=>{if(typeof e==="number"){return Number.isInteger(e)}if(typeof e==="string"&&e.trim()!==""){return Number.isInteger(Number(e))}return false};t.find=(e,t)=>e.nodes.find((e=>e.type===t));t.exceedsLimit=(e,r,n=1,s)=>{if(s===false)return false;if(!t.isInteger(e)||!t.isInteger(r))return false;return(Number(r)-Number(e))/Number(n)>=s};t.escapeNode=(e,t=0,r)=>{const n=e.nodes[t];if(!n)return;if(r&&n.type===r||n.type==="open"||n.type==="close"){if(n.escaped!==true){n.value="\\"+n.value;n.escaped=true}}};t.encloseBrace=e=>{if(e.type!=="brace")return false;if(e.commas>>0+e.ranges>>0===0){e.invalid=true;return true}return false};t.isInvalidBrace=e=>{if(e.type!=="brace")return false;if(e.invalid===true||e.dollar)return true;if(e.commas>>0+e.ranges>>0===0){e.invalid=true;return true}if(e.open!==true||e.close!==true){e.invalid=true;return true}return false};t.isOpenOrClose=e=>{if(e.type==="open"||e.type==="close"){return true}return e.open===true||e.close===true};t.reduce=e=>e.reduce(((e,t)=>{if(t.type==="text")e.push(t.value);if(t.type==="range")t.type="text";return e}),[]);t.flatten=(...e)=>{const t=[];const flat=e=>{for(let r=0;r<e.length;r++){const n=e[r];if(Array.isArray(n)){flat(n);continue}if(n!==undefined){t.push(n)}}return t};flat(e);return t}},3845:(e,t,r)=>{"use strict";var n=r(7596);var s=r(6125);var o=s(n("String.prototype.indexOf"));e.exports=function callBoundIntrinsic(e,t){var r=n(e,!!t);if(typeof r==="function"&&o(e,".prototype.")>-1){return s(r)}return r}},6125:(e,t,r)=>{"use strict";var n=r(7797);var s=r(7596);var o=r(3798);var i=r(4785);var a=s("%Function.prototype.apply%");var c=s("%Function.prototype.call%");var u=s("%Reflect.apply%",true)||n.call(c,a);var l=r(2072);var p=s("%Math.max%");e.exports=function callBind(e){if(typeof e!=="function"){throw new i("a function is required")}var t=u(n,c,arguments);return o(t,1+p(0,e.length-(arguments.length-1)),true)};var d=function applyBind(){return u(n,a,arguments)};if(l){l(e.exports,"apply",{value:d})}else{e.exports.apply=d}},1542:(e,t,r)=>{"use strict";if(r(7914).major>=4){e.exports=r(1994)}else{e.exports=r(9304)}},1083:e=>{"use strict";function _classCallCheck(e,t){if(!(e instanceof t)){throw new TypeError("Cannot call a class as a function")}}function _possibleConstructorReturn(e,t){if(!e){throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}return t&&(typeof t==="object"||typeof t==="function")?t:e}function _inherits(e,t){if(typeof t!=="function"&&t!==null){throw new TypeError("Super expression must either be null or a function, not "+typeof t)}e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:false,writable:true,configurable:true}});if(t)Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t}var t=function(e){_inherits(ChildProcessError,e);function ChildProcessError(e,t,r,n,s){_classCallCheck(this,ChildProcessError);var o=_possibleConstructorReturn(this,(ChildProcessError.__proto__||Object.getPrototypeOf(ChildProcessError)).call(this,e));Error.captureStackTrace(o,o.constructor);o.name=o.constructor.name;o.code=t;o.childProcess=r;o.stdout=n;o.stderr=s;return o}return ChildProcessError}(Error);e.exports=t},560:(e,t,r)=>{"use strict";var n=function(){function defineProperties(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||false;n.configurable=true;if("value"in n)n.writable=true;Object.defineProperty(e,n.key,n)}}return function(e,t,r){if(t)defineProperties(e.prototype,t);if(r)defineProperties(e,r);return e}}();var s=function get(e,t,r){if(e===null)e=Function.prototype;var n=Object.getOwnPropertyDescriptor(e,t);if(n===undefined){var s=Object.getPrototypeOf(e);if(s===null){return undefined}else{return get(s,t,r)}}else if("value"in n){return n.value}else{var o=n.get;if(o===undefined){return undefined}return o.call(r)}};function _classCallCheck(e,t){if(!(e instanceof t)){throw new TypeError("Cannot call a class as a function")}}function _possibleConstructorReturn(e,t){if(!e){throw new ReferenceError("this hasn't been initialised - super() hasn't been called")}return t&&(typeof t==="object"||typeof t==="function")?t:e}function _inherits(e,t){if(typeof t!=="function"&&t!==null){throw new TypeError("Super expression must either be null or a function, not "+typeof t)}e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:false,writable:true,configurable:true}});if(t)Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t}var o;if(r(7914).major>=4){o=global.Promise}else{o=r(2799)}var i=function(e){_inherits(ChildProcessPromise,e);function ChildProcessPromise(e){_classCallCheck(this,ChildProcessPromise);var t;var r;var n=_possibleConstructorReturn(this,(ChildProcessPromise.__proto__||Object.getPrototypeOf(ChildProcessPromise)).call(this,(function(n,s){t=n;r=s;if(e){e(t,r)}})));n._cpResolve=t;n._cpReject=r;n.childProcess=undefined;return n}n(ChildProcessPromise,[{key:"progress",value:function progress(e){var t=this;process.nextTick((function(){e(t.childProcess)}));return this}},{key:"then",value:function then(e,t){var r=s(ChildProcessPromise.prototype.__proto__||Object.getPrototypeOf(ChildProcessPromise.prototype),"then",this).call(this,e,t);r.childProcess=this.childProcess;return r}},{key:"catch",value:function _catch(e){var t=s(ChildProcessPromise.prototype.__proto__||Object.getPrototypeOf(ChildProcessPromise.prototype),"catch",this).call(this,e);t.childProcess=this.childProcess;return t}},{key:"done",value:function done(){this.catch((function(e){process.nextTick((function(){throw e}))}))}}]);return ChildProcessPromise}(o);i.prototype.fail=i.prototype.catch;e.exports=i},9304:(e,t,r)=>{"use strict";var n=r(5317);var s=r(349);var o=r(560);var i=r(1083);var a=Array.prototype.slice;function doExec(e,t){var r;var s=new o;var c=s._cpReject;var u=s._cpResolve;var l=a.call(t,0);l.push(callback);r=n[e].apply(n,l);function callback(e,s,o){if(e){var a=t[0]+(Array.isArray(t[1])?" "+t[1].join(" "):"");e.message+=" `"+a+"` (exited with error code "+e.code+")";e.stdout=s;e.stderr=o;var l=new i(e.message,e.code,n,s,o);c(l)}else{u({childProcess:r,stdout:s,stderr:o})}}s.childProcess=r;return s}function exec(){return doExec("exec",arguments)}function execFile(){return doExec("execFile",arguments)}function doSpawn(e,t,r,n){var s={};var a;var c=new o;var u=c._cpReject;var l=c._cpResolve;var p=n&&n.successfulExitCodes||[0];a=e(t,r,n);var d=false;var f=false;var h=n&&n.capture;if(h){for(var g=0,m=h.length;g<m;g++){var y=h[g];if(y==="stdout"){d=true}else if(y==="stderr"){f=true}}}s.childProcess=a;if(d){s.stdout="";a.stdout.on("data",(function(e){s.stdout+=e}))}if(f){s.stderr="";a.stderr.on("data",(function(e){s.stderr+=e}))}a.on("error",u);a.on("close",(function(e){if(p.indexOf(e)===-1){var n=t+(r.length?" "+r.join(" "):"");var o="`"+n+"` failed with code "+e;var c=new i(o,e,a);if(f){c.stderr=s.stderr.toString()}if(d){c.stdout=s.stdout.toString()}u(c)}else{s.code=e;l(s)}}));c.childProcess=a;return c}function spawn(e,t,r){return doSpawn(s,e,t,r)}function fork(e,t,r){return doSpawn(n.fork,e,t,r)}t.exec=exec;t.execFile=execFile;t.spawn=spawn;t.fork=fork},1793:e=>{"use strict";class ChildProcessError extends Error{constructor(e,t,r,n,s){super(e);Error.captureStackTrace(this,this.constructor);this.name=this.constructor.name;this.code=t;this.childProcess=r;this.stdout=n;this.stderr=s}}e.exports=ChildProcessError},7802:(e,t,r)=>{"use strict";var n;if(r(7914).major>=4){n=global.Promise}else{n=r(2799)}class ChildProcessPromise extends n{constructor(e){var t;var r;super(((n,s)=>{t=n;r=s;if(e){e(t,r)}}));this._cpResolve=t;this._cpReject=r;this.childProcess=undefined}progress(e){process.nextTick((()=>{e(this.childProcess)}));return this}then(e,t){var r=super.then(e,t);r.childProcess=this.childProcess;return r}catch(e){var t=super.catch(e);t.childProcess=this.childProcess;return t}done(){this.catch((e=>{process.nextTick((()=>{throw e}))}))}}ChildProcessPromise.prototype.fail=ChildProcessPromise.prototype.catch;e.exports=ChildProcessPromise},1994:(e,t,r)=>{"use strict";var n=r(5317);var s=r(349);var o=r(7802);var i=r(1793);var a=Array.prototype.slice;function doExec(e,t){var r;var s=new o;var c=s._cpReject;var u=s._cpResolve;var l=a.call(t,0);l.push(callback);r=n[e].apply(n,l);function callback(e,s,o){if(e){var a=t[0]+(Array.isArray(t[1])?" "+t[1].join(" "):"");e.message+=" `"+a+"` (exited with error code "+e.code+")";e.stdout=s;e.stderr=o;var l=new i(e.message,e.code,n,s,o);c(l)}else{u({childProcess:r,stdout:s,stderr:o})}}s.childProcess=r;return s}function exec(){return doExec("exec",arguments)}function execFile(){return doExec("execFile",arguments)}function doSpawn(e,t,r,n){var s={};var a;var c=new o;var u=c._cpReject;var l=c._cpResolve;var p=n&&n.successfulExitCodes||[0];a=e(t,r,n);var d=false;var f=false;var h=n&&n.capture;if(h){for(var g=0,m=h.length;g<m;g++){var y=h[g];if(y==="stdout"){d=true}else if(y==="stderr"){f=true}}}s.childProcess=a;if(d){s.stdout="";a.stdout.on("data",(function(e){s.stdout+=e}))}if(f){s.stderr="";a.stderr.on("data",(function(e){s.stderr+=e}))}a.on("error",u);a.on("close",(function(e){if(p.indexOf(e)===-1){var n=t+(r.length?" "+r.join(" "):"");var o="`"+n+"` failed with code "+e;var c=new i(o,e,a);if(f){c.stderr=s.stderr.toString()}if(d){c.stdout=s.stdout.toString()}u(c)}else{s.code=e;l(s)}}));c.childProcess=a;return c}function spawn(e,t,r){return doSpawn(s,e,t,r)}function fork(e,t,r){return doSpawn(n.fork,e,t,r)}t.exec=exec;t.execFile=execFile;t.spawn=spawn;t.fork=fork},349:(e,t,r)=>{"use strict";var n=r(5317);var s=r(5386);var o=r(232);var i=n.spawnSync;function spawn(e,t,r){var i;var a;i=s(e,t,r);a=n.spawn(i.command,i.args,i.options);o.hookChildProcess(a,i);return a}function spawnSync(e,t,n){var a;var c;if(!i){try{i=r(8426)}catch(e){throw new Error("In order to use spawnSync on node 0.10 or older, you must "+"install spawn-sync:\n\n"+" npm install spawn-sync --save")}}a=s(e,t,n);c=i(a.command,a.args,a.options);c.error=c.error||o.verifyENOENTSync(c.status,a);return c}e.exports=spawn;e.exports.spawn=spawn;e.exports.sync=spawnSync;e.exports._parse=s;e.exports._enoent=o},232:(e,t,r)=>{"use strict";var n=process.platform==="win32";var s=r(6172);var o=process.version.indexOf("v0.10.")===0;function notFoundError(e,t){var r;r=new Error(t+" "+e+" ENOENT");r.code=r.errno="ENOENT";r.syscall=t+" "+e;return r}function hookChildProcess(e,t){var r;if(!n){return}r=e.emit;e.emit=function(n,s){var o;if(n==="exit"){o=verifyENOENT(s,t,"spawn");if(o){return r.call(e,"error",o)}}return r.apply(e,arguments)}}function verifyENOENT(e,t){if(n&&e===1&&!t.file){return notFoundError(t.original,"spawn")}return null}function verifyENOENTSync(e,t){if(n&&e===1&&!t.file){return notFoundError(t.original,"spawnSync")}if(o&&e===-1){t.file=n?t.file:s(t.original);if(!t.file){return notFoundError(t.original,"spawnSync")}}return null}e.exports.hookChildProcess=hookChildProcess;e.exports.verifyENOENT=verifyENOENT;e.exports.verifyENOENTSync=verifyENOENTSync;e.exports.notFoundError=notFoundError},4269:e=>{"use strict";e.exports=function(){if(process.platform!=="win32"){return false}var e=process.version.substr(1).split(".").map((function(e){return parseInt(e,10)}));return e[0]===0&&e[1]<12}()},5386:(e,t,r)=>{"use strict";var n=r(9896);var s=r(9939);var o=r(6172);var i=r(4269);var a=process.platform==="win32";var c=new s({max:50,maxAge:30*1e3});function readShebang(e){var t;var r;var s;var o;if(c.has(e)){return c.get(e)}t=new Buffer(150);try{r=n.openSync(e,"r");n.readSync(r,t,0,150,0);n.closeSync(r)}catch(e){}s=t.toString().trim().match(/#!(.+)/i);if(s){o=s[1].replace(/\/usr\/bin\/env\s+/i,"")}c.set(e,o);return o}function escapeArg(e,t){e=""+e;if(!t){e=e.replace(/([\(\)%!\^<>&|;,"'\s])/g,"^$1")}else{e=e.replace(/(\\*)"/g,'$1$1\\"');e=e.replace(/(\\*)$/,"$1$1");e='"'+e+'"'}return e}function escapeCommand(e){return/^[a-z0-9_-]+$/i.test(e)?e:escapeArg(e,true)}function requiresShell(e){return!/\.(?:com|exe)$/i.test(e)}function parse(e,t,r){var n;var s;var c;var u;var l;if(t&&!Array.isArray(t)){r=t;t=null}t=t?t.slice(0):[];r=r||{};u=e;if(a){c=o(e);c=c||o(e,true);n=c&&readShebang(c);l=r.shell||i;if(n){t.unshift(c);e=n;l=l||requiresShell(o(n)||o(n,true))}else{l=l||requiresShell(c)}if(l){s=e!=="echo";e=escapeCommand(e);t=t.map((function(e){return escapeArg(e,s)}));t=["/s","/c",'"'+e+(t.length?" "+t.join(" "):"")+'"'];e=process.env.comspec||"cmd.exe";r.windowsVerbatimArguments=true}}return{command:e,args:t,options:r,file:c,original:u}}e.exports=parse},6172:(e,t,r)=>{"use strict";var n=r(6928);var s=r(2871);var o=r(9939);var i=new o({max:50,maxAge:30*1e3});function resolveCommand(e,t){var r;t=!!t;r=i.get(e+"!"+t);if(i.has(e)){return i.get(e)}try{r=!t?s.sync(e):s.sync(e,{pathExt:n.delimiter+(process.env.PATHEXT||"")})}catch(e){}i.set(e+"!"+t,r);return r}e.exports=resolveCommand},2071:(e,t,r)=>{"use strict";var n=r(2072);var s=r(9546);var o=r(4785);var i=r(5583);e.exports=function defineDataProperty(e,t,r){if(!e||typeof e!=="object"&&typeof e!=="function"){throw new o("`obj` must be an object or a function`")}if(typeof t!=="string"&&typeof t!=="symbol"){throw new o("`property` must be a string or a symbol`")}if(arguments.length>3&&typeof arguments[3]!=="boolean"&&arguments[3]!==null){throw new o("`nonEnumerable`, if provided, must be a boolean or null")}if(arguments.length>4&&typeof arguments[4]!=="boolean"&&arguments[4]!==null){throw new o("`nonWritable`, if provided, must be a boolean or null")}if(arguments.length>5&&typeof arguments[5]!=="boolean"&&arguments[5]!==null){throw new o("`nonConfigurable`, if provided, must be a boolean or null")}if(arguments.length>6&&typeof arguments[6]!=="boolean"){throw new o("`loose`, if provided, must be a boolean")}var a=arguments.length>3?arguments[3]:null;var c=arguments.length>4?arguments[4]:null;var u=arguments.length>5?arguments[5]:null;var l=arguments.length>6?arguments[6]:false;var p=!!i&&i(e,t);if(n){n(e,t,{configurable:u===null&&p?p.configurable:!u,enumerable:a===null&&p?p.enumerable:!a,value:r,writable:c===null&&p?p.writable:!c})}else if(l||!a&&!c&&!u){e[t]=r}else{throw new s("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")}}},2072:(e,t,r)=>{"use strict";var n=r(7596);var s=n("%Object.defineProperty%",true)||false;if(s){try{s({},"a",{value:1})}catch(e){s=false}}e.exports=s},1247:e=>{"use strict";e.exports=EvalError},6621:e=>{"use strict";e.exports=Error},6136:e=>{"use strict";e.exports=RangeError},252:e=>{"use strict";e.exports=ReferenceError},9546:e=>{"use strict";e.exports=SyntaxError},4785:e=>{"use strict";e.exports=TypeError},1223:e=>{"use strict";e.exports=URIError},9730:(e,t,r)=>{"use strict";
2
2
  /*!
3
3
  * fill-range <https://github.com/jonschlinkert/fill-range>
4
4
  *