Skip to content

Commit af7a2e6

Browse files
committed
add switch command
1 parent 7a34c11 commit af7a2e6

File tree

2 files changed

+56
-8
lines changed

2 files changed

+56
-8
lines changed

docs/cli-switch.mdx

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
---
2+
title: "CLI switch command"
3+
sidebarTitle: "switch"
4+
description: "The `trigger.dev switch` command can be used to switch between profiles."
5+
tag: "v4"
6+
---
7+
8+
import UpgradeToV4Note from "/snippets/upgrade-to-v4-note.mdx";
9+
import ProjectPathArg from "/snippets/cli-args-project-path.mdx";
10+
import CommonOptions from "/snippets/cli-options-common.mdx";
11+
import ProjectRefOption from "/snippets/cli-options-project-ref.mdx";
12+
import EnvFileOption from "/snippets/cli-options-env-file.mdx";
13+
import ConfigFileOption from "/snippets/cli-options-config-file.mdx";
14+
import SkipUpdateCheckOption from "/snippets/cli-options-skip-update-check.mdx";
15+
import BranchOption from "/snippets/cli-options-branch.mdx";
16+
17+
<UpgradeToV4Note />
18+
19+
Run the command like this:
20+
21+
<CodeGroup>
22+
23+
```bash npm
24+
npx trigger.dev@v4-beta switch [profile]
25+
```
26+
27+
```bash pnpm
28+
pnpm dlx trigger.dev@v4-beta switch [profile]
29+
```
30+
31+
```bash yarn
32+
yarn dlx trigger.dev@v4-beta switch [profile]
33+
```
34+
35+
</CodeGroup>
36+
37+
It will switch to the specified profile. If no profile is specified, it will list all available profiles and run interactively.
38+
39+
## Arguments
40+
41+
```
42+
npx trigger.dev@v4-beta switch [profile]
43+
```
44+
45+
<ParamField body="Profile" type="[profile]">
46+
The profile to switch to. If not specified, it will list all available profiles and run interactively.
47+
</ParamField>

docs/docs.json

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -140,16 +140,17 @@
140140
{
141141
"group": "Commands",
142142
"pages": [
143-
"cli-login-commands",
144-
"cli-init-commands",
145-
"cli-dev-commands",
146143
"cli-deploy-commands",
147-
"cli-promote-commands",
148-
"cli-preview-archive",
149-
"cli-whoami-commands",
150-
"cli-logout-commands",
144+
"cli-dev-commands",
145+
"cli-init-commands",
151146
"cli-list-profiles-commands",
152-
"cli-update-commands"
147+
"cli-login-commands",
148+
"cli-logout-commands",
149+
"cli-preview-archive",
150+
"cli-promote-commands",
151+
"cli-switch",
152+
"cli-update-commands",
153+
"cli-whoami-commands"
153154
]
154155
}
155156
]

0 commit comments

Comments
 (0)