diff --git a/package.json b/package.json index df2fdab..807c64f 100644 --- a/package.json +++ b/package.json @@ -4,13 +4,17 @@ "description": "server code for mentor labs", "main": "server/server.ts", "license": "MIT", + "engines": { + "node": "14.17.1", + "yarn": "1.22.10" + }, "scripts": { "start": "cross-env NODE_ENV=production node prod/server.js", "dev": "concurrently \"yarn server:dev\" \"yarn client:dev\"", "client:dev": "cd client && yarn start", "server:dev": "cross-env NODE_ENV=development nodemon server/main.ts", "server:build": "tsc -p tsconfig.prod.json", - "client:build": "yarn --prefix ./client run build && yarn run client:move-build", + "client:build": "yarn --cwd ./client build && yarn client:move-build", "client:move-build": "ts-node utils/move-from-to.ts client/build prod/client", "lint": "eslint server/**/*.ts", "lint:fix": "eslint server/**/*.ts --fix", @@ -22,7 +26,7 @@ "prepare": "husky install", "pre-commit": "lint-staged", "heroku-prebuild": "cd client && yarn install --dev", - "heroku-postbuild": "NPM_CONFIG_PRODUCTION=false yarn run server:build && yarn run client:install && yarn run client:build" + "heroku-postbuild": "NPM_CONFIG_PRODUCTION=false yarn server:build && yarn client:install && yarn run client:build" }, "devDependencies": { "@commitlint/cli": "^12.1.4", @@ -31,6 +35,7 @@ "@types/cookie-parser": "^1.4.2", "@types/cors": "^2.8.10", "@types/express": "^4.17.12", + "@types/fs-extra": "^9.0.13", "@types/gravatar": "^1.8.2", "@types/jest": "^27.0.2", "@types/jsonwebtoken": "^8.5.1", @@ -58,6 +63,7 @@ "danfojs-node": "^0.3.3", "dotenv": "^10.0.0", "express": "^4.17.1", + "fs-extra": "^10.0.0", "gravatar": "^1.8.1", "helmet": "^4.6.0", "history": "^5.0.1", diff --git a/tsconfig.json b/tsconfig.json index d8dedf3..9b8062e 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -25,5 +25,5 @@ "typeRoots": ["server/common/types", "./node_modules/@types"] }, "include": ["server/**/*.ts"], - "exclude": ["node_modules", "client"] + "exclude": ["node_modules", "client", "./utils"] } diff --git a/yarn.lock b/yarn.lock index ed3fa6e..202eade 100644 --- a/yarn.lock +++ b/yarn.lock @@ -958,6 +958,13 @@ "@types/qs" "*" "@types/serve-static" "*" +"@types/fs-extra@^9.0.13": + version "9.0.13" + resolved "https://registry.yarnpkg.com/@types/fs-extra/-/fs-extra-9.0.13.tgz#7594fbae04fe7f1918ce8b3d213f74ff44ac1f45" + integrity sha512-nEnwB++1u5lVDM2UI4c1+5R+FYaKfaAzS4OococimjVm3nQw3TuzH5UNsocrcTBbhnerblyHj4A49qXbIiZdpA== + dependencies: + "@types/node" "*" + "@types/graceful-fs@^4.1.2": version "4.1.5" resolved "https://registry.yarnpkg.com/@types/graceful-fs/-/graceful-fs-4.1.5.tgz#21ffba0d98da4350db64891f92a9e5db3cdb4e15" @@ -2921,6 +2928,15 @@ fresh@0.5.2: resolved "https://registry.yarnpkg.com/fresh/-/fresh-0.5.2.tgz#3d8cadd90d976569fa835ab1f8e4b23a105605a7" integrity sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac= +fs-extra@^10.0.0: + version "10.0.0" + resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-10.0.0.tgz#9ff61b655dde53fb34a82df84bb214ce802e17c1" + integrity sha512-C5owb14u9eJwizKGdchcDUQeFtlSHHthBk8pbX9Vc1PFZrLombudjDnNns88aYslCyF6IY5SUw3Roz6xShcEIQ== + dependencies: + graceful-fs "^4.2.0" + jsonfile "^6.0.1" + universalify "^2.0.0" + fs-extra@^9.0.0: version "9.1.0" resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-9.1.0.tgz#5954460c764a8da2094ba3554bf839e6b9a7c86d"