Skip to content

Commit 040d4b7

Browse files
author
Alex Patterson
committed
used two methods of copying with two tools
1 parent d9ac9a5 commit 040d4b7

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

package-lock.json

Lines changed: 6 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,10 @@
4242
"analyze": "cross-env BUNDLE_ANALYZE=both next build",
4343
"analyze:server": "cross-env BUNDLE_ANALYZE=server next build",
4444
"analyze:browser": "cross-env BUNDLE_ANALYZE=browser next build",
45-
"build:functions": "npm run build:functions:lint && cpx \"functions/lib/**/*.*\" dist/functions",
45+
"build:functions": "npm run build:functions:lint && cpx \"functions/lib/functions/src/**/*.*\" dist/functions",
4646
"build:functions:lint": "cd functions && npm run lint && npm run build",
4747
"clean": "rimraf dist && rimraf functions/lib && rimraf .next",
48-
"copy:deps": "cpx \"functions/*{package.json,package-lock.json}\" dist/functions && cpx \"functions/node_modules/**/*.*\" dist/functions/node_modules && cpx \".next/serverless/**/*.*\" dist/functions/_next/serverless/ && cpx \".next/static/**/*.*\" dist/public/_next/static/ && cpx \"static/**/*.*\" dist/public/static && cpx \"dist/functions/_next/static/**/*.*\" dist/public/_next/static && cpx \"dist/functions/_next/serverless/pages/*.html\" dist/public",
48+
"copy:deps": "cpx \"functions/*{package.json,package-lock.json}\" dist/functions && ncp functions/node_modules/ dist/functions/node_modules && cpx \".next/serverless/**/*.*\" dist/functions/_next/serverless/ && cpx \".next/static/**/*.*\" dist/public/_next/static/ && cpx \"static/**/*.*\" dist/public/static && cpx \"dist/functions/_next/static/**/*.*\" dist/public/_next/static && cpx \"dist/functions/_next/serverless/pages/*.html\" dist/public",
4949
"firebase:build": "npm install && npm run clean && npm run build && npm run build:functions && npm run copy:deps",
5050
"firebase:serve": "npm run firebase:build && firebase serve",
5151
"firebase:deploy": "npm run firebase:build && firebase deploy"
@@ -54,6 +54,7 @@
5454
"@zeit/next-bundle-analyzer": "^0.1.2",
5555
"cpx": "^1.5.0",
5656
"cross-env": "^5.2.0",
57+
"ncp": "^2.0.0",
5758
"rimraf": "^2.6.3",
5859
"typescript": "^3.5.3"
5960
}

0 commit comments

Comments
 (0)