thinkwork-cli 0.5.3 → 0.5.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 (2) hide show
  1. package/dist/cli.js +7 -2
  2. package/package.json +1 -1
package/dist/cli.js CHANGED
@@ -2026,6 +2026,7 @@ function registerToolsCommand(program2) {
2026
2026
 
2027
2027
  // src/commands/update.ts
2028
2028
  import { execSync as execSync9 } from "child_process";
2029
+ import { realpathSync } from "fs";
2029
2030
  import chalk9 from "chalk";
2030
2031
  function getLatestVersion() {
2031
2032
  try {
@@ -2045,8 +2046,12 @@ function detectInstallMethod() {
2045
2046
  timeout: 5e3,
2046
2047
  stdio: ["pipe", "pipe", "pipe"]
2047
2048
  }).trim();
2048
- if (which.includes("Cellar") || which.includes("homebrew")) return "homebrew";
2049
- if (which.includes("node_modules") || which.includes("npm") || which.includes("nvm") || which.includes("fnm")) return "npm";
2049
+ let resolved = which;
2050
+ try {
2051
+ resolved = realpathSync(which);
2052
+ } catch {
2053
+ }
2054
+ if (resolved.includes("/Cellar/")) return "homebrew";
2050
2055
  return "npm";
2051
2056
  } catch {
2052
2057
  return "npm";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "thinkwork-cli",
3
- "version": "0.5.3",
3
+ "version": "0.5.4",
4
4
  "description": "Thinkwork CLI — deploy, manage, and interact with your Thinkwork stack",
5
5
  "license": "MIT",
6
6
  "type": "module",