5
0
mirror of https://github.com/astral-sh/setup-uv.git synced 2026-03-29 01:49:53 +00:00

Always use api.github.com (#191)

The octokit client would default to the URL of enterprise instances and
then not be able to find the uv repo.

Closes: #188
This commit is contained in:
Kevin Stillhammer
2024-12-11 18:42:54 +01:00
committed by GitHub
parent 884a30e33c
commit 3460fe1a9a
5 changed files with 18 additions and 10 deletions

View File

@@ -1,7 +1,7 @@
import * as github from "@actions/github";
import * as core from "@actions/core";
import { OWNER, REPO } from "./utils/constants";
import { GITHUB_COM_API, OWNER, REPO } from "./utils/constants";
import * as semver from "semver";
import { updateChecksums } from "./download/checksum/update-known-checksums";
@@ -10,7 +10,7 @@ async function run(): Promise<void> {
const checksumFilePath = process.argv.slice(2)[0];
const github_token = process.argv.slice(2)[1];
const octokit = github.getOctokit(github_token);
const octokit = github.getOctokit(github_token, { baseUrl: GITHUB_COM_API });
const response = await octokit.paginate(octokit.rest.repos.listReleases, {
owner: OWNER,