mirror of
https://github.com/oven-sh/bun
synced 2026-02-09 10:28:47 +00:00
Fix workflow
This commit is contained in:
10
.github/actions/cache/action.mjs
vendored
10
.github/actions/cache/action.mjs
vendored
@@ -10,12 +10,14 @@ const restoreKeys = getMultilineInput("restore-keys");
|
||||
const cacheDir = getInput("cache-dir") || join(tmpdir(), ".github", "cache");
|
||||
|
||||
export async function restoreCache() {
|
||||
console.log("Restoring cache...");
|
||||
|
||||
if (isGithubHosted()) {
|
||||
console.log("Using GitHub cache...");
|
||||
try {
|
||||
return await restoreGithubCache([path], key, restoreKeys);
|
||||
const cacheKey = await restoreGithubCache([path], key, restoreKeys);
|
||||
return {
|
||||
cacheHit: !!cacheKey,
|
||||
cacheKey: cacheKey ?? key,
|
||||
};
|
||||
} catch (error) {
|
||||
console.error("Failed to restore cache:", error);
|
||||
return null;
|
||||
@@ -69,8 +71,6 @@ export async function restoreCache() {
|
||||
}
|
||||
|
||||
export async function saveCache() {
|
||||
console.log("Saving cache...");
|
||||
|
||||
if (isGithubHosted()) {
|
||||
console.log("Using GitHub cache...");
|
||||
try {
|
||||
|
||||
8
.github/actions/cache/dist/action.mjs
vendored
8
.github/actions/cache/dist/action.mjs
vendored
@@ -69631,11 +69631,14 @@ import {cpSync, existsSync, mkdirSync, readdirSync} from "node:fs";
|
||||
import {tmpdir} from "node:os";
|
||||
import {join} from "node:path";
|
||||
async function restoreCache() {
|
||||
console.log("Restoring cache...");
|
||||
if (isGithubHosted()) {
|
||||
console.log("Using GitHub cache...");
|
||||
try {
|
||||
return await cache.restoreCache([path], key, restoreKeys);
|
||||
const cacheKey = await cache.restoreCache([path], key, restoreKeys);
|
||||
return {
|
||||
cacheHit: !!cacheKey,
|
||||
cacheKey: cacheKey ?? key
|
||||
};
|
||||
} catch (error) {
|
||||
console.error("Failed to restore cache:", error);
|
||||
return null;
|
||||
@@ -69683,7 +69686,6 @@ async function restoreCache() {
|
||||
return null;
|
||||
}
|
||||
async function saveCache() {
|
||||
console.log("Saving cache...");
|
||||
if (isGithubHosted()) {
|
||||
console.log("Using GitHub cache...");
|
||||
try {
|
||||
|
||||
@@ -69631,11 +69631,14 @@ import {cpSync, existsSync, mkdirSync, readdirSync} from "node:fs";
|
||||
import {tmpdir} from "node:os";
|
||||
import {join} from "node:path";
|
||||
async function restoreCache() {
|
||||
console.log("Restoring cache...");
|
||||
if (isGithubHosted()) {
|
||||
console.log("Using GitHub cache...");
|
||||
try {
|
||||
return await cache.restoreCache([path], key, restoreKeys);
|
||||
const cacheKey = await cache.restoreCache([path], key, restoreKeys);
|
||||
return {
|
||||
cacheHit: !!cacheKey,
|
||||
cacheKey: cacheKey ?? key
|
||||
};
|
||||
} catch (error) {
|
||||
console.error("Failed to restore cache:", error);
|
||||
return null;
|
||||
@@ -69683,7 +69686,6 @@ async function restoreCache() {
|
||||
return null;
|
||||
}
|
||||
async function saveCache() {
|
||||
console.log("Saving cache...");
|
||||
if (isGithubHosted()) {
|
||||
console.log("Using GitHub cache...");
|
||||
try {
|
||||
|
||||
8
.github/actions/cache/dist/save/action.mjs
vendored
8
.github/actions/cache/dist/save/action.mjs
vendored
@@ -69631,11 +69631,14 @@ import {cpSync, existsSync, mkdirSync, readdirSync} from "node:fs";
|
||||
import {tmpdir} from "node:os";
|
||||
import {join} from "node:path";
|
||||
async function restoreCache() {
|
||||
console.log("Restoring cache...");
|
||||
if (isGithubHosted()) {
|
||||
console.log("Using GitHub cache...");
|
||||
try {
|
||||
return await cache.restoreCache([path], key, restoreKeys);
|
||||
const cacheKey = await cache.restoreCache([path], key, restoreKeys);
|
||||
return {
|
||||
cacheHit: !!cacheKey,
|
||||
cacheKey: cacheKey ?? key
|
||||
};
|
||||
} catch (error) {
|
||||
console.error("Failed to restore cache:", error);
|
||||
return null;
|
||||
@@ -69683,7 +69686,6 @@ async function restoreCache() {
|
||||
return null;
|
||||
}
|
||||
async function saveCache() {
|
||||
console.log("Saving cache...");
|
||||
if (isGithubHosted()) {
|
||||
console.log("Using GitHub cache...");
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user