change getinput to getstate for cache ()

This commit is contained in:
Dmitry Shibanov 2023-08-10 16:32:24 +02:00 committed by GitHub
parent d82f92a0eb
commit bea5baf987
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 62 additions and 32 deletions

View file

@ -9,6 +9,7 @@ import {restoreCache} from './cache-restore';
import {isCacheFeatureAvailable} from './cache-utils';
import {getNodejsDistribution} from './distributions/installer-factory';
import {parseNodeVersionFile, printEnvDetailsAndSetOutput} from './util';
import {State} from './constants';
export async function run() {
try {
@ -60,6 +61,7 @@ export async function run() {
}
if (cache && isCacheFeatureAvailable()) {
core.saveState(State.CachePackageManager, cache);
const cacheDependencyPath = core.getInput('cache-dependency-path');
await restoreCache(cache, cacheDependencyPath);
}