@ghl-ai/aw 0.1.70-beta.4 → 0.1.70-beta.5

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/integrations.mjs +36 -7
  2. package/package.json +1 -1
package/integrations.mjs CHANGED
@@ -15,7 +15,7 @@ import {
15
15
  mkdirSync,
16
16
  rmSync,
17
17
  } from 'node:fs';
18
- import { join, basename } from 'node:path';
18
+ import { join, basename, delimiter } from 'node:path';
19
19
  import { homedir } from 'node:os';
20
20
  import * as fmt from './fmt.mjs';
21
21
  import { chalk } from './fmt.mjs';
@@ -36,6 +36,29 @@ function getErrorMessage(error) {
36
36
  return error instanceof Error ? error.message : String(error);
37
37
  }
38
38
 
39
+ function shellQuote(value) {
40
+ return `'${String(value).replaceAll("'", "'\\''")}'`;
41
+ }
42
+
43
+ function installerEnv(home = HOME) {
44
+ const pathEntries = [
45
+ join(home, '.local', 'bin'),
46
+ join(home, '.cargo', 'bin'),
47
+ join(home, 'bin'),
48
+ process.env.PATH || '',
49
+ ].filter(Boolean);
50
+
51
+ return {
52
+ ...process.env,
53
+ HOME: home,
54
+ PATH: pathEntries.join(delimiter),
55
+ };
56
+ }
57
+
58
+ function posixInstallerCommand(url, runner = 'bash') {
59
+ return `bash -o pipefail -c ${shellQuote(`curl -fsSL ${shellQuote(url)} | ${runner}`)}`;
60
+ }
61
+
39
62
  // ────────────────────────────────────────────────────────────────────────────────
40
63
  // INTEGRATION REGISTRY
41
64
  // ────────────────────────────────────────────────────────────────────────────────
@@ -76,7 +99,7 @@ export const INTEGRATIONS = {
76
99
  description: 'CLI proxy that filters/compresses shell output (git, tests, logs) by 60-90%',
77
100
  scripts: {
78
101
  win32: null, // use WSL fallback
79
- posix: 'https://raw.githubusercontent.com/rtk-ai/rtk/main/install.sh',
102
+ posix: 'https://raw.githubusercontent.com/rtk-ai/rtk/refs/heads/master/install.sh',
80
103
  },
81
104
  postInstall: [
82
105
  'rtk init -g', // Claude Code
@@ -110,11 +133,11 @@ export const INTEGRATIONS = {
110
133
  posix: null, // no binary — installed entirely via npx below
111
134
  },
112
135
  postInstall: [
113
- 'npx skills@latest add mattpocock/skills',
136
+ 'npx skills@latest add mattpocock/skills --global --all',
114
137
  ],
115
138
  teams: [],
116
139
  requiresAuth: false,
117
- authNote: 'Interactive install pick which skills + agents you want. Then run /setup-matt-pocock-skills once per repo.',
140
+ authNote: 'Installs all bundled skills and agents globally. Then run /setup-matt-pocock-skills once per repo.',
118
141
  },
119
142
 
120
143
  // PYTHON CLIs (installed via uv / pipx / pip, then runs post-install hooks)
@@ -601,6 +624,7 @@ async function runClaudePlugin(installCmd, { silent = false, marketplaceSource =
601
624
 
602
625
  async function runUniversalInstaller(integration, key, { silent = false, home = HOME } = {}) {
603
626
  const spinner = silent ? null : fmt.spinner();
627
+ const env = installerEnv(home);
604
628
 
605
629
  if (!silent) spinner.start(`Installing ${integration.label} for all detected IDEs...`);
606
630
 
@@ -633,7 +657,7 @@ async function runUniversalInstaller(integration, key, { silent = false, home =
633
657
  }
634
658
 
635
659
  if (wslOk) {
636
- cmd = `wsl -- bash -c "curl -fsSL '${integration.scripts.posix}' | sh"`;
660
+ cmd = `wsl -- ${posixInstallerCommand(integration.scripts.posix, 'sh')}`;
637
661
  } else if (integration.npmPackage) {
638
662
  if (!silent) fmt.logWarn('WSL/bash not available — installing via npm instead');
639
663
  cmd = `npm install -g ${integration.npmPackage}`;
@@ -651,13 +675,14 @@ async function runUniversalInstaller(integration, key, { silent = false, home =
651
675
  }
652
676
  }
653
677
  } else {
654
- cmd = `curl -fsSL '${integration.scripts.posix}' | bash`;
678
+ cmd = posixInstallerCommand(integration.scripts.posix);
655
679
  }
656
680
 
657
681
  if (cmd) {
658
682
  await execAsync(cmd, {
659
683
  timeout: 5 * 60 * 1000,
660
684
  maxBuffer: 20 * 1024 * 1024,
685
+ env,
661
686
  });
662
687
  }
663
688
 
@@ -673,7 +698,11 @@ async function runUniversalInstaller(integration, key, { silent = false, home =
673
698
  }
674
699
 
675
700
  try {
676
- await execAsync(finalPostCmd, { timeout: 60 * 1000, maxBuffer: 10 * 1024 * 1024 });
701
+ await execAsync(finalPostCmd, {
702
+ timeout: 60 * 1000,
703
+ maxBuffer: 10 * 1024 * 1024,
704
+ env,
705
+ });
677
706
  } catch (e) {
678
707
  failedPostInstalls.push(finalPostCmd);
679
708
  if (!silent) fmt.logWarn(`Post-install step failed: ${finalPostCmd} — ${getErrorMessage(e)}`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ghl-ai/aw",
3
- "version": "0.1.70-beta.4",
3
+ "version": "0.1.70-beta.5",
4
4
  "description": "Agentic Workspace CLI — pull, push & manage agents, skills and commands from the registry",
5
5
  "type": "module",
6
6
  "bin": {