Skip to content
This repository was archived by the owner on May 10, 2021. It is now read-only.

Commit 993c1a6

Browse files
committed
Cypress tests: Create .git dir prior to deploy to Netlify
This is a workaround to netlify-cli's new way to resolve the project directory. By creating an empty .git folder in the build directory, netlify-cli deploys files relative to that directory (rather than project root). See: netlify/cli#953 (comment)
1 parent 9b790ce commit 993c1a6

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

cypress/fixtures/package.json

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
"build": "../../../node_modules/.bin/next build",
55
"postbuild": "node ../../../next-on-netlify",
66
"preview": "../../../node_modules/.bin/netlify dev",
7+
"predeploy": "mkdir -p .git",
78
"deploy": "../../../node_modules/.bin/netlify deploy --json > deployment.json"
89
}
910
}

0 commit comments

Comments
 (0)