fix(dependencies): increase cache size for npm, yarn, and pnpm installations
Signed-off-by: zhenyus <zhenyus@mathmast.com>
This commit is contained in:
parent
0b1f5b709c
commit
912b1fd710
@ -85,7 +85,7 @@ class DependenciesResolver {
|
||||
|
||||
if (cachingEnabled) {
|
||||
steps.dir(this.workspace) {
|
||||
steps.cache(maxCacheSize: 512, caches: [[$class: 'ArbitraryFileCache', includes: '**/*', path: "${steps.env.WORKSPACE}/.${configurations.name}-npm-cache", cacheValidityDecidingFile: 'package-lock.json']]) {
|
||||
steps.cache(maxCacheSize: 2048, caches: [[$class: 'ArbitraryFileCache', includes: '**/*', path: "${steps.env.WORKSPACE}/.${configurations.name}-npm-cache", cacheValidityDecidingFile: 'package-lock.json']]) {
|
||||
steps.sh "mkdir -p ${steps.env.WORKSPACE}/.${configurations.name}-npm-cache"
|
||||
steps.sh "npm install --cache ${steps.env.WORKSPACE}/.${configurations.name}-npm-cache --prefer-offline --no-audit"
|
||||
}
|
||||
@ -111,7 +111,7 @@ class DependenciesResolver {
|
||||
|
||||
if (cachingEnabled) {
|
||||
steps.dir(this.workspace) {
|
||||
steps.cache(maxCacheSize: 512, caches: [[$class: 'ArbitraryFileCache', includes: '**/*', path: "${steps.env.WORKSPACE}/.${configurations.name}-yarn-cache", cacheValidityDecidingFile: 'yarn.lock']]) {
|
||||
steps.cache(maxCacheSize: 2048, caches: [[$class: 'ArbitraryFileCache', includes: '**/*', path: "${steps.env.WORKSPACE}/.${configurations.name}-yarn-cache", cacheValidityDecidingFile: 'yarn.lock']]) {
|
||||
steps.sh "mkdir -p ${steps.env.WORKSPACE}/.${configurations.name}-pnpm-cache"
|
||||
steps.sh "yarn install --cache-folder ${steps.env.WORKSPACE}/.${configurations.name}-pnpm-cache --prefer-offline"
|
||||
}
|
||||
@ -137,7 +137,7 @@ class DependenciesResolver {
|
||||
|
||||
if (cachingEnabled) {
|
||||
steps.dir(this.workspace) {
|
||||
steps.cache(maxCacheSize: 512, caches: [[$class: 'ArbitraryFileCache', includes: '**/*', path: "${steps.env.WORKSPACE}/.${configurations.name}-pnpm-cache", cacheValidityDecidingFile: 'pnpm-lock.yaml']]) {
|
||||
steps.cache(maxCacheSize: 2048, caches: [[$class: 'ArbitraryFileCache', includes: '**/*', path: "${steps.env.WORKSPACE}/.${configurations.name}-pnpm-cache", cacheValidityDecidingFile: 'pnpm-lock.yaml']]) {
|
||||
steps.sh "mkdir -p ${steps.env.WORKSPACE}/.${configurations.name}-pnpm-cache"
|
||||
steps.sh "pnpm install --store-dir ${steps.env.WORKSPACE}/.${configurations.name}-pnpm-cache --prefer-offline"
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user