Read-only mirror — the public repositories of the Forgejo instance, refreshed every 10 minutes. The live instance (fg.dieschoenewolke.de) is reachable only over the VPN; clone here with https://git.dieschoenewolke.de/git/<owner>/<repo>.git.
summaryrefslogtreecommitdiff
path: root/src/github-api-helper.ts
diff options
context:
space:
mode:
authoreric sciple <ericsciple@users.noreply.github.com>2020-05-07 12:11:11 -0400
committerGitHub <noreply@github.com>2020-05-07 12:11:11 -0400
commite55727d418e99c52db29fa5e822f0eb64ce9b1ca (patch)
tree3fcc55e6e8d3277fef16ff218f15e66d04bbda57 /src/github-api-helper.ts
parent180495b609267603108b2c62f0b5f40e7d1aba40 (diff)
consume new @actions/github for GHES support (#236)
Diffstat (limited to 'src/github-api-helper.ts')
-rw-r--r--src/github-api-helper.ts7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/github-api-helper.ts b/src/github-api-helper.ts
index df11a85..e559c45 100644
--- a/src/github-api-helper.ts
+++ b/src/github-api-helper.ts
@@ -6,9 +6,8 @@ import * as io from '@actions/io'
import * as path from 'path'
import * as retryHelper from './retry-helper'
import * as toolCache from '@actions/tool-cache'
-import * as urlHelper from './url-helper'
import {default as uuid} from 'uuid/v4'
-import {ReposGetArchiveLinkParams} from '@octokit/rest'
+import {Octokit} from '@octokit/rest'
const IS_WINDOWS = process.platform === 'win32'
@@ -75,8 +74,8 @@ async function downloadArchive(
ref: string,
commit: string
): Promise<Buffer> {
- const octokit = new github.GitHub(authToken, {baseUrl: urlHelper.getApiUrl()})
- const params: ReposGetArchiveLinkParams = {
+ const octokit = new github.GitHub(authToken)
+ const params: Octokit.ReposGetArchiveLinkParams = {
owner: owner,
repo: repo,
archive_format: IS_WINDOWS ? 'zipball' : 'tarball',