Skip to content

Latest commit

 

History

History
128 lines (98 loc) · 3.77 KB

cache-beta-v0.md

File metadata and controls

128 lines (98 loc) · 3.77 KB
title description ms.date monikerRange
CacheBeta@0 - Cache (Beta) v0 task
Cache files between runs (task version 0).
05/14/2024
>=azure-pipelines-2020

CacheBeta@0 - Cache (Beta) v0 task

:::moniker range=">=azure-pipelines-2020"

Improve build performance by using this task to cache files, like dependencies, between pipeline runs.

Note

There is a newer version of this task. Use Cache@2.

:::moniker-end

Syntax

:::moniker range=">=azure-pipelines-2020"

# Cache (Beta) v0
# Cache files between runs.
- task: CacheBeta@0
  inputs:
    key: # string. Required. Key. 
    path: # string. Required. Path. 
    #cacheHitVar: # string. Cache hit variable.

:::moniker-end

Inputs

:::moniker range=">=azure-pipelines-2020"

key - Key
string. Required.

The key (unique identifier) for the cache. This should be a newline-delimited list of strings or file paths. File paths can be absolute or relative to $(System.DefaultWorkingDirectory).


:::moniker-end

:::moniker range=">=azure-pipelines-2020"

path - Path
string. Required.

The path of the folder to cache. Can be fully qualified or relative to $(System.DefaultWorkingDirectory). Wildcards are not supported. Variables are supported.


:::moniker-end

:::moniker range=">=azure-pipelines-2020"

cacheHitVar - Cache hit variable
string.

The variable to set to true when the cache is restored (i.e. a cache hit). Otherwise, sets the variable to false.


:::moniker-end

Task control options

All tasks have control options in addition to their task inputs. For more information, see Control options and common task properties.

Output variables

:::moniker range=">=azure-pipelines-2020"

None.

:::moniker-end

Requirements

:::moniker range=">=azure-pipelines-2020"

Requirement Description
Pipeline types YAML, Classic build, Classic release
Runs on Agent, DeploymentGroup
Demands None
Capabilities This task does not satisfy any demands for subsequent tasks in the job.
Command restrictions Any
Settable variables Any
Agent version 2.159.2 or greater
Task category Utility

:::moniker-end