@xano/cli 1.0.2-beta.2 → 1.0.2-beta.4

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.
Files changed (34) hide show
  1. package/README.md +9 -0
  2. package/dist/commands/auth/index.js +4 -1
  3. package/dist/commands/branch/delete/index.js +1 -1
  4. package/dist/commands/branch/set_live/index.js +2 -2
  5. package/dist/commands/profile/delete/index.js +2 -2
  6. package/dist/commands/release/delete/index.js +1 -1
  7. package/dist/commands/release/deploy/index.js +3 -3
  8. package/dist/commands/release/import/index.js +1 -1
  9. package/dist/commands/release/push/index.js +1 -1
  10. package/dist/commands/sandbox/delete/index.js +2 -2
  11. package/dist/commands/sandbox/env/delete/index.js +1 -1
  12. package/dist/commands/sandbox/env/set_all/index.js +1 -1
  13. package/dist/commands/sandbox/license/set/index.js +1 -1
  14. package/dist/commands/sandbox/push/index.js +3 -3
  15. package/dist/commands/sandbox/reset/index.js +2 -2
  16. package/dist/commands/tenant/backup/delete/index.js +2 -2
  17. package/dist/commands/tenant/backup/restore/index.js +2 -2
  18. package/dist/commands/tenant/cluster/delete/index.js +2 -2
  19. package/dist/commands/tenant/cluster/license/set/index.js +1 -1
  20. package/dist/commands/tenant/create/index.js +1 -1
  21. package/dist/commands/tenant/delete/index.js +1 -1
  22. package/dist/commands/tenant/deploy_platform/index.js +1 -1
  23. package/dist/commands/tenant/deploy_release/index.js +1 -1
  24. package/dist/commands/tenant/edit/index.js +3 -3
  25. package/dist/commands/tenant/env/delete/index.js +1 -1
  26. package/dist/commands/tenant/env/set_all/index.js +1 -1
  27. package/dist/commands/tenant/license/set/index.js +1 -1
  28. package/dist/commands/tenant/push/index.js +1 -1
  29. package/dist/commands/workflow_test/delete/index.js +1 -1
  30. package/dist/commands/workspace/delete/index.js +1 -1
  31. package/dist/commands/workspace/edit/index.js +1 -1
  32. package/dist/commands/workspace/push/index.js +6 -6
  33. package/oclif.manifest.json +2209 -2209
  34. package/package.json +1 -1
package/README.md CHANGED
@@ -30,6 +30,15 @@ npm install -g @xano/cli
30
30
 
31
31
  ## Commands
32
32
 
33
+ ### Safety warnings in command help
34
+
35
+ Destructive commands include imperative safety prefixes in their help text and flag descriptions so automated agents (e.g. Claude Code, Cursor) pause before running them in auto-accept mode:
36
+
37
+ - **`[CRITICAL]`** — Agents must STOP and confirm with the user before running. Used for irreversible or high-blast-radius operations, including (but not limited to) `--force` deletions, `workspace edit --allow-push`, `workspace push --records`, `workspace/sandbox push --truncate`, `--no-transaction`, `--sync --delete`, backup restore/delete, cluster delete, `env set_all`, `sandbox reset`, `sandbox delete`, `profile delete`, and tenant deploys.
38
+ - **`[IMPORTANT]`** — Agents should confirm with the user (and prefer `--dry-run` previews where applicable). Used for base `workspace push` and `sandbox push`, `branch set_live`, `release import`, `release push`, `release deploy`, and single-variable env / workflow-test deletes.
39
+
40
+ These warnings are layer 1 of broader push-safety work; ephemeral sandbox environments and push preview remain the structural safeguards.
41
+
33
42
  ### Authentication
34
43
 
35
44
  ```bash
@@ -138,7 +138,10 @@ Opening browser for Xano login at https://custom.xano.com...`,
138
138
  }
139
139
  const data = (await response.json());
