mirror of
https://git.mirrors.martin98.com/https://github.com/actions/toolkit
synced 2026-04-24 13:48:05 +08:00
Use options to specify download folder
This commit is contained in:
@@ -56,8 +56,8 @@ export async function downloadArtifact(
|
||||
options?: DownloadArtifactOptions
|
||||
): Promise<DownloadArtifactResponse> {
|
||||
let downloadPath = options?.path || getGitHubWorkspaceDir()
|
||||
if (options?.createArtifactFolder) {
|
||||
downloadPath = path.join(downloadPath, 'my-artifact') // TODO: need to pass artifact name
|
||||
if (options?.createArtifactFolderName) {
|
||||
downloadPath = path.join(downloadPath, options?.createArtifactFolderName)
|
||||
}
|
||||
|
||||
if (!(await exists(downloadPath))) {
|
||||
|
||||
Reference in New Issue
Block a user