@akshar5/cohall 0.12.5 → 0.12.6

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.12.6](https://github.com/AksharP5/cohall/compare/v0.12.5...v0.12.6) (2026-10-17)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * **upgrade:** support Homebrew managers with custom global prefixes ([#209](https://github.com/AksharP5/cohall/issues/209)) ([e826403](https://github.com/AksharP5/cohall/commit/e826403db21a9345a804b1929dea6769e648a2a3))
9
+
3
10
  ## [0.12.5](https://github.com/AksharP5/cohall/compare/v0.12.4...v0.12.5) (2026-10-17)
4
11
 
5
12
 
package/bin/cohall.js CHANGED
@@ -17,7 +17,7 @@ var __esm = (fn, res) => () => (fn && (res = fn(fn = 0)), res);
17
17
 
18
18
  // packages/protocol/src/index.ts
19
19
  import { Effect, Schema } from "effect";
20
- var version = "0.12.5", maxSocketPayloadBytes, maxAuthTokenBytes = 512, maxAttachmentBytes, maxTaskAttachments = 2, maxProgressNoteBytes = 1024, bounded = (maxLength) => Schema.String.check(Schema.isMinLength(1), Schema.isMaxLength(maxLength)), optionalText = (maxLength) => Schema.String.check(Schema.isMaxLength(maxLength)), boundedArray = (schema, maxLength) => Schema.Array(schema).check(Schema.isMaxLength(maxLength)), count, assertOwnerToken = (token) => {
20
+ var version = "0.12.6", maxSocketPayloadBytes, maxAuthTokenBytes = 512, maxAttachmentBytes, maxTaskAttachments = 2, maxProgressNoteBytes = 1024, bounded = (maxLength) => Schema.String.check(Schema.isMinLength(1), Schema.isMaxLength(maxLength)), optionalText = (maxLength) => Schema.String.check(Schema.isMaxLength(maxLength)), boundedArray = (schema, maxLength) => Schema.Array(schema).check(Schema.isMaxLength(maxLength)), count, assertOwnerToken = (token) => {
21
21
  if (token.length < 32) {
22
22
  throw new Error("The Cohall relay owner token must be at least 32 characters");
23
23
  }
@@ -5847,23 +5847,20 @@ var macosHomebrewRoots = ["/opt/homebrew", "/usr/local"];
5847
5847
  var macosAdminGroup = 80;
5848
5848
  var isTrustedSystemPath = (platform4, path) => platform4 === "linux" && (path === "/home" || linuxSystemExecutableRoots.some((root) => containsPath(root, path) || containsPath(path, root)));
5849
5849
  var isTrustedGroupWritablePath = (options) => {
5850
- const writableRoot = options.writableRoot;
5851
- return options.platform === "darwin" && writableRoot !== undefined && options.uid !== undefined && options.ownerUid === options.uid && options.ownerGid === macosAdminGroup && macosHomebrewRoots.some((root) => containsPath(root, writableRoot)) && containsPath(writableRoot, options.canonical) && containsPath(writableRoot, options.path);
5850
+ return options.platform === "darwin" && options.uid !== undefined && options.ownerUid === options.uid && options.ownerGid === macosAdminGroup && macosHomebrewRoots.some((root) => containsPath(root, options.canonical) && containsPath(root, options.path));
5852
5851
  };
5853
- var validateExecutable = async (candidate, installationRoot, preserveSymlink = false) => {
5852
+ var validateExecutable = async (candidate, preserveSymlink = false) => {
5854
5853
  const canonical = await realpath2(candidate);
5855
5854
  if (operatingSystem() === "win32") {
5856
5855
  return preserveSymlink ? resolve3(candidate) : canonical;
5857
5856
  }
5858
5857
  const uid = process.getuid?.();
5859
- const writableRoot = installationRoot === undefined ? undefined : await realpath2(installationRoot);
5860
5858
  for (const executablePath of preserveSymlink ? [canonical, resolve3(candidate)] : [canonical]) {
5861
5859
  for (let path = executablePath;; path = dirname3(path)) {
5862
5860
  const metadata = await stat2(path);
5863
5861
  const trustedGroupWritablePath = isTrustedGroupWritablePath({
5864
5862
  platform: operatingSystem(),
5865
5863
  canonical,
5866
- writableRoot,
5867
5864
  path,
5868
5865
  uid,
5869
5866
  ownerUid: metadata.uid,
@@ -5893,7 +5890,7 @@ var trustedExecutable = async (command, options = {}) => {
5893
5890
  try {
5894
5891
  if (!(await stat2(path)).isFile())
5895
5892
  continue;
5896
- return await validateExecutable(path, options.writableRoot, options.preserveSymlink);
5893
+ return await validateExecutable(path, options.preserveSymlink);
5897
5894
  } catch (cause) {
5898
5895
  failure ??= cause;
5899
5896
  }
@@ -6257,7 +6254,7 @@ var upgrade = async (options) => {
6257
6254
  const resolvePackageManager = () => {
6258
6255
  if (installation.pnpmExecutable !== undefined)
6259
6256
  return Promise.resolve(installation.pnpmExecutable);
6260
- return options.resolveExecutable === undefined ? trustedExecutable(installation.manager, installation.prefix === undefined ? {} : { writableRoot: installation.prefix }) : resolveExecutable(installation.manager);
6257
+ return options.resolveExecutable === undefined ? trustedExecutable(installation.manager) : resolveExecutable(installation.manager);
6261
6258
  };
6262
6259
  let packageManagerExecutable;
6263
6260
  let resolvedTarget = target;
@@ -9202,4 +9199,4 @@ await main().catch((cause) => {
9202
9199
  process.exitCode = 1;
9203
9200
  });
9204
9201
 
9205
- //# debugId=A33BDA8325259EFC64756E2164756E21
9202
+ //# debugId=0C3787CDC3B3DC7D64756E2164756E21