mirror of
https://github.com/astral-sh/setup-uv.git
synced 2026-02-18 06:51:45 +00:00
Ran 'npm run all'
This commit is contained in:
parent
e381565822
commit
df0cc1dcf0
1 changed files with 9 additions and 4 deletions
13
dist/save-cache/index.js
generated
vendored
13
dist/save-cache/index.js
generated
vendored
|
|
@ -90056,12 +90056,17 @@ async function saveCache() {
|
||||||
if (inputs_1.pruneCache) {
|
if (inputs_1.pruneCache) {
|
||||||
await pruneCache();
|
await pruneCache();
|
||||||
}
|
}
|
||||||
core.info(`Saving cache path: ${inputs_1.cacheLocalPath}`);
|
let actualCachePath = inputs_1.cacheLocalPath;
|
||||||
if (!fs.existsSync(inputs_1.cacheLocalPath) && !inputs_1.ignoreNothingToCache) {
|
if (process.env.UV_CACHE_DIR && process.env.UV_CACHE_DIR !== inputs_1.cacheLocalPath) {
|
||||||
throw new Error(`Cache path ${inputs_1.cacheLocalPath} does not exist on disk. This likely indicates that there are no dependencies to cache. Consider disabling the cache input if it is not needed.`);
|
core.warning(`The environment variable UV_CACHE_DIR has been changed to "${process.env.UV_CACHE_DIR}", by an action or step running after astral-sh/setup-uv. This can lead to unexpected behavior. If you expected this to happen set the cache-local-path input to "${process.env.UV_CACHE_DIR}" instead of "${inputs_1.cacheLocalPath}".`);
|
||||||
|
actualCachePath = process.env.UV_CACHE_DIR;
|
||||||
|
}
|
||||||
|
core.info(`Saving cache path: ${actualCachePath}`);
|
||||||
|
if (!fs.existsSync(actualCachePath) && !inputs_1.ignoreNothingToCache) {
|
||||||
|
throw new Error(`Cache path ${actualCachePath} does not exist on disk. This likely indicates that there are no dependencies to cache. Consider disabling the cache input if it is not needed.`);
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
await cache.saveCache([inputs_1.cacheLocalPath], cacheKey);
|
await cache.saveCache([actualCachePath], cacheKey);
|
||||||
core.info(`cache saved with the key: ${cacheKey}`);
|
core.info(`cache saved with the key: ${cacheKey}`);
|
||||||
}
|
}
|
||||||
catch (e) {
|
catch (e) {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue