@robinmordasiewicz/f5xc-xcsh 2.0.21-2601090626 → 2.0.21-2601090658

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 (2) hide show
  1. package/dist/index.js +17 -7
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -46994,8 +46994,8 @@ function getLogoModeFromEnv(envPrefix) {
46994
46994
  var CLI_NAME = "xcsh";
46995
46995
  var CLI_FULL_NAME = "F5 Distributed Cloud Shell";
46996
46996
  function getVersion() {
46997
- if ("v2.0.21-2601090626") {
46998
- return "v2.0.21-2601090626";
46997
+ if ("v2.0.21-2601090658") {
46998
+ return "v2.0.21-2601090658";
46999
46999
  }
47000
47000
  if (process.env.XCSH_VERSION) {
47001
47001
  return process.env.XCSH_VERSION;
@@ -77130,6 +77130,13 @@ var CompletionRegistry = class {
77130
77130
  }
77131
77131
  }
77132
77132
  }
77133
+ /**
77134
+ * Register an alias for a domain
77135
+ * Used for domain aliases that aren't part of the domain definition
77136
+ */
77137
+ registerAlias(alias, canonicalName) {
77138
+ this.aliases.set(alias, canonicalName);
77139
+ }
77133
77140
  /**
77134
77141
  * Add or merge children into an existing domain
77135
77142
  * Used for extensions that augment API domains
@@ -80472,12 +80479,15 @@ for (const [, info] of domainRegistry) {
80472
80479
  var domainAliases = /* @__PURE__ */ new Map();
80473
80480
  for (const alias of cloudstatusAliases) {
80474
80481
  domainAliases.set(alias, "cloudstatus");
80482
+ completionRegistry.registerAlias(alias, "cloudstatus");
80475
80483
  }
80476
80484
  for (const alias of aiServicesAliases) {
80477
80485
  domainAliases.set(alias, "ai_services");
80486
+ completionRegistry.registerAlias(alias, "ai_services");
80478
80487
  }
80479
80488
  for (const alias of subscriptionAliases) {
80480
80489
  domainAliases.set(alias, "subscription");
80490
+ completionRegistry.registerAlias(alias, "subscription");
80481
80491
  }
80482
80492
  function resolveDomainAlias(name) {
80483
80493
  return domainAliases.get(name) ?? name;
@@ -81920,7 +81930,7 @@ function parseCommand(input) {
81920
81930
  };
81921
81931
  }
81922
81932
  if (trimmed.startsWith("/") && trimmed.length > 1) {
81923
- const parts2 = trimmed.slice(1).split(/\s+/);
81933
+ const parts2 = parseInputArgs(trimmed.slice(1));
81924
81934
  const domainPart = parts2[0] ?? "";
81925
81935
  const hasExtension = extensionRegistry.hasExtension(domainPart);
81926
81936
  if (isValidDomain(domainPart) || isCustomDomain(domainPart) || hasExtension) {
@@ -81955,10 +81965,10 @@ function parseCommand(input) {
81955
81965
  raw: effectiveCommand,
81956
81966
  isDirectNavigation: false,
81957
81967
  isBuiltin: true,
81958
- args: trimmed.split(/\s+/).slice(1)
81968
+ args: parseInputArgs(trimmed).slice(1)
81959
81969
  };
81960
81970
  }
81961
- const parts = trimmed.split(/\s+/);
81971
+ const parts = parseInputArgs(trimmed);
81962
81972
  return {
81963
81973
  raw: trimmed,
81964
81974
  isDirectNavigation: false,
@@ -82078,7 +82088,7 @@ function executeBuiltin(cmd, session, ctx) {
82078
82088
  };
82079
82089
  }
82080
82090
  if (command === "whoami" || command.startsWith("whoami ")) {
82081
- const parts = command.split(/\s+/).slice(1);
82091
+ const parts = parseInputArgs(command).slice(1);
82082
82092
  const options = {};
82083
82093
  for (const arg of parts) {
82084
82094
  const lowerArg = arg.toLowerCase();
@@ -82603,7 +82613,7 @@ async function executeAPICommand(session, ctx, cmd) {
82603
82613
  args = cmd.args;
82604
82614
  }
82605
82615
  } else {
82606
- const parts = cmd.raw.split(/\s+/);
82616
+ const parts = parseInputArgs(cmd.raw);
82607
82617
  domain = parts[0] ?? "";
82608
82618
  action = parts[1]?.toLowerCase() ?? "list";
82609
82619
  args = parts.slice(validActions.has(action) ? 2 : 1);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@robinmordasiewicz/f5xc-xcsh",
3
- "version": "2.0.21-2601090626",
3
+ "version": "2.0.21-2601090658",
4
4
  "description": "F5 Distributed Cloud Shell - Interactive CLI for F5 XC",
5
5
  "type": "module",
6
6
  "bin": {