aawp-ai 1.5.3 → 1.6.0
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/bin/install.js +10 -7
- package/package.json +1 -1
package/bin/install.js
CHANGED
|
@@ -69,9 +69,12 @@ function dirExists(p) {
|
|
|
69
69
|
const CLIENTS = [
|
|
70
70
|
{
|
|
71
71
|
name: 'OpenClaw',
|
|
72
|
-
detect: () => hasCmd('clawhub'),
|
|
72
|
+
detect: () => hasCmd('clawhub') || dirExists('skills'),
|
|
73
73
|
install: async () => {
|
|
74
|
-
|
|
74
|
+
if (!hasCmd('git')) return false;
|
|
75
|
+
const dest = path.join('skills', SKILL_NAME);
|
|
76
|
+
if (dirExists(dest)) { warn(`${dest} already exists — skipping git clone`); return true; }
|
|
77
|
+
const r = spawnSync('git', ['clone', '--depth', '1', 'https://github.com/aawp-ai/aawp.git', dest], { stdio: 'inherit' });
|
|
75
78
|
return r.status === 0;
|
|
76
79
|
},
|
|
77
80
|
skillDir: null,
|
|
@@ -145,13 +148,13 @@ async function main() {
|
|
|
145
148
|
|
|
146
149
|
const openclaw = detected.find(c => c.name === 'OpenClaw');
|
|
147
150
|
if (openclaw) {
|
|
148
|
-
info('Installing via
|
|
151
|
+
info('Installing via git clone (OpenClaw)...');
|
|
149
152
|
try {
|
|
150
153
|
const ok = await openclaw.install();
|
|
151
|
-
if (ok) { success('Installed via
|
|
152
|
-
else { warn('
|
|
154
|
+
if (ok) { success('Installed via git clone'); count++; }
|
|
155
|
+
else { warn('git clone failed — falling back to file install'); }
|
|
153
156
|
} catch (e) {
|
|
154
|
-
warn(`
|
|
157
|
+
warn(`git clone error: ${e.message}`);
|
|
155
158
|
}
|
|
156
159
|
console.log('');
|
|
157
160
|
}
|
|
@@ -188,7 +191,7 @@ async function main() {
|
|
|
188
191
|
console.log('');
|
|
189
192
|
console.log(` ${dim('Restart your AI client to load the skill.')}`);
|
|
190
193
|
console.log(` ${dim('Then ask: "set up my AAWP wallet"')}`);
|
|
191
|
-
console.log(` ${dim('Full autonomy (24/7 daemon
|
|
194
|
+
console.log(` ${dim('Full autonomy (24/7 daemon): git clone https://github.com/aawp-ai/aawp.git skills/aawp')}`);
|
|
192
195
|
console.log(` ${dim('Docs: https://aawp.ai · https://github.com/aawp-ai/aawp')}`);
|
|
193
196
|
} else {
|
|
194
197
|
warn('Nothing was installed.');
|