inferay 0.1.105 → 0.1.107

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "inferay",
3
- "version": "0.1.105",
3
+ "version": "0.1.107",
4
4
  "description": "Install and launch Inferay, a macOS AI workspace for multi-pane Claude/Codex chats, project context, slash commands, agent workspaces, and diffs.",
5
5
  "type": "module",
6
6
  "main": "./index.js",
package/src/cli.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import { createRequire } from "node:module";
2
+ import { getChannel, setChannel } from "./config.js";
3
+ import { doctor } from "./doctor.js";
2
4
  import { install } from "./install.js";
3
5
  import { launchApp } from "./launch.js";
4
- import { doctor } from "./doctor.js";
5
- import { getChannel, setChannel } from "./config.js";
6
6
 
7
7
  const require = createRequire(import.meta.url);
8
8
  const { version: VERSION } = require("../package.json");
@@ -51,8 +51,11 @@ async function printDoctor(args) {
51
51
  }
52
52
  }
53
53
 
54
- async function update() {
55
- const result = await install({ force: true });
54
+ async function update(args) {
55
+ const result = await install({
56
+ force: true,
57
+ launch: !args.includes("--no-launch"),
58
+ });
56
59
  console.log(result.message);
57
60
  }
58
61
 
@@ -105,7 +108,7 @@ export async function main(argv) {
105
108
  await printDoctor(args);
106
109
  return;
107
110
  case "update":
108
- await update();
111
+ await update(args);
109
112
  return;
110
113
  case "channel":
111
114
  if (!args[1]) {
package/src/install.js CHANGED
@@ -1,16 +1,16 @@
1
1
  import { execFile } from "node:child_process";
2
- import { cp, mkdir, readdir, rm } from "node:fs/promises";
3
2
  import { existsSync } from "node:fs";
3
+ import { cp, mkdir, readdir, rm } from "node:fs/promises";
4
4
  import { basename, dirname, join, resolve } from "node:path";
5
5
  import { promisify } from "node:util";
6
6
  import { getChannel } from "./config.js";
7
+ import { openFile } from "./launch.js";
7
8
  import {
8
9
  defaultInstallPath,
9
10
  findExistingApp,
10
11
  platformInfo,
11
12
  } from "./platform.js";
12
13
  import { downloadAsset, fetchRelease, findAsset } from "./releases.js";
13
- import { openFile } from "./launch.js";
14
14
 
15
15
  const execFileAsync = promisify(execFile);
16
16
 
@@ -27,14 +27,14 @@ async function copyAppBundle(source, destination = defaultInstallPath()) {
27
27
  function parseMountPoint(output) {
28
28
  return output
29
29
  .split("\n")
30
- .map((line) => line.trim().split(/\s+/).at(-1))
31
- .find((part) => part?.startsWith("/Volumes/"));
30
+ .map((line) => line.match(/\/Volumes\/[^\r\n]+/)?.[0].trim())
31
+ .find(Boolean);
32
32
  }
33
33
 
34
34
  async function findAppBundle(directory) {
35
35
  const entries = await readdir(directory, { withFileTypes: true });
36
36
  const app = entries.find(
37
- (entry) => entry.isDirectory() && entry.name.endsWith(".app")
37
+ (entry) => entry.isDirectory() && entry.name.endsWith(".app"),
38
38
  );
39
39
  if (!app) {
40
40
  throw new Error(`no .app bundle found in ${directory}`);
@@ -100,7 +100,7 @@ export async function install({ local, launch = true, force = false } = {}) {
100
100
  const asset = findAsset(release, platform);
101
101
  if (!asset) {
102
102
  throw new Error(
103
- `no ${platform.target} release asset found for ${release.tag_name || channel}`
103
+ `no ${platform.target} release asset found for ${release.tag_name || channel}`,
104
104
  );
105
105
  }
106
106