Skip to content
This repository was archived by the owner on Jan 2, 2022. It is now read-only.

Commit f54d11b

Browse files
committed
2 parents d27524d + baaabf2 commit f54d11b

File tree

4 files changed

+12
-12
lines changed

4 files changed

+12
-12
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ jobs:
4747
- name: Install dependencies with Yarn
4848
run: yarn install
4949
- name: Lint with XO
50-
run: yarn run xo
50+
run: yarn run lint
5151
style:
5252
name: Check style
5353

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"url": "https://github.com/pizzafox/netlify-cache-nextjs/issues"
99
},
1010
"dependencies": {
11-
"@netlify/cache-utils": "^0.2.4"
11+
"@netlify/cache-utils": "^0.2.8"
1212
},
1313
"devDependencies": {
1414
"prettier": "^1.19.1",
@@ -17,7 +17,7 @@
1717
"xo": "^0.28.1"
1818
},
1919
"engines": {
20-
"node": "12"
20+
"node": ">=8.3.0"
2121
},
2222
"keywords": [
2323
"netlify",

src/index.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,11 @@ interface NetlifyUtils {
88
}
99

1010
interface NetlifyInputs {
11+
// The TOML config uses camelcase for readability and because it's convention
12+
/* eslint-disable camelcase */
1113
custom_build_dir_name?: string;
1214
build_dir_path?: string;
15+
/* eslint-enable camelcase */
1316
}
1417

1518
interface NetlifyOpts {
@@ -58,9 +61,7 @@ module.exports = {
5861
// - the file/directory has not been cached yet
5962
async onPreBuild({utils, netlifyConfig, inputs}: NetlifyOpts) {
6063
const paths = generateAbsolutePaths({netlifyConfig, inputs});
61-
const success = await utils.cache.restore(paths.absolute.buildDir, {
62-
digest: [paths.absolute.manifest]
63-
});
64+
const success = await utils.cache.restore(paths.absolute.buildDir);
6465

6566
if (success) {
6667
console.log(`Restored the cached ${paths.buildDirName} folder at the location \`${paths.absolute.buildDir}\``);

yarn.lock

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,19 +42,18 @@
4242
call-me-maybe "^1.0.1"
4343
glob-to-regexp "^0.3.0"
4444

45-
"@netlify/cache-utils@^0.2.4":
46-
version "0.2.4"
47-
resolved "https://registry.yarnpkg.com/@netlify/cache-utils/-/cache-utils-0.2.4.tgz#78325ccf4446c5ba341516789ee72920e68b7b85"
48-
integrity sha512-qySES6dAxYHxj90gKvHKJ+dX7SdtcjsYPTQopgp2kcW7CdNxoPZsTM3lpTr2JSvz6jzo/tUGv9jexk14MALDNw==
45+
"@netlify/cache-utils@^0.2.8":
46+
version "0.2.8"
47+
resolved "https://registry.yarnpkg.com/@netlify/cache-utils/-/cache-utils-0.2.8.tgz#c7ba3389853ea6611530b1361095858711290eee"
48+
integrity sha512-gH04KLAnAs3HR/AGojWjFfvHbSSmypRZ7K7ca1r19agobjcH+IWrYLxHDcd1HtnvIpitWAYlT4YYGOajr1ywKg==
4949
dependencies:
5050
array-flat-polyfill "^1.0.1"
5151
cpy "^8.0.0"
5252
del "^5.1.0"
5353
get-stream "^5.1.0"
5454
global-cache-dir "^1.0.1"
55-
junk "^3.1.0"
55+
locate-path "^5.0.0"
5656
move-file "^1.2.0"
57-
p-map "^3.0.0"
5857
path-exists "^4.0.0"
5958
readdirp "^3.4.0"
6059

0 commit comments

Comments
 (0)