cc-x10ded 3.0.15 → 3.0.16

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/package.json +1 -1
  2. package/src/index.ts +16 -10
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cc-x10ded",
3
- "version": "3.0.15",
3
+ "version": "3.0.16",
4
4
  "description": "Extend Claude Code with custom OpenAI-compatible model providers",
5
5
  "repository": {
6
6
  "type": "git",
package/src/index.ts CHANGED
@@ -22,8 +22,8 @@ cli
22
22
 
23
23
  cli
24
24
  .command("update", "Update ccx to the latest version")
25
- .option("--migrate-aliases", "Also migrate old bunx-based aliases to new format")
26
- .action(async (options: { migrateAliases?: boolean }) => {
25
+ .option("--skip-aliases", "Skip alias installation")
26
+ .action(async (options: { skipAliases?: boolean }) => {
27
27
  const { spawn } = await import("bun");
28
28
  const { ShellIntegrator } = await import("./core/shell");
29
29
  const pc = await import("picocolors");
@@ -43,15 +43,21 @@ cli
43
43
 
44
44
  console.log(pc.default.green("✅ ccx updated!"));
45
45
 
46
- // Migrate aliases
47
- const shellInt = new ShellIntegrator();
48
- const shell = shellInt.detectShell();
46
+ // Always reinstall aliases (unless skipped)
47
+ if (!options.skipAliases) {
48
+ const shellInt = new ShellIntegrator();
49
+ const shell = shellInt.detectShell();
49
50
 
50
- if (shell !== "unknown") {
51
- const migrated = await shellInt.migrateAliases(shell);
52
- if (migrated) {
53
- console.log(pc.default.green("✅ Aliases migrated to new format!"));
54
- console.log(pc.default.dim(` Run: source ~/.${shell}rc (or restart your terminal)`));
51
+ if (shell !== "unknown") {
52
+ // Ensure bun bin is in PATH
53
+ await shellInt.ensureBunBinInPath(shell);
54
+
55
+ // Install/update aliases
56
+ const success = await shellInt.installAliases(shell);
57
+ if (success) {
58
+ console.log(pc.default.green("✅ Aliases updated!"));
59
+ console.log(pc.default.dim(` Run: source ~/.${shell}rc (or restart your terminal)`));
60
+ }
55
61
  }
56
62
  }
57
63