How to Cache Dependencies in GitHub Actions
A workflow that runs npm ci on every push downloads the same few hundred packages from the registry each time, even when the lockfile hasn鈥檛 changed in a week. On a project with a real dependency tree that鈥檚 a minute or two gone before the first test starts, and you pay it again on every push and every pull request. actions/cache keeps those downloads between runs and hands them back when nothing relevant has changed. ...