mirror of
https://code.forgejo.org/actions/checkout.git
synced 2025-04-23 20:05:33 +00:00
.
This commit is contained in:
parent
ad6dd29a96
commit
4af80cb867
4 changed files with 68 additions and 68 deletions
|
@ -6,7 +6,7 @@ import * as gitCommandManager from './git-command-manager'
|
|||
import * as io from '@actions/io'
|
||||
import * as path from 'path'
|
||||
import * as refHelper from './ref-helper'
|
||||
import * as repositoryApiHelper from './repository-api-helper'
|
||||
import * as githubApiHelper from './github-api-helper'
|
||||
import {IGitCommandManager} from './git-command-manager'
|
||||
|
||||
const authConfigKey = `http.https://github.com/.extraheader`
|
||||
|
@ -79,7 +79,7 @@ export async function getSource(settings: ISourceSettings): Promise<void> {
|
|||
}
|
||||
|
||||
if (!git || `${1}` == '1') {
|
||||
await repositoryApiHelper.download(
|
||||
await githubApiHelper.downloadRepository(
|
||||
settings.accessToken,
|
||||
settings.repositoryOwner,
|
||||
settings.repositoryName,
|
||||
|
|
|
@ -3,7 +3,7 @@ import {ReposGetArchiveLinkParams} from '@octokit/rest'
|
|||
|
||||
const IS_WINDOWS = process.platform === 'win32'
|
||||
|
||||
export async function download(
|
||||
export async function downloadRepository(
|
||||
accessToken: string,
|
||||
owner: string,
|
||||
repo: string,
|
||||
|
@ -20,5 +20,5 @@ export async function download(
|
|||
const response = await octokit.repos.getArchiveLink(params)
|
||||
console.log(`status=${response.status}`)
|
||||
console.log(`headers=${JSON.stringify(response.headers)}`)
|
||||
console.log(`data=${JSON.stringify(response.data)}`)
|
||||
console.log(`data=${JSON.stringify(typeof response.data)}`)
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue