Skip to content

Commit

Permalink
feat: add EGG_FRAMEWORK for bootstrap custom framework (#131)
Browse files Browse the repository at this point in the history
  • Loading branch information
killagu authored Nov 8, 2022
1 parent a2cc714 commit 209c921
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -455,6 +455,10 @@ describe('test app', () => {
});
```

### env for custom bootstrap
EGG_BASE_DIR: the base dir of egg app
EGG_FRAMEWORK: the framework of egg app

## Questions & Suggestions

Please open an issue [here](https://github.com/eggjs/egg/issues).
Expand Down
3 changes: 3 additions & 0 deletions lib/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ module.exports = {
} else {
options.baseDir = process.cwd();
}
if (process.env.EGG_FRAMEWORK) {
options.framework = process.env.EGG_FRAMEWORK;
}
return options;
},
};

0 comments on commit 209c921

Please sign in to comment.