-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(package.json): refactor scripts
- Loading branch information
1 parent
a3a2cb9
commit 358c9b0
Showing
10 changed files
with
44 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,6 @@ | ||
:: 启动开发版 | ||
|
||
set PORT=8080 | ||
:: 数据库密码 | ||
set MARIADBPWD=xxxx | ||
npm run dev | ||
npm run start:dev |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# 启动正式版 | ||
|
||
# MARIADBPWD: 数据库密码 | ||
PORT=8080 MARIADBPWD=xxx npm run prod |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# 启动测试版 | ||
|
||
# MARIADBPWD: 数据库密码 | ||
PORT=8080 MARIADBPWD=xxx npm run start:test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
set PORT=8080 | ||
:: 运行测试用例 | ||
|
||
:: 数据库密码 | ||
set MARIADBPWD=xxxx | ||
npm run test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/app/config/dev-server.config.ts → src/app/config/test.config.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,12 @@ | ||
/** | ||
* 整个项目的入口变量 | ||
*/ | ||
export const MARIADBPWD: string = process.env.MARIADBPWD; // 数据库密码 | ||
|
||
// 开发环境: development || testing || production, 默认 development | ||
export const NODE_ENV: string = process.env.NODE_ENV; | ||
|
||
// 数据库密码 | ||
|
||
export const MARIADBPWD: string = process.env.MARIADBPWD; | ||
// 启动端口号,默认 8080 | ||
export const PORT: string = process.env.PORT || '8080'; |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters