sealos-cli 1.1.1 → 1.1.2
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/README.md +7 -3
- package/dist/bin/cli.cjs +1219 -982
- package/dist/bin/cli.mjs +1217 -980
- package/dist/main.cjs +1219 -982
- package/dist/main.mjs +1217 -980
- package/package.json +1 -1
- package/src/commands/auth/index.ts +2 -2
- package/src/commands/auth/login.ts +1 -1
- package/src/commands/auth/logout.ts +21 -2
- package/src/commands/auth/whoami.ts +1 -1
- package/src/commands/database/index.ts +142 -18
- package/src/commands/devbox/index.ts +108 -24
- package/src/commands/template/index.ts +28 -3
- package/src/commands/workspace/index.ts +3 -3
- package/src/lib/auth.ts +17 -1
package/README.md
CHANGED
|
@@ -49,7 +49,9 @@ src/
|
|
|
49
49
|
|
|
50
50
|
### Output Formatting (`lib/output.ts`)
|
|
51
51
|
|
|
52
|
-
- JSON
|
|
52
|
+
- JSON is the default output for registered commands so agents and scripts can parse results reliably
|
|
53
|
+
- Table output is available with `-o table` / `--output table` for human inspection
|
|
54
|
+
- Plain text output is available only where explicitly documented, such as database logs with `-o plain`
|
|
53
55
|
- Colored terminal output using chalk
|
|
54
56
|
- Loading spinners using ora
|
|
55
57
|
- Table formatting using table
|
|
@@ -142,7 +144,7 @@ sealos-cli devbox create --name my-devbox --runtime next.js --cpu 2c --memory 4g
|
|
|
142
144
|
|
|
143
145
|
# List devboxes
|
|
144
146
|
sealos-cli devbox list
|
|
145
|
-
sealos-cli devbox list --output
|
|
147
|
+
sealos-cli devbox list --output table
|
|
146
148
|
|
|
147
149
|
# Get devbox details
|
|
148
150
|
sealos-cli devbox get my-devbox
|
|
@@ -204,6 +206,7 @@ sealos-cli database enable-public my-db
|
|
|
204
206
|
sealos-cli database disable-public my-db
|
|
205
207
|
sealos-cli database log-files <pod-name> --db-type postgresql --log-type runtimeLog
|
|
206
208
|
sealos-cli database logs <pod-name> --db-type postgresql --log-type runtimeLog --log-path /path/to/log
|
|
209
|
+
sealos-cli database logs <pod-name> --db-type postgresql --log-type runtimeLog --log-path /path/to/log -o plain
|
|
207
210
|
```
|
|
208
211
|
|
|
209
212
|
Implementation: `src/commands/database/index.ts`
|
|
@@ -225,7 +228,8 @@ The v1 command surface is limited to auth, workspace, template, database, and de
|
|
|
225
228
|
- TypeScript for type safety
|
|
226
229
|
- Shared utilities for common operations
|
|
227
230
|
- Consistent error handling
|
|
228
|
-
- JSON and
|
|
231
|
+
- JSON output by default for agent and automation use
|
|
232
|
+
- Optional table output with `-o table`
|
|
229
233
|
- Environment variable support
|
|
230
234
|
- Loading indicators for async operations
|
|
231
235
|
- Color-coded terminal output
|