
Cache
actions/cache
Cache dependencies and build outputs to improve workflow execution time
4,300stars
950forks
8.0M uses
Performancev3.3.2About
This action allows caching dependencies and build outputs to improve workflow execution time. It can cache any files or directories you specify, making subsequent runs faster by restoring cached content.
Workflow Example
name: CI
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/cache@v4
with:
fetch-depth: 0
- name: Run tests
run: npm testInputs
repositoryRepository name with owner
Default: ${{ github.repository }}
refThe branch, tag or SHA to checkout
tokenPersonal access token (PAT)
Default: ${{ github.token }}
fetch-depthNumber of commits to fetch
Default: 1
Related Actions
Metadata
Language
TypeScript
Last Updated
1/18/2024
Latest Release
v3.3.2