clawlabor 1.11.2 → 1.11.3

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/SKILL.md CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  name: clawlabor
3
3
  description: "The autonomous marketplace where AI agents discover, purchase, and sell specialized AI capabilities. Use when the user needs to find, hire, buy, sell, or outsource AI capabilities through UAT escrow."
4
- version: "1.11.2"
4
+ version: "1.11.3"
5
5
  tags:
6
6
  - ai-marketplace
7
7
  - agent-to-agent
package/bin/install.js CHANGED
@@ -68,6 +68,11 @@ const DOCS_URL = "https://www.clawlabor.com/skill.md";
68
68
  function copySkillFiles(targetDir) {
69
69
  const sourceDir = path.resolve(__dirname, "..");
70
70
 
71
+ // A previous symlink-mode install may have left `targetDir` as a symlink
72
+ // (often dangling, once the global package it pointed at was removed).
73
+ // `mkdirSync` throws ENOENT on a dangling symlink, so clear it first.
74
+ clearExistingPath(targetDir);
75
+
71
76
  fs.mkdirSync(targetDir, { recursive: true });
72
77
 
73
78
  for (const file of FILES_TO_COPY) {
@@ -135,14 +140,25 @@ function safeLstat(p) {
135
140
  }
136
141
  }
137
142
 
143
+ // Remove whatever currently occupies `p`, if anything. Symlinks (including
144
+ // dangling ones) MUST be unlinked: `fs.rmSync(p, { recursive, force })`
145
+ // follows the link, hits ENOENT on a dangling target, and — because of
146
+ // `force` — silently no-ops, leaving the dead link in place.
147
+ function clearExistingPath(p) {
148
+ const stat = safeLstat(p);
149
+ if (!stat) return;
150
+ if (stat.isSymbolicLink()) {
151
+ fs.unlinkSync(p);
152
+ return;
153
+ }
154
+ fs.rmSync(p, { recursive: true, force: true });
155
+ }
156
+
138
157
  function symlinkTarget(target, sourceDir) {
139
158
  // Replace whatever's at `target` (file / dir / existing symlink) with a fresh
140
159
  // symlink → sourceDir. Returns { ok, error? }. Windows or hardened sandboxes
141
160
  // may refuse symlink creation; caller falls back to copy mode.
142
- const stat = safeLstat(target);
143
- if (stat) {
144
- fs.rmSync(target, { recursive: true, force: true });
145
- }
161
+ clearExistingPath(target);
146
162
  try {
147
163
  fs.mkdirSync(path.dirname(target), { recursive: true });
148
164
  fs.symlinkSync(sourceDir, target, "dir");
@@ -154,7 +170,7 @@ function symlinkTarget(target, sourceDir) {
154
170
 
155
171
  function removeSkillDir(targetDir) {
156
172
  if (fs.existsSync(targetDir) || safeLstat(targetDir)) {
157
- fs.rmSync(targetDir, { recursive: true, force: true });
173
+ clearExistingPath(targetDir);
158
174
  return true;
159
175
  }
160
176
  return false;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "clawlabor",
3
- "version": "1.11.2",
3
+ "version": "1.11.3",
4
4
  "description": "ClawLabor AI Capability Marketplace skill for Claude Code, OpenClaw, and Codex CLI. Discover, purchase, and sell specialized AI capabilities.",
5
5
  "keywords": [
6
6
  "agent-skills",