Skip to content

api_function_savegithubactionscache

hugoalh edited this page Mar 2, 2023 · 9 revisions

Save-GitHubActionsCache

πŸ”˜ NodeJS Wrapper: This dependents and requires NodeJS to invoke.

  • Type: Function
  • In Version: >= v0.5.0
  • Alias:
    • Export-GitHubActionsCache

Description

# Parameter Set: LiteralPath
Save-GitHubActionsCache [-Key] <String> -LiteralPath <String[]> [-UploadChunkSizes <UInt32>] [-UploadConcurrency <Byte>]

# Parameter Set: Path (Default)
Save-GitHubActionsCache [-Key] <String> [-Path] <String[]> [-UploadChunkSizes <UInt32>] [-UploadConcurrency <Byte>]

Save cache to persist the data and/or share with the future jobs in the same workflow.

Parameter

Key

<String> Key of the cache.

  • Parameter Set:
    • LiteralPath
    • Path
  • Position: 0
  • Accept Pipeline Input: False ❌
  • Accept Pipeline Input By Property Name: True βœ”
  • Accept Wildcard Characters: False ❌
  • Alias:
    • Name

LiteralPath

<String[]> Literal paths of the cache.

  • Parameter Set: LiteralPath
  • Position: Named
  • Accept Pipeline Input: False ❌
  • Accept Pipeline Input By Property Name: True βœ”
  • Accept Wildcard Characters: False ❌
  • Alias:
    • LiteralFile
    • LiteralFiles
    • LiteralPaths
    • LP
    • PSPath
    • PSPaths

⚠ Important: Previously, this parameter did accept pipeline input, but often cause issues, avoid if possible.

Path

<String[]> Paths of the cache.

  • Parameter Set: Path
  • Position: 1
  • Accept Pipeline Input: False ❌
  • Accept Pipeline Input By Property Name: True βœ”
  • Accept Wildcard Characters: True βœ”
  • Alias:
    • File
    • Files
    • Paths

⚠ Important: Previously, this parameter did accept pipeline input, but often cause issues, avoid if possible.

UploadChunkSizes

[Optional] <UInt32> Maximum chunk size of the cache, by KB in range 1KB~1GB (i.e.: 1~1048576).

  • Parameter Set:
    • LiteralPath
    • Path
  • Position: Named
  • Accept Pipeline Input: False ❌
  • Accept Pipeline Input By Property Name: True βœ”
  • Accept Wildcard Characters: False ❌
  • Alias:
    • ChunkSize
    • ChunkSizes
    • UploadChunkSize

UploadConcurrency

[Optional] <Byte> Number of parallel uploads of the cache, in range 1~16.

  • Parameter Set:
    • LiteralPath
    • Path
  • Position: Named
  • Accept Pipeline Input: False ❌
  • Accept Pipeline Input By Property Name: True βœ”
  • Accept Wildcard Characters: False ❌
  • Alias:
    • Concurrency

Output

<String> ID of the cache.

Guide

API

Enum

Enum Flag

Function

Function Alias

Clone this wiki locally