@robinmordasiewicz/f5xc-xcsh 1.0.91-2601030116 → 1.0.91-2601030153

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 +13 -13
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -47015,8 +47015,8 @@ function getLogoModeFromEnv(envPrefix) {
47015
47015
  var CLI_NAME = "xcsh";
47016
47016
  var CLI_FULL_NAME = "F5 Distributed Cloud Shell";
47017
47017
  function getVersion() {
47018
- if ("v1.0.91-2601030116") {
47019
- return "v1.0.91-2601030116";
47018
+ if ("v1.0.91-2601030153") {
47019
+ return "v1.0.91-2601030153";
47020
47020
  }
47021
47021
  if (process.env.XCSH_VERSION) {
47022
47022
  return process.env.XCSH_VERSION;
@@ -145455,7 +145455,7 @@ var createCommand2 = {
145455
145455
  descriptionMedium: "Create a profile with tenant URL, authentication token, and optional default namespace.",
145456
145456
  usage: "<name> --url <api-url> --token <api-token> [--namespace <ns>]",
145457
145457
  aliases: ["add", "new"],
145458
- async execute(args, _session) {
145458
+ async execute(args, session) {
145459
145459
  const manager = getProfileManager();
145460
145460
  const name = args[0];
145461
145461
  if (!name || name.startsWith("-")) {
@@ -145515,23 +145515,23 @@ var createCommand2 = {
145515
145515
  if (!result.success) {
145516
145516
  return errorResult(result.message);
145517
145517
  }
145518
+ await session.switchProfile(name);
145518
145519
  const connectionInfo = buildConnectionInfo(
145519
145520
  name,
145520
145521
  apiUrl,
145521
145522
  true,
145522
145523
  // hasToken - we just saved it
145523
- defaultNamespace || "default",
145524
- false
145525
- // Not connected yet - profile just created
145524
+ defaultNamespace || session.getNamespace(),
145525
+ session.isAuthenticated(),
145526
+ session.isTokenValidated(),
145527
+ session.getValidationError() ?? void 0
145526
145528
  );
145527
145529
  const tableLines = formatConnectionTable(connectionInfo);
145528
- return successResult([
145529
- `Profile '${name}' created successfully.`,
145530
- ``,
145531
- ...tableLines,
145532
- ``,
145533
- `Use 'login profile use ${name}' to activate this profile.`
145534
- ]);
145530
+ return successResult(
145531
+ [`Profile '${name}' created and activated.`, ``, ...tableLines],
145532
+ true
145533
+ // contextChanged - REPL prompt should update
145534
+ );
145535
145535
  }
145536
145536
  };
145537
145537
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@robinmordasiewicz/f5xc-xcsh",
3
- "version": "1.0.91-2601030116",
3
+ "version": "1.0.91-2601030153",
4
4
  "description": "F5 Distributed Cloud Shell - Interactive CLI for F5 XC",
5
5
  "type": "module",
6
6
  "bin": {