Skip to content

Commit

Permalink
Merge pull request #458 from HubSpot/feature/createDotEnv
Browse files Browse the repository at this point in the history
copy .env.template to .env if it exists
  • Loading branch information
ksvirkou-hubspot authored Apr 6, 2021
2 parents 3eb77a3 + f2a6a7e commit 1df31de
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/cli/commands/create.js
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,9 @@ exports.handler = async options => {
}
);
if (created) {
if (fs.existsSync(`${filePath}/.env.template`)) {
fs.copySync(`${filePath}/.env.template`, `${filePath}/.env`);
}
logger.success(
`Please, follow ${filePath}/README.md to find out how to run the sample`
);
Expand Down

0 comments on commit 1df31de

Please sign in to comment.