Skip to content

Commit

Permalink
feat: use GITHUB_API_URL as baseUrl for octokit (#43)
Browse files Browse the repository at this point in the history
* feat: use GITHUB_API_URL as baseUrl for octokit

Allow also to connect to GHE instances when using the API URL from the envs

* feat: use GITHUB_API_URL as baseUrl for octokit (build)
  • Loading branch information
fty4 authored Apr 16, 2024
1 parent 6d7c198 commit 316f8ac
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ async function main() {

const octokit = new Octokit({
auth: `token ${GITHUB_TOKEN}`,
baseUrl: process.env.GITHUB_API_URL || "https://api.github.com",
userAgent: "pascalgn/size-label-action"
});

Expand Down
1 change: 1 addition & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ async function main() {

const octokit = new Octokit({
auth: `token ${GITHUB_TOKEN}`,
baseUrl: process.env.GITHUB_API_URL || "https://api.github.com",
userAgent: "pascalgn/size-label-action"
});

Expand Down

0 comments on commit 316f8ac

Please sign in to comment.