Skip to content

Commit

Permalink
feat: setup yarn workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
adarshaacharya committed Oct 22, 2021
1 parent 64f6d76 commit b43a876
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 3 deletions.
10 changes: 8 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -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",
Expand All @@ -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",
Expand All @@ -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",
Expand Down Expand Up @@ -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",
Expand Down
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,5 @@
"typeRoots": ["server/common/types", "./node_modules/@types"]
},
"include": ["server/**/*.ts"],
"exclude": ["node_modules", "client"]
"exclude": ["node_modules", "client", "./utils"]
}
16 changes: 16 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down Expand Up @@ -2921,6 +2928,15 @@ [email protected]:
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"
Expand Down

0 comments on commit b43a876

Please sign in to comment.