mirror of
https://github.com/actions/download-artifact.git
synced 2025-08-22 23:51:19 +08:00
Compare commits
4 Commits
v4-beta-in
...
robherley/
Author | SHA1 | Date | |
---|---|---|---|
|
3132d12662 | ||
|
5be1d38671 | ||
|
465b526e63 | ||
|
8b83831f82 |
20463
dist/index.js
vendored
20463
dist/index.js
vendored
File diff suppressed because it is too large
Load Diff
@@ -1,7 +1,8 @@
|
|||||||
import * as os from 'os'
|
import * as os from 'os'
|
||||||
import * as path from 'path'
|
import * as path from 'path'
|
||||||
import * as core from '@actions/core'
|
import * as core from '@actions/core'
|
||||||
import * as artifact from '@actions/artifact'
|
import artifactClient from '@actions/artifact'
|
||||||
|
import type {Artifact, FindOptions} from '@actions/artifact'
|
||||||
import {Inputs, Outputs} from './constants'
|
import {Inputs, Outputs} from './constants'
|
||||||
|
|
||||||
const PARALLEL_DOWNLOADS = 5
|
const PARALLEL_DOWNLOADS = 5
|
||||||
@@ -34,7 +35,7 @@ async function run(): Promise<void> {
|
|||||||
const resolvedPath = path.resolve(inputs.path)
|
const resolvedPath = path.resolve(inputs.path)
|
||||||
core.debug(`Resolved path is ${resolvedPath}`)
|
core.debug(`Resolved path is ${resolvedPath}`)
|
||||||
|
|
||||||
const options: artifact.FindOptions = {}
|
const options: FindOptions = {}
|
||||||
if (inputs.token) {
|
if (inputs.token) {
|
||||||
const [repositoryOwner, repositoryName] = inputs.repository.split('/')
|
const [repositoryOwner, repositoryName] = inputs.repository.split('/')
|
||||||
if (!repositoryOwner || !repositoryName) {
|
if (!repositoryOwner || !repositoryName) {
|
||||||
@@ -51,8 +52,7 @@ async function run(): Promise<void> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const artifactClient = artifact.create()
|
let artifacts: Artifact[] = []
|
||||||
let artifacts: artifact.Artifact[] = []
|
|
||||||
|
|
||||||
if (isSingleArtifactDownload) {
|
if (isSingleArtifactDownload) {
|
||||||
core.info(`Downloading single artifact`)
|
core.info(`Downloading single artifact`)
|
||||||
|
Reference in New Issue
Block a user