Skip to content

Commit 2466e9b

Browse files
authored
Merge pull request #2 from F88/get-rid-of-environmental-dependencies-in-npm-scripts
Get rid of environmental dependencies in npm scripts
2 parents f32d446 + 7547370 commit 2466e9b

File tree

2 files changed

+288
-13
lines changed

2 files changed

+288
-13
lines changed

package.json

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,12 @@
1010
"start": "cross-env NODE_ENV=production node src/server/index.js",
1111
"generate": "nuxt generate",
1212
"lint": "eslint --ext .js,.vue --ignore-path .gitignore .",
13-
"clean": "if exist dist rd /s /q dist && if exist .nuxt rd /s /q .nuxt",
14-
"install:functions": "cd dist\\server && npm install && cd ..\\..\\",
15-
"copy": "mkdir dist && xcopy functions dist\\server /e /c /h /i /y && xcopy /e /c /h /i /y src\\static dist\\client && xcopy /e /c /h /i /y .nuxt dist\\server\\.nuxt && xcopy /e /c /h /i /y dist\\server\\.nuxt\\dist dist\\client\\assets",
13+
"lintx": "eslint --ext .js,.vue .",
14+
"clean": "rimraf .nuxt dist",
15+
"install:functions": "yarn install --cwd dist/server",
16+
"copy": "yarn copy:client && yarn copy:server",
17+
"copy:server": "cpx -Cv \"functions/**\" dist/server && cpx -v \".nuxt/**\" dist/server/",
18+
"copy:client": "cpx -Cv \"src/static/**\" dist/client/ && cpx -Cv \".nuxt/dist/**\" dist/client/assets/",
1619
"firebase-emulator": "yarn clean && yarn lint && yarn build && yarn copy && yarn install:functions && firebase emulators:start"
1720
},
1821
"lint-staged": {
@@ -51,6 +54,7 @@
5154
"@nuxtjs/stylelint-module": "^3.2.2",
5255
"@nuxtjs/vuetify": "^1.11.2",
5356
"babel-eslint": "^10.1.0",
57+
"cpx": "^1.5.0",
5458
"eslint": "^6.8.0",
5559
"eslint-config-prettier": "^6.11.0",
5660
"eslint-plugin-nuxt": "^0.5.2",
@@ -59,6 +63,7 @@
5963
"lint-staged": "^10.2.2",
6064
"nodemon": "^2.0.3",
6165
"prettier": "^2.0.5",
66+
"rimraf": "^3.0.2",
6267
"sass-loader": "^8.0.2",
6368
"stylelint": "^13.3.3"
6469
}

0 commit comments

Comments
 (0)