5
0
mirror of https://github.com/astral-sh/setup-uv.git synced 2025-12-15 11:07:14 +00:00

Add more debug logs (#297)

This commit is contained in:
Kevin Stillhammer
2025-02-21 11:10:37 +01:00
committed by GitHub
parent a4fbf7b827
commit 1edb52594c
3 changed files with 10 additions and 0 deletions

5
dist/setup/index.js generated vendored
View File

@@ -95208,6 +95208,7 @@ async function downloadVersion(platform, arch, version, checkSum, githubToken) {
return { version: resolvedVersion, cachedToolDir };
}
async function resolveVersion(versionInput, githubToken) {
core.debug(`Resolving version: ${versionInput}`);
const version = versionInput === "latest"
? await getLatestVersion(githubToken)
: versionInput;
@@ -95216,6 +95217,7 @@ async function resolveVersion(versionInput, githubToken) {
return version;
}
const availableVersions = await getAvailableVersions(githubToken);
core.debug(`Available versions: ${availableVersions}`);
const resolvedVersion = tc.evaluateVersions(availableVersions, version);
if (resolvedVersion === "") {
throw new Error(`No version found for ${version}`);
@@ -95246,6 +95248,7 @@ async function getReleaseTagNames(octokit) {
return response.map((release) => release.tag_name);
}
async function getLatestVersion(githubToken) {
core.debug("Getting latest version...");
const octokit = new PaginatingOctokit({
auth: githubToken,
});
@@ -95266,6 +95269,7 @@ async function getLatestVersion(githubToken) {
if (!latestRelease) {
throw new Error("Could not determine latest release.");
}
core.debug(`Latest version: ${latestRelease.tag_name}`);
return latestRelease.tag_name;
}
async function getLatestRelease(octokit) {
@@ -95818,6 +95822,7 @@ const node_fs_1 = __importDefault(__nccwpck_require__(3024));
const core = __importStar(__nccwpck_require__(7484));
const toml = __importStar(__nccwpck_require__(7106));
function getUvVersionFromConfigFile(filePath) {
core.debug(`Trying to find required-version for uv in: ${filePath}`);
if (!node_fs_1.default.existsSync(filePath)) {
core.warning(`Could not find file: ${filePath}`);
return undefined;