Skip to content

Commit ea8f1c0

Browse files
committed
zcli project scope & project env
1 parent 738f857 commit ea8f1c0

File tree

1 file changed

+23
-4
lines changed

1 file changed

+23
-4
lines changed

apps/docs/content/references/cli/commands.mdx

Lines changed: 23 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,21 @@ zcli project delete [project-id] [flags]
109109
- `--confirm` - Skip confirmation prompts for destructive operations
110110
- `-P, --project-id string` - Required when you have access to multiple projects
111111

112+
### project env
113+
114+
Displays environment variables for the current project scope.
115+
116+
```sh
117+
zcli project env [flags]
118+
```
119+
120+
**Flags:**
121+
- `--export` - Prepends export keyword to each env in output: 'export {{.Key}}={{.Value}}'
122+
- `-P, --project-id string` - Required when you have access to multiple projects
123+
- `--service string` - Service name, in which context the environment variables are output
124+
- `--template string` - Output template (default: "{{.Key}}={{.Value}}")
125+
- `--user-only` - Exclude all non user env variables
126+
112127
### project project-import
113128

114129
Creates a new project with one or more services from a YAML definition.
@@ -132,16 +147,20 @@ zcli project service-import importYamlPath [flags]
132147
**Flags:**
133148
- `-P, --project-id string` - Required when you have access to multiple projects
134149

135-
### scope project
150+
### project scope
136151

137-
Sets the default project for commands that require a project ID.
152+
Sets or clears the default project scope for commands that require a project ID.
138153

139154
```sh
140-
zcli scope project [project-id]
155+
zcli project scope [project-id] [flags]
141156
```
142157

158+
**Flags:**
159+
- `--clear` - Clear project scope
160+
- `-P, --project-id string` - Required when you have access to multiple projects
161+
143162
:::tip
144-
Instead of using the `scope project` command, you can also set a default project ID in a `.zcli.yml` file or via the `ZEROPS_PROJECTID` environment variable. See the [Configuration](/references/cli/configuration) page for details.
163+
Instead of using the `project scope` command, you can also set a default project ID in a `.zcli.yml` file or via the `ZEROPS_PROJECTID` environment variable. See the [Configuration](/references/cli/configuration) page for details.
145164
:::
146165

147166
### scope reset

0 commit comments

Comments
 (0)