@dotenv/cli
Advanced tools
Comparing version 0.5.1 to 0.6.0
@@ -13,2 +13,4 @@ "use strict"; | ||
await new check_latest_version_service_1.CheckLatestVersionService().run(); | ||
// Deprecation notice | ||
console.log('DEPRECATION NOTICE: \'dotenv-cli init\' is deprecated. Going forward, run \'dotenv-cli new\' instead.'); | ||
// 1. create gitignore | ||
@@ -23,5 +25,5 @@ new append_to_gitignore_service_1.AppendToGitignoreService().run(); | ||
exports.default = Init; | ||
Init.description = 'initialize .env.me and .env.project'; | ||
Init.description = 'DEPRECATED: initialize .env.me and .env.project'; | ||
Init.args = [ | ||
{ name: 'organizationSlug' }, | ||
]; |
@@ -6,2 +6,3 @@ "use strict"; | ||
const warn_if_env_project_does_not_exist_service_1 = require("../services/warn-if-env-project-does-not-exist-service"); | ||
const warn_if_env_does_not_exist_service_1 = require("../services/warn-if-env-does-not-exist-service"); | ||
const push_service_1 = require("../services/push-service"); | ||
@@ -15,4 +16,5 @@ const check_latest_version_service_1 = require("../services/check-latest-version-service"); | ||
await new append_to_gitignore_service_1.AppendToGitignoreService().run(); | ||
// 2. check if .env.project file exists | ||
// 2. check if .env.project & .env files exists | ||
await new warn_if_env_project_does_not_exist_service_1.WarnIfEnvProjectDoesNotExistService({ _this: this }).run(); | ||
await new warn_if_env_does_not_exist_service_1.WarnIfEnvDoesNotExistService({ _this: this }).run(); | ||
// 3. push | ||
@@ -19,0 +21,0 @@ await new push_service_1.PushService().run(); |
@@ -14,3 +14,3 @@ "use strict"; | ||
if (!fs.existsSync(projectFile)) { | ||
signale.fatal('Missing .env.project. To create it, run the command: dotenv-cli init'); | ||
signale.fatal('Missing .env.project. To create it, run the command: dotenv-cli new'); | ||
this._this.exit(1); | ||
@@ -17,0 +17,0 @@ } |
@@ -1,1 +0,1 @@ | ||
{"version":"0.5.1","commands":{"init":{"id":"init","description":"initialize .env.me and .env.project","pluginName":"@dotenv/cli","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"organizationSlug"}]},"pull":{"id":"pull","description":"pull .env","pluginName":"@dotenv/cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"push":{"id":"push","description":"push .env","pluginName":"@dotenv/cli","pluginType":"core","aliases":[],"flags":{},"args":[]}}} | ||
{"version":"0.6.0","commands":{"init":{"id":"init","description":"DEPRECATED: initialize .env.me and .env.project","pluginName":"@dotenv/cli","pluginType":"core","aliases":[],"flags":{},"args":[{"name":"organizationSlug"}]},"new":{"id":"new","description":"create .env.project file","pluginName":"@dotenv/cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"pull":{"id":"pull","description":"pull .env","pluginName":"@dotenv/cli","pluginType":"core","aliases":[],"flags":{},"args":[]},"push":{"id":"push","description":"push .env","pluginName":"@dotenv/cli","pluginType":"core","aliases":[],"flags":{},"args":[]}}} |
{ | ||
"name": "@dotenv/cli", | ||
"description": "CLI to interact with dotenv", | ||
"version": "0.5.1", | ||
"version": "0.6.0", | ||
"author": "motdotla @motdotla", | ||
@@ -6,0 +6,0 @@ "bin": { |
@@ -28,17 +28,13 @@ # @dotenv/cli | ||
In your terminal (and in your project folder), initialize dotenv the same way you | ||
initialize git. | ||
In your terminal (and in your project folder), create a new .env.project file. | ||
```bash | ||
dotenv-cli init | ||
dotenv-cli new | ||
``` | ||
This will create (if not existing) a | ||
This will ask you to visit Dotenv to create your project. Follow that for | ||
instructions on setting your `.env.project` file. | ||
* `.env` file | ||
* `.env.me` file | ||
* `.env.project` file | ||
Then make changes to your `.env` file and when you do, run: | ||
Make changes to your `.env` file and when you do, run: | ||
```bash | ||
@@ -45,0 +41,0 @@ dotenv-cli push |
37735
41
1016
87
9