Skip to content

Commit

Permalink
chore(remix-dev): upgrade cacache to v17 (#7100)
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelDeBoey authored Aug 8, 2023
1 parent c6b70a6 commit e6b4ab7
Show file tree
Hide file tree
Showing 3 changed files with 143 additions and 84 deletions.
14 changes: 4 additions & 10 deletions packages/remix-dev/cache.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,7 @@
import { put, get } from "cacache";

export { put, get };
export const putJson = async (cachePath: string, key: string, data: any) =>
put(cachePath, key, JSON.stringify(data));

export function putJson(cachePath: string, key: string, data: any) {
return put(cachePath, key, JSON.stringify(data));
}

export function getJson(cachePath: string, key: string) {
return get(cachePath, key).then((obj) =>
JSON.parse(obj.data.toString("utf-8"))
);
}
export const getJson = async (cachePath: string, key: string) =>
get(cachePath, key).then((obj) => JSON.parse(obj.data.toString("utf-8")));
3 changes: 2 additions & 1 deletion packages/remix-dev/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"@remix-run/server-runtime": "1.19.2",
"@vanilla-extract/integration": "^6.2.0",
"arg": "^5.0.1",
"cacache": "^15.0.5",
"cacache": "^17.1.3",
"chalk": "^4.1.2",
"chokidar": "^3.5.1",
"dotenv": "^16.0.0",
Expand Down Expand Up @@ -77,6 +77,7 @@
"@types/gunzip-maybe": "^1.4.0",
"@types/jsesc": "^3.0.1",
"@types/lodash.debounce": "^4.0.6",
"@types/node": "^18.17.1",
"@types/node-fetch": "^2.5.7",
"@types/npmcli__package-json": "^2.0.0",
"@types/picomatch": "^2.3.0",
Expand Down
Loading

0 comments on commit e6b4ab7

Please sign in to comment.