@dotenvx/dotenvx 0.6.6 → 0.6.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "0.6.6",
2
+ "version": "0.6.7",
3
3
  "name": "@dotenvx/dotenvx",
4
4
  "description": "a better dotenv–from the creator of `dotenv`",
5
5
  "author": "@motdotla",
@@ -54,7 +54,7 @@ program
54
54
 
55
55
  // dotenvx run -- node index.js
56
56
  program.command('run')
57
- .description('inject env at runtime (example: `dotenvx run -- your-cmd`)')
57
+ .description('inject env at runtime [dotenvx run -- your-command-here]')
58
58
  .addHelpText('after', examples.run)
59
59
  .option('-f, --env-file <paths...>', 'path(s) to your env file(s)', '.env')
60
60
  .option('-o, --overload', 'override existing env variables')
@@ -159,7 +159,10 @@ program.command('run')
159
159
  // Extract command and arguments after '--'
160
160
  const commandIndex = process.argv.indexOf('--')
161
161
  if (commandIndex === -1 || commandIndex === process.argv.length - 1) {
162
- logger.error('at least one argument is required after the run command, received 0.')
162
+ logger.error('missing command after [dotenvx run --]')
163
+ logger.error('')
164
+ logger.error(' get help: [dotenvx help run]')
165
+ logger.error(' or try: [dotenvx run -- npm run dev]')
163
166
  process.exit(1)
164
167
  } else {
165
168
  const subCommand = process.argv.slice(commandIndex + 1)
@@ -1,14 +1,17 @@
1
1
  const run = function () {
2
2
  return `
3
- Example:
3
+ Examples:
4
4
 
5
- \`\`\`sh
6
- $ dotenvx run -- your-cmd
5
+ \`\`\`
6
+ $ dotenvx run -- npm run dev
7
+ $ dotenvx run -- flask --app index run
8
+ $ dotenvx run -- php artisan serve
9
+ $ dotenvx run -- bin/rails s
7
10
  \`\`\`
8
11
 
9
12
  Try it:
10
13
 
11
- \`\`\`sh
14
+ \`\`\`
12
15
  $ echo "HELLO=World" > .env
13
16
  $ echo "console.log('Hello ' + process.env.HELLO)" > index.js
14
17
 
@@ -21,15 +24,15 @@ Try it:
21
24
 
22
25
  const encrypt = function () {
23
26
  return `
24
- Example:
27
+ Examples:
25
28
 
26
- \`\`\`sh
29
+ \`\`\`
27
30
  $ dotenvx encrypt
28
31
  \`\`\`
29
32
 
30
33
  Try it:
31
34
 
32
- \`\`\`sh
35
+ \`\`\`
33
36
  $ echo "HELLO=World" > .env
34
37
  $ echo "HELLO=production" > .env.production
35
38
  $ echo "console.log('Hello ' + process.env.HELLO)" > index.js