Skip to content

Commit

Permalink
Change NODE_ENV value to full version
Browse files Browse the repository at this point in the history
Many libraries have optimizations built in when the NODE_ENV
environment variable is set to production.
  • Loading branch information
khshourov committed Nov 2, 2024
1 parent 2754d06 commit 5b17805
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 12 deletions.
8 changes: 4 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,10 @@ lerna-debug.log*
.env.test.local
.env.production.local
.env.local
.env.dev
.env.test
.env.prod
!test/resources/.env.test
.env.development
.env.testing
.env.production
!test/resources/.env.testing
# temp directory
.temp
.tmp
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
"format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"",
"check-format": "prettier --check \"src/**/*.ts\" \"test/**/*.ts\"",
"start": "nest start",
"start:dev": "NODE_ENV=dev nest start --watch",
"start:debug": "NODE_ENV=dev nest start --debug --watch",
"start:prod": "NODE_ENV=prod node dist/main",
"start:dev": "NODE_ENV=development nest start --watch",
"start:debug": "NODE_ENV=development nest start --debug --watch",
"start:prod": "NODE_ENV=production node dist/main",
"lint": "eslint \"{src,apps,libs,test}/**/*.ts\" --fix",
"test": "jest",
"test:watch": "jest --watch",
Expand Down
8 changes: 4 additions & 4 deletions scripts/run-e2e
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
MARKER="\033[32m#\033[0m"

# Define paths
ROOT_ENV=".env.test"
TEST_ENV="test/resources/.env.test"
BACKUP_ENV=".env.test.backup"
ROOT_ENV=".env.testing"
TEST_ENV="test/resources/.env.testing"
BACKUP_ENV=".env.testing.backup"
POSTGRES_COMPOSE_FILE="test/resources/postgresql.yml"

get_env_var() {
Expand Down Expand Up @@ -75,7 +75,7 @@ done
linebreak

title "Run migration and the NestJS e2e tests"
export NODE_ENV="test"
export NODE_ENV="testing"
yarn run migration:run && yarn run jest --config ./test/jest-e2e.json
linebreak

Expand Down
2 changes: 1 addition & 1 deletion test/resources/.env.test → test/resources/.env.testing
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
App configuration
# App configuration
PORT=3000

# Rate Limit
Expand Down

0 comments on commit 5b17805

Please sign in to comment.