@ghl-ai/aw 0.1.36-beta.64 → 0.1.36-beta.65

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/integrate.mjs +14 -4
  2. package/package.json +1 -1
package/integrate.mjs CHANGED
@@ -39,7 +39,11 @@ export function generateCommands(cwd, { silent = false } = {}) {
39
39
  function findFiles(dir, typeName) {
40
40
  const results = [];
41
41
  function walk(d) {
42
- for (const entry of readdirSync(d, { withFileTypes: true })) {
42
+ let entries;
43
+ try {
44
+ entries = readdirSync(d, { withFileTypes: true });
45
+ } catch { return; } // not a directory — skip gracefully
46
+ for (const entry of entries) {
43
47
  if (entry.name.startsWith('.')) continue;
44
48
  const full = join(d, entry.name);
45
49
  if (entry.isDirectory()) {
@@ -432,12 +436,18 @@ No active tasks. Tasks are created during workflow execution.
432
436
  }
433
437
 
434
438
  /**
435
- * Return team namespace paths from config (excludes 'platform').
436
- * E.g. ['revex/courses'] generated CLI commands only go into team namespaces.
439
+ * Return top-level team namespace names from config (excludes 'platform').
440
+ * cfg.include may contain full paths like 'mobile/core/backend/agents/dev.md'
441
+ * so we extract only the first path segment (the actual namespace folder).
442
+ * E.g. ['mobile/core/backend/agents/dev.md', 'revex'] → ['mobile', 'revex']
437
443
  */
438
444
  function getTeamNamespaces(awDir) {
439
445
  const cfg = config.load(awDir);
440
446
  if (!cfg || !cfg.include) return [];
441
- return cfg.include.filter(p => p !== 'platform');
447
+ return [...new Set(
448
+ cfg.include
449
+ .filter(p => p !== 'platform')
450
+ .map(p => p.split('/')[0]),
451
+ )];
442
452
  }
443
453
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ghl-ai/aw",
3
- "version": "0.1.36-beta.64",
3
+ "version": "0.1.36-beta.65",
4
4
  "description": "Agentic Workspace CLI — pull, push & manage agents, skills and commands from the registry",
5
5
  "type": "module",
6
6
  "bin": "bin.js",