v2.4.0
版本发布时间: 2021-08-06 00:44:33
actions/setup-node最新发布版本:v4.0.4(2024-09-19 22:07:35)
This release introduces dependency caching support for mono repos and repositories with complex structure (#305).
By default, the action searches for the dependency file (package-lock.json
or yarn.lock
) in the repository root. Use the cache-dependency-path
input for cases when multiple dependency files are used, or they are located in different subdirectories. This input supports wildcards or a list of file names for caching multiple dependencies.
Yaml example:
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: 14
cache: npm
cache-dependency-path: 'sub-project/package-lock.json'
For more examples of using cache-dependency-path
input, see the Advanced usage guide.