From 6c78886ec903a10b67aac02393a7653d202789fb Mon Sep 17 00:00:00 2001 From: Pip Date: Tue, 10 Mar 2026 17:42:31 -0500 Subject: [PATCH 1/2] openclaw: auto-register agents on install MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit After copying workspace files, call `openclaw agents add --non-interactive` for each agent so they're immediately usable by agentId without any manual config steps. Guarded by `command -v openclaw` so it's a no-op when OpenClaw isn't installed. Adds a post-install reminder to restart the gateway. Tested by Pip — an OpenClaw instance running on the machine that maintains the agency-agents repo. 🫛 --- scripts/install.sh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/scripts/install.sh b/scripts/install.sh index 8d7e531..7505bf0 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -358,9 +358,16 @@ install_openclaw() { cp "$d/SOUL.md" "$dest/$name/SOUL.md" cp "$d/AGENTS.md" "$dest/$name/AGENTS.md" cp "$d/IDENTITY.md" "$dest/$name/IDENTITY.md" + # Register with OpenClaw so agents are usable by agentId immediately + if command -v openclaw >/dev/null 2>&1; then + openclaw agents add "$name" --workspace "$dest/$name" --non-interactive 2>/dev/null || true + fi (( count++ )) || true done < <(find "$src" -mindepth 1 -maxdepth 1 -type d -print0) ok "OpenClaw: $count workspaces -> $dest" + if command -v openclaw >/dev/null 2>&1; then + warn "OpenClaw: run 'openclaw gateway restart' to activate new agents" + fi } install_cursor() { From 27afa03c64f73cb6cc4013d100214b348151a826 Mon Sep 17 00:00:00 2001 From: Pip Date: Tue, 10 Mar 2026 18:54:15 -0500 Subject: [PATCH 2/2] openclaw: let stderr through on agents add failure --- scripts/install.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/install.sh b/scripts/install.sh index 7505bf0..ddfd701 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -360,7 +360,7 @@ install_openclaw() { cp "$d/IDENTITY.md" "$dest/$name/IDENTITY.md" # Register with OpenClaw so agents are usable by agentId immediately if command -v openclaw >/dev/null 2>&1; then - openclaw agents add "$name" --workspace "$dest/$name" --non-interactive 2>/dev/null || true + openclaw agents add "$name" --workspace "$dest/$name" --non-interactive || true fi (( count++ )) || true done < <(find "$src" -mindepth 1 -maxdepth 1 -type d -print0)