MCPcopy Create free account
hub / github.com/Azure/powershell / getDownloadUrlFromGHRelease

Method getDownloadUrlFromGHRelease

lib/index.js:7825–7837  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

7823 });
7824 }
7825 getDownloadUrlFromGHRelease() {
7826 return __awaiter(this, void 0, void 0, function* () {
7827 var _a;
7828 core.debug("Getting versions manifest from GHRelease.");
7829 const releases = yield tc.getManifestFromRepo("Azure", "az-ps-module-versions", this.githubAuth, "main");
7830 core.debug(JSON.stringify(releases));
7831 const releaseInfo = (_a = releases.filter(release => release.version === this.version)) === null || _a === void 0 ? void 0 : _a[0];
7832 if (!releaseInfo || releaseInfo.files.length === 0) {
7833 throw new Error(`Version ${this.version} not present in versions manifest of GHRelease.`);
7834 }
7835 return releaseInfo.files[0].download_url;
7836 });
7837 }
7838}
7839exports.AzModuleInstaller = AzModuleInstaller;
7840

Callers 1

Calls 1

stringifyMethod · 0.80

Tested by

no test coverage detected