140
140
  if (Array.isArray(data)) {
141
- return data.map((br) => ({
141
+ return data
142
+ .filter((br) => !br.backup)
143
+ .map((br) => ({
144
+ backup: br.backup,
142
145
  id: br.id || br.label,
143
146
  label: br.label,
144
147
  }));
@@ -30,7 +30,7 @@ Deleted branch: dev
30
30
  force: Flags.boolean({
31
31
  char: 'f',
32
32
  default: false,
33
- description: 'Skip confirmation prompt',
33
+ description: '[CRITICAL] NEVER run without explicit user confirmation. Skips the confirmation prompt.',
34
34
  required: false,
35
35
  }),
36
36
  output: Flags.string({
@@ -9,7 +9,7 @@ export default class BranchSetLive extends BaseCommand {
9
9
  required: true,
10
10
  }),
11
11
  };
12
- static description = 'Set a branch as the live (active) branch for API requests';
12
+ static description = '[IMPORTANT] ALWAYS confirm with the user before changing the live branch. Sets a branch as the live (active) branch for API requests.';
13
13
  static examples = [
14
14
  `$ xano branch set-live staging
15
15
  Are you sure you want to set 'staging' as the live branch? (y/N) y
@@ -32,7 +32,7 @@ Branch 'v1' is now live
32
32
  force: Flags.boolean({
33
33
  char: 'f',
34
34
  default: false,
35
- description: 'Skip confirmation prompt',
35
+ description: '[IMPORTANT] NEVER run without explicit user confirmation. Skips the confirmation prompt.',
36
36
  required: false,
37
37
  }),
38
38
  output: Flags.string({
@@ -9,7 +9,7 @@ export default class ProfileDelete extends Command {
9
9
  required: true,
10
10
  }),
11
11
  };
12
- static description = 'Delete a profile configuration';
12
+ static description = '[CRITICAL] NEVER run without explicit user confirmation; this removes saved credentials from the local config. Deletes a profile configuration.';
13
13
  static examples = [
14
14
  `$ xano profile:delete old-profile
15
15
  Are you sure you want to delete profile 'old-profile'? (y/n): y
@@ -32,7 +32,7 @@ Profile 'old-profile' deleted successfully from ~/.xano/credentials.yaml
32
32
  force: Flags.boolean({
33
33
  char: 'f',
34
34
  default: false,
35
- description: 'Skip confirmation prompt',
35
+ description: '[CRITICAL] NEVER run without explicit user confirmation. Skips the confirmation prompt.',
36
36
  required: false,
37
37
  }),
38
38
  };
@@ -25,7 +25,7 @@ Deleted release 'v1.0'
25
25
  force: Flags.boolean({
26
26
  char: 'f',
27
27
  default: false,
28
- description: 'Skip confirmation prompt',
28
+ description: '[CRITICAL] NEVER run without explicit user confirmation. Skips the confirmation prompt.',
29
29
  required: false,
30
30
  }),
31
31
  output: Flags.string({
@@ -7,7 +7,7 @@ export default class ReleaseDeploy extends BaseCommand {
7
7
  required: true,
8
8
  }),
9
9
  };
10
- static description = 'Deploy a release to its workspace as a new branch';
10
+ static description = '[IMPORTANT] ALWAYS confirm with the user before deploying a release. Deploys a release to its workspace as a new branch.';
11
11
  static examples = [
12
12
  `$ xano release deploy "v1.0"
13
13
  Are you sure you want to deploy release "v1.0"? (y/N) y
@@ -29,7 +29,7 @@ Deployed release "v1.0" to workspace 40 (branch: v1.0)
29
29
  force: Flags.boolean({
30
30
  char: 'f',
31
31
  default: false,
32
- description: 'Skip confirmation prompt',
32
+ description: '[IMPORTANT] NEVER run without explicit user confirmation. Skips the confirmation prompt.',
33
33
  required: false,
34
34
  }),
35
35
  output: Flags.string({
@@ -41,7 +41,7 @@ Deployed release "v1.0" to workspace 40 (branch: v1.0)
41
41
  }),
42
42
  set_live: Flags.boolean({
43
43
  default: false,
44
- description: 'Set the new branch as live',
44
+ description: '[CRITICAL] STOP and confirm with the user before setting the deployed branch as live.',
45
45
  required: false,
46
46
  }),
47
47
  workspace: Flags.string({
@@ -5,7 +5,7 @@ import * as yaml from 'js-yaml';
5
5
  import BaseCommand from '../../../base-command.js';
6
6
  export default class ReleaseImport extends BaseCommand {
7
7
  static args = {};
8
- static description = 'Import a release file into a workspace';
8
+ static description = '[IMPORTANT] ALWAYS confirm with the user before importing a release. Imports a release file into a workspace.';
9
9
  static examples = [
10
10
  `$ xano release import --file ./my-release.tar.gz
11
11
  Imported release as #15
@@ -5,7 +5,7 @@ import * as path from 'node:path';
5
5
  import BaseCommand from '../../../base-command.js';
6
6
  import { findFilesWithGuid } from '../../../utils/document-parser.js';
7
7
  export default class ReleasePush extends BaseCommand {
8
- static description = 'Create a new release from local XanoScript files via the multidoc endpoint';
8
+ static description = '[IMPORTANT] ALWAYS confirm with the user before creating a release from local files. Creates a new release from local XanoScript files via the multidoc endpoint.';
9
9
  static examples = [
10
10
  `$ xano release push -n "v1.0"
11
11
  Created release: v1.0 - ID: 10 (from current directory)
@@ -1,7 +1,7 @@
1
1
  import { Flags } from '@oclif/core';
2
2
  import BaseCommand from '../../../base-command.js';
3
3
  export default class SandboxDelete extends BaseCommand {
4
- static description = 'Delete your sandbox environment completely (debugging only — it will be re-created on next access)';
4
+ static description = '[CRITICAL] NEVER run without explicit user confirmation; this destroys all sandbox data. Deletes your sandbox environment completely (debugging only — it will be re-created on next access).';
5
5
  static examples = [
6
6
  `$ xano sandbox delete
7
7
  Are you sure you want to DELETE your sandbox environment? This destroys all data. (y/N) y
@@ -14,7 +14,7 @@ Sandbox environment deleted.
14
14
  force: Flags.boolean({
15
15
  char: 'f',
16
16
  default: false,
17
- description: 'Skip confirmation prompt',
17
+ description: '[CRITICAL] Skips the confirmation prompt.',
18
18
  required: false,
19
19
  }),
20
20
  };
@@ -15,7 +15,7 @@ Environment variable 'DATABASE_URL' deleted
15
15
  force: Flags.boolean({
16
16
  char: 'f',
17
17
  default: false,
18
- description: 'Skip confirmation prompt',
18
+ description: '[IMPORTANT] NEVER run without explicit user confirmation. Skips the confirmation prompt.',
19
19
  required: false,
20
20
  }),
21
21
  name: Flags.string({
@@ -4,7 +4,7 @@ import * as fs from 'node:fs';
4
4
  import * as path from 'node:path';
5
5
  import BaseCommand from '../../../../base-command.js';
6
6
  export default class SandboxEnvSetAll extends BaseCommand {
7
- static description = 'Set all environment variables for a sandbox environment from a YAML file (replaces all existing)';
7
+ static description = '[CRITICAL] STOP and confirm with the user; this replaces all environment variables with the imported file. Sets all environment variables for a sandbox environment from a YAML file.';
8
8
  static examples = [
9
9
  `$ xano sandbox env set_all
10
10
  Reads from env_<tenant>.yaml
@@ -16,7 +16,7 @@ Reads from license_<tenant>.yaml
16
16
  ...BaseCommand.baseFlags,
17
17
  clean: Flags.boolean({
18
18
  default: false,
19
- description: 'Remove the source file after successful upload',
19
+ description: '[IMPORTANT] ALWAYS confirm with the user before deleting the source license file after upload. Removes the source file after successful upload.',
20
20
  exclusive: ['value'],
21
21
  required: false,
22
22
  }),
@@ -5,7 +5,7 @@ import open from 'open';
5
5
  import BaseCommand from '../../../base-command.js';
6
6
  import { executePush } from '../../../utils/multidoc-push.js';
7
7
  export default class SandboxPush extends BaseCommand {
8
- static description = 'Push local documents to your sandbox environment via multidoc import. By default, only changed files are pushed (partial mode). Use --sync to push all files. Shows a preview of changes before pushing unless --force is specified. Use --dry-run to preview only. Include/exclude glob filters are intentionally not supported on sandbox push — partial pushes can hide deletions during review and lead to data loss when promoted to the workspace. Large pushes against a sandbox loaded with a different workspace will prompt for confirmation; run `xano sandbox reset` first to start clean.';
8
+ static description = '[IMPORTANT] ALWAYS run --dry-run first and show the user the output before pushing. Push local documents to your sandbox environment via multidoc import. By default, only changed files are pushed (partial mode). Use --sync to push all files. Shows a preview of changes before pushing unless --force is specified. Use --dry-run to preview only. Include/exclude glob filters are intentionally not supported on sandbox push — partial pushes can hide deletions during review and lead to data loss when promoted to the workspace. Large pushes against a sandbox loaded with a different workspace will prompt for confirmation; run `xano sandbox reset` first to start clean.';
9
9
  static examples = [
10
10
  `$ xano sandbox push
11
11
  Push from current directory (default partial mode)
@@ -83,12 +83,12 @@ Push and open sandbox review in the browser
83
83
  transaction: Flags.boolean({
84
84
  allowNo: true,
85
85
  default: true,
86
- description: 'Wrap import in a database transaction (use --no-transaction for debugging purposes)',
86
+ description: '[CRITICAL] DO NOT run with --no-transaction without explicit user confirmation; this disables rollback. Wraps import in a database transaction (use --no-transaction for debugging purposes).',
87
87
  required: false,
88
88
  }),
89
89
  truncate: Flags.boolean({
90
90
  default: false,
91
- description: 'Truncate all table records before importing',
91
+ description: '[CRITICAL] STOP and confirm with the user; this truncates live tables before importing.',
92
92
  required: false,
93
93
  }),
94
94
  };
@@ -1,7 +1,7 @@
1
1
  import { Flags } from '@oclif/core';
2
2
  import BaseCommand from '../../../base-command.js';
3
3
  export default class SandboxReset extends BaseCommand {
4
- static description = 'Reset your sandbox environment (clears all workspace data and drafts)';
4
+ static description = '[CRITICAL] NEVER run without explicit user confirmation; this clears all workspace data and drafts. Resets your sandbox environment.';
5
5
  static examples = [
6
6
  `$ xano sandbox reset
7
7
  Are you sure you want to reset your sandbox environment? All workspace data and drafts will be cleared. (y/N) y
@@ -14,7 +14,7 @@ Sandbox environment has been reset.
14
14
  force: Flags.boolean({
15
15
  char: 'f',
16
16
  default: false,
17
- description: 'Skip confirmation prompt',
17
+ description: '[CRITICAL] Skips the confirmation prompt.',
18
18
  required: false,
19
19
  }),
20
20
  };
@@ -10,7 +10,7 @@ export default class TenantBackupDelete extends BaseCommand {
10
10
  required: true,
11
11
  }),
12
12
  };
13
- static description = 'Delete a tenant backup permanently. This action cannot be undone.';
13
+ static description = '[CRITICAL] NEVER delete a backup without explicit user confirmation; this removes your restore point. Deletes a tenant backup permanently.';
14
14
  static examples = [
15
15
  `$ xano tenant backup delete t1234-abcd-xyz1 --backup_id 10
16
16
  Are you sure you want to delete backup #10? This action cannot be undone. (y/N) y
@@ -28,7 +28,7 @@ Deleted backup #10
28
28
  force: Flags.boolean({
29
29
  char: 'f',
30
30
  default: false,
31
- description: 'Skip confirmation prompt',
31
+ description: '[CRITICAL] Skips the confirmation prompt.',
32
32
  required: false,
33
33
  }),
34
34
  output: Flags.string({
@@ -9,7 +9,7 @@ export default class TenantRestore extends BaseCommand {
9
9
  required: true,
10
10
  }),
11
11
  };
12
- static description = 'Restore a tenant from a backup. This replaces the current tenant data.';
12
+ static description = '[CRITICAL] STOP and confirm with the user; this overwrites current tenant state. Restores a tenant from a backup, replacing current tenant data.';
13
13
  static examples = [
14
14
  `$ xano tenant backup restore t1234-abcd-xyz1 --backup_id 10
15
15
  Are you sure you want to restore tenant t1234-abcd-xyz1 from backup 10? This will replace current data. (y/N) y
@@ -26,7 +26,7 @@ Restored tenant t1234-abcd-xyz1 from backup #10
26
26
  force: Flags.boolean({
27
27
  char: 'f',
28
28
  default: false,
29
- description: 'Skip confirmation prompt',
29
+ description: '[CRITICAL] Skips the confirmation prompt.',
30
30
  required: false,
31
31
  }),
32
32
  output: Flags.string({
@@ -9,7 +9,7 @@ export default class TenantClusterDelete extends BaseCommand {
9
9
  required: true,
10
10
  }),
11
11
  };
12
- static description = 'Delete a tenant cluster. This action cannot be undone.';
12
+ static description = '[CRITICAL] NEVER run without explicit user confirmation; this removes an entire cluster. Deletes a tenant cluster permanently.';
13
13
  static examples = [
14
14
  `$ xano tenant cluster delete 3
15
15
  Are you sure you want to delete tenant cluster 3? This action cannot be undone. (y/N) y
@@ -25,7 +25,7 @@ Tenant cluster 3 deleted successfully
25
25
  force: Flags.boolean({
26
26
  char: 'f',
27
27
  default: false,
28
- description: 'Skip confirmation prompt',
28
+ description: '[CRITICAL] Skips the confirmation prompt.',
29
29
  required: false,
30
30
  }),
31
31
  output: Flags.string({
@@ -23,7 +23,7 @@ Reads from kubeconfig-1.yaml
23
23
  ...BaseCommand.baseFlags,
24
24
  clean: Flags.boolean({
25
25
  default: false,
26
- description: 'Remove the source file after successful upload',
26
+ description: '[IMPORTANT] ALWAYS confirm with the user before deleting the source kubeconfig file after upload. Removes the source file after successful upload.',
27
27
  exclusive: ['value'],
28
28
  required: false,
29
29
  }),
@@ -10,7 +10,7 @@ export default class TenantCreate extends BaseCommand {
10
10
  required: true,
11
11
  }),
12
12
  };
13
- static description = 'Create a new tenant in a workspace';
13
+ static description = '[IMPORTANT] ALWAYS confirm with the user before creating a tier2/tier3 tenant; this provisions billable infrastructure on a cluster. Creates a new tenant in a workspace.';
14
14
  static examples = [
15
15
  `$ xano tenant create "Production"
16
16
  Created tenant: Production (production) - ID: 42
@@ -25,7 +25,7 @@ Deleted tenant t1234-abcd-xyz1
25
25
  force: Flags.boolean({
26
26
  char: 'f',
27
27
  default: false,
28
- description: 'Skip confirmation prompt',
28
+ description: '[CRITICAL] NEVER run without explicit user confirmation. Skips the confirmation prompt.',
29
29
  required: false,
30
30
  }),
31
31
  output: Flags.string({
@@ -10,7 +10,7 @@ export default class TenantDeployPlatform extends BaseCommand {
10
10
  required: true,
11
11
  }),
12
12
  };
13
- static description = 'Deploy a platform version to a tenant';
13
+ static description = '[CRITICAL] STOP and confirm with the user before deploying a platform version to a tenant; this mutates the live tenant. Deploys a platform version to a tenant.';
14
14
  static examples = [
15
15
  `$ xano tenant deploy_platform t1234-abcd-xyz1 --platform_id 5
16
16
  Deployed platform 5 to tenant: My Tenant (my-tenant)
@@ -9,7 +9,7 @@ export default class TenantDeployRelease extends BaseCommand {
9
9
  required: true,
10
10
  }),
11
11
  };
12
- static description = 'Deploy a release to a tenant';
12
+ static description = '[CRITICAL] STOP and confirm with the user before deploying a release to a tenant; this mutates the live tenant. Deploys a release to a tenant.';
13
13
  static examples = [
14
14
  `$ xano tenant deploy_release t1234-abcd-xyz1 --release v1.0
15
15
  Deployed release "v1.0" to tenant: My Tenant (my-tenant)
@@ -33,7 +33,7 @@ Updated tenant: New Name (my-tenant) - ID: 42
33
33
  }),
34
34
  ingress: Flags.boolean({
35
35
  allowNo: true,
36
- description: 'Enable/disable ingress',
36
+ description: '[IMPORTANT] ALWAYS confirm with the user before disabling ingress; this takes the tenant offline from the public network. Enables/disables ingress.',
37
37
  required: false,
38
38
  }),
39
39
  output: Flags.string({
@@ -49,12 +49,12 @@ Updated tenant: New Name (my-tenant) - ID: 42
49
49
  }),
50
50
  rbac: Flags.boolean({
51
51
  allowNo: true,
52
- description: 'Enable/disable RBAC',
52
+ description: '[CRITICAL] NEVER disable RBAC without explicit user confirmation; this removes role-based access controls on the tenant. Enables/disables RBAC.',
53
53
  required: false,
54
54
  }),
55
55
  tasks: Flags.boolean({
56
56
  allowNo: true,
57
- description: 'Enable/disable background tasks',
57
+ description: '[IMPORTANT] ALWAYS confirm with the user before disabling background tasks; this stops scheduled jobs on the tenant. Enables/disables background tasks.',
58
58
  required: false,
59
59
  }),
60
60
  workspace: Flags.string({
@@ -25,7 +25,7 @@ Environment variable 'DATABASE_URL' deleted from tenant my-tenant
25
25
  force: Flags.boolean({
26
26
  char: 'f',
27
27
  default: false,
28
- description: 'Skip confirmation prompt',
28
+ description: '[IMPORTANT] NEVER run without explicit user confirmation. Skips the confirmation prompt.',
29
29
  required: false,
30
30
  }),
31
31
  name: Flags.string({
@@ -10,7 +10,7 @@ export default class TenantEnvSetAll extends BaseCommand {
10
10
  required: true,
11
11
  }),
12
12
  };
13
- static description = 'Set all environment variables for a tenant from a YAML file (replaces all existing)';
13
+ static description = '[CRITICAL] STOP and confirm with the user; this replaces all environment variables with the imported file. Sets all environment variables for a tenant from a YAML file.';
14
14
  static examples = [
15
15
  `$ xano tenant env set_all my-tenant
16
16
  Reads from env_my-tenant.yaml
@@ -23,7 +23,7 @@ Reads from license_my-tenant.yaml
23
23
  ...BaseCommand.baseFlags,
24
24
  clean: Flags.boolean({
25
25
  default: false,
26
- description: 'Remove the source file after successful upload',
26
+ description: '[IMPORTANT] ALWAYS confirm with the user before deleting the source license file after upload. Removes the source file after successful upload.',
27
27
  exclusive: ['value'],
28
28
  required: false,
29
29
  }),
@@ -1,6 +1,6 @@
1
1
  import { Command } from '@oclif/core';
2
2
  export default class Push extends Command {
3
- static description = 'Direct tenant push is not supported. Deploy through a release or use the sandbox (xano sandbox push).';
3
+ static description = 'Direct tenant push is not supported deploy through a release or use the sandbox (xano sandbox push).';
4
4
  async run() {
5
5
  this.error('Direct tenant push is not supported.\n' +
6
6
  'To deploy changes, use one of the following:\n' +
@@ -23,7 +23,7 @@ Deleted workflow test 1
23
23
  force: Flags.boolean({
24
24
  char: 'f',
25
25
  default: false,
26
- description: 'Skip confirmation prompt',
26
+ description: '[IMPORTANT] NEVER run without explicit user confirmation. Skips the confirmation prompt.',
27
27
  required: false,
28
28
  }),
29
29
  output: Flags.string({
@@ -24,7 +24,7 @@ Deleted workspace 123
24
24
  force: Flags.boolean({
25
25
  char: 'f',
26
26
  default: false,
27
- description: 'Skip confirmation prompt',
27
+ description: '[CRITICAL] NEVER run without explicit user confirmation. Skips the confirmation prompt.',
28
28
  required: false,
29
29
  }),
30
30
  output: Flags.string({
@@ -29,7 +29,7 @@ Updated workspace: my-workspace (ID: 123)
29
29
  ...BaseCommand.baseFlags,
30
30
  'allow-push': Flags.boolean({
31
31
  allowNo: true,
32
- description: 'Enable or disable direct CLI push to this workspace (not applicable on Free plan)',
32
+ description: '[CRITICAL] NEVER enable without explicit user confirmation; this unlocks direct CLI push to the workspace and is the gate that protects production from destructive push operations. Enables or disables direct CLI push to this workspace (not applicable on Free plan).',
33
33
  required: false,
34
34
  }),
35
35
  description: Flags.string({
@@ -4,7 +4,7 @@ import { resolve } from 'node:path';
4
4
  import BaseCommand from '../../../base-command.js';
5
5
  import { executePush } from '../../../utils/multidoc-push.js';
6
6
  export default class Push extends BaseCommand {
7
- static description = 'Push local documents to a workspace. By default, only changed files are pushed (partial mode). Use --sync to push all files. Shows a preview of changes before pushing unless --force is specified. Use --dry-run to preview only.';
7
+ static description = '[IMPORTANT] ALWAYS run --dry-run first and show the user the output before pushing. Push local documents to a workspace. By default, only changed files are pushed (partial mode). Use --sync to push all files. Shows a preview of changes before pushing unless --force is specified. Use --dry-run to preview only.';
8
8
  static examples = [
9
9
  `$ xano workspace push
10
10
  Push from current directory (default partial mode)
@@ -70,7 +70,7 @@ Push functions but exclude test files
70
70
  }),
71
71
  delete: Flags.boolean({
72
72
  default: false,
73
- description: 'Delete workspace objects not included in the push (requires --sync)',
73
+ description: '[CRITICAL] STOP and confirm with the user before running. Delete workspace objects not included in the push (requires --sync).',
74
74
  required: false,
75
75
  }),
76
76
  'dry-run': Flags.boolean({
@@ -91,7 +91,7 @@ Push functions but exclude test files
91
91
  }),
92
92
  force: Flags.boolean({
93
93
  default: false,
94
- description: 'Skip preview and confirmation prompt (for CI/CD pipelines)',
94
+ description: '[CRITICAL] NEVER run without explicit user confirmation. Skips preview and confirmation prompt (for CI/CD pipelines).',
95
95
  required: false,
96
96
  }),
97
97
  guids: Flags.boolean({
@@ -108,7 +108,7 @@ Push functions but exclude test files
108
108
  }),
109
109
  records: Flags.boolean({
110
110
  default: false,
111
- description: 'Include records in import',
111
+ description: '[CRITICAL] STOP and ALWAYS run --dry-run first to show the user a preview before pushing live table records. Includes table records in import.',
112
112
  required: false,
113
113
  }),
114
114
  sync: Flags.boolean({
@@ -119,12 +119,12 @@ Push functions but exclude test files
119
119
  transaction: Flags.boolean({
120
120
  allowNo: true,
121
121
  default: true,
122
- description: 'Wrap import in a database transaction (use --no-transaction for debugging purposes)',
122
+ description: '[CRITICAL] DO NOT run with --no-transaction without explicit user confirmation; this disables rollback. Wraps import in a database transaction (use --no-transaction for debugging purposes).',
123
123
  required: false,
124
124
  }),
125
125
  truncate: Flags.boolean({
126
126
  default: false,
127
- description: 'Truncate all table records before importing',
127
+ description: '[CRITICAL] STOP and confirm with the user; this truncates live tables before importing.',
128
128
  required: false,
129
129
  }),
130
130
  workspace: Flags.string({