Skip to content

Commit 3551b63

Browse files
authored
Revert "Revert "Add CLI Reference for now env"" (#1752)
1 parent e827d48 commit 3551b63

File tree

2 files changed

+59
-0
lines changed

2 files changed

+59
-0
lines changed

components/references-mdx/now-cli/commands/commands.mdx

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import Certs from './certs.mdx'
66
import Dev from './dev.mdx'
77
import DNS from './dns.mdx'
88
import Domains from './domains.mdx'
9+
import Env from './env.mdx'
910
import Help from './help.mdx'
1011
import Init from './init.mdx'
1112
import Inspect from './inspect.mdx'
@@ -32,6 +33,7 @@ export const meta = {
3233
<Login />
3334
<Logout />
3435
<Init />
36+
<Env />
3537
<Secrets />
3638
<Switch />
3739
<Help />
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
import Snippet from '~/components/snippet'
2+
import Caption from '~/components/text/caption'
3+
import { InlineCode } from '~/components/text/code'
4+
import Note from '~/components/text/note'
5+
import Link from '~/components/text/link'
6+
7+
export const meta = {
8+
editUrl: 'pages/docs/now-cli/now-cli-mdx/commands/env.mdx',
9+
lastEdited: '2020-04-13T22:03:42.000Z'
10+
}
11+
12+
## Env
13+
14+
The `now env` command is used to manage Environment Variables under a Project, providing functionality to list, add, remove, and pull.
15+
16+
### Basic Usage
17+
18+
<Snippet dark text="now env ls" />
19+
<Caption>Using the <InlineCode>now env</InlineCode> command to list all Environment Variables under a Project.</Caption>
20+
21+
<Snippet dark text="now env add" />
22+
<Caption>Using the <InlineCode>now env</InlineCode> command to add an Environment Variable to a Project.</Caption>
23+
24+
<Snippet dark text="now env rm" />
25+
<Caption>Using the <InlineCode>now env</InlineCode> command to remove an Environment Variable from a Project.</Caption>
26+
27+
<Snippet dark text="now env pull" />
28+
<Caption>Using the <InlineCode>now env</InlineCode> command to download Development Environment Variables from the cloud and write to the <InlineCode>.env</InlineCode> file.</Caption>
29+
30+
### Extended Usage
31+
32+
<Snippet dark text="now env ls [environment]" />
33+
<Caption>Using the <InlineCode>now env</InlineCode> command to list Environment Variables for a specific Environment under a Project.</Caption>
34+
35+
<Snippet dark text="now env add [name] [environment]" />
36+
<Caption>Using the <InlineCode>now env</InlineCode> command to add an Environment Variable to a Project.</Caption>
37+
38+
<Snippet dark text="now env add [name] [environment] < [file]" />
39+
<Caption>Using the <InlineCode>now env</InlineCode> command to add an Environment Variable to a Project using a local file as the value.</Caption>
40+
41+
<Snippet dark text="now env rm [name] [environment]" />
42+
<Caption>Using the <InlineCode>now env</InlineCode> command to remove an Environment Variable from a Project.</Caption>
43+
44+
<Snippet dark text="now env pull [file]" />
45+
<Caption>Using the <InlineCode>now env</InlineCode> command to download Development Environment Variables from the cloud and write to a specific file.</Caption>
46+
47+
### Global Options
48+
49+
The following [global options](#options) can be passed when using the `now env` command:
50+
51+
- `--debug`
52+
- `--global-config`
53+
- `--help`
54+
- `--local-config`
55+
- `--token`
56+
57+
For more information on global options and their usage, refer to the [options section](#options).

0 commit comments

Comments
 (0)