findskills 0.1.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.js +46 -0
- package/package.json +30 -0
package/bin.js
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const BOLD = '\x1b[1m';
|
|
4
|
+
const DIM = '\x1b[2m';
|
|
5
|
+
const CYAN = '\x1b[36m';
|
|
6
|
+
const YELLOW = '\x1b[33m';
|
|
7
|
+
const RESET = '\x1b[0m';
|
|
8
|
+
|
|
9
|
+
const query = process.argv.slice(2).join(' ').trim();
|
|
10
|
+
|
|
11
|
+
if (!query) {
|
|
12
|
+
console.log(`\n ${BOLD}findskills${RESET} — Search 15,000+ AI agent skills\n`);
|
|
13
|
+
console.log(` ${DIM}Usage:${RESET} findskills <query>\n`);
|
|
14
|
+
console.log(` ${DIM}Examples:${RESET}`);
|
|
15
|
+
console.log(` findskills "web scraping"`);
|
|
16
|
+
console.log(` findskills github automation`);
|
|
17
|
+
console.log(` findskills database\n`);
|
|
18
|
+
process.exit(0);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
const API = 'https://findskills.org/api/v1/search';
|
|
22
|
+
|
|
23
|
+
try {
|
|
24
|
+
const res = await fetch(`${API}?q=${encodeURIComponent(query)}&limit=10`);
|
|
25
|
+
if (!res.ok) throw new Error(`API error: ${res.status}`);
|
|
26
|
+
const data = await res.json();
|
|
27
|
+
|
|
28
|
+
if (!data.skills?.length) {
|
|
29
|
+
console.log(`\n No skills found for "${query}"\n`);
|
|
30
|
+
process.exit(0);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
console.log(`\n ${DIM}${data.total} results for${RESET} "${query}"${data.total > 10 ? ` ${DIM}(showing top 10)${RESET}` : ''}\n`);
|
|
34
|
+
|
|
35
|
+
for (const s of data.skills) {
|
|
36
|
+
const score = s.quality_score != null ? ` ${YELLOW}★ ${s.quality_score}${RESET}` : '';
|
|
37
|
+
console.log(` ${BOLD}${CYAN}${s.name}${RESET}${score}`);
|
|
38
|
+
if (s.description) console.log(` ${s.description}`);
|
|
39
|
+
if (s.tags?.length) console.log(` ${DIM}${s.tags.map(t => `[${t}]`).join(' ')}${RESET}`);
|
|
40
|
+
if (s.url) console.log(` ${DIM}→ ${s.url}${RESET}`);
|
|
41
|
+
console.log();
|
|
42
|
+
}
|
|
43
|
+
} catch (err) {
|
|
44
|
+
console.error(`\n ${BOLD}Error:${RESET} ${err.message}\n`);
|
|
45
|
+
process.exit(1);
|
|
46
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "findskills",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Search 15,000+ AI agent skills from the terminal",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"bin": {
|
|
7
|
+
"findskills": "./bin.js"
|
|
8
|
+
},
|
|
9
|
+
"files": [
|
|
10
|
+
"bin.js"
|
|
11
|
+
],
|
|
12
|
+
"engines": {
|
|
13
|
+
"node": ">=18.0.0"
|
|
14
|
+
},
|
|
15
|
+
"keywords": [
|
|
16
|
+
"ai",
|
|
17
|
+
"agent",
|
|
18
|
+
"skills",
|
|
19
|
+
"mcp",
|
|
20
|
+
"findskills",
|
|
21
|
+
"cli",
|
|
22
|
+
"search"
|
|
23
|
+
],
|
|
24
|
+
"license": "MIT",
|
|
25
|
+
"repository": {
|
|
26
|
+
"type": "git",
|
|
27
|
+
"url": "git+https://github.com/shintemy/findskills.git",
|
|
28
|
+
"directory": "cli"
|
|
29
|
+
}
|
|
30
|
+
}
|