claudient 0.4.0 → 0.5.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/README.md CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  > The definitive knowledge system for Claude Code — skills, agents, hooks, rules, workflows, and prompts that multiply what you can build.
4
4
 
5
+ ![Claudient](web/public/social-preview.svg)
6
+
5
7
  [![npm](https://img.shields.io/npm/v/claudient)](https://www.npmjs.com/package/claudient)
6
8
  [![License: MIT](https://img.shields.io/badge/License-MIT-black.svg)](LICENSE)
7
9
  [![Languages](https://img.shields.io/badge/languages-EN%20%7C%20FR%20%7C%20DE%20%7C%20NL%20%7C%20ES-orange)](#translations)
package/index.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
- "version": "0.4.0",
3
- "generated": "2026-05-16T17:19:22.557Z",
2
+ "version": "0.5.0",
3
+ "generated": "2026-05-16T17:33:40.657Z",
4
4
  "skills": [
5
5
  {
6
6
  "id": "backend/dotnet/csharp",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "claudient",
3
- "version": "0.4.0",
3
+ "version": "0.5.0",
4
4
  "description": "The definitive Claude Code knowledge system — skills, agents, hooks, rules, and workflows.",
5
5
  "keywords": [
6
6
  "claude-code",
package/scripts/cli.js CHANGED
@@ -19,6 +19,7 @@ const SKILL_CATEGORIES = [
19
19
  'database',
20
20
  'finance-payments',
21
21
  'ai-engineering',
22
+ 'productivity',
22
23
  ]
23
24
 
24
25
  const SUPPORTED_LANGS = ['en', 'fr', 'de', 'nl', 'es']
@@ -335,62 +336,118 @@ function updateCommand() {
335
336
  }
336
337
  }
337
338
 
339
+ function loadIndex() {
340
+ // Try index.json next to package.json first (installed package),
341
+ // then fall back to filesystem scan (dev/repo context)
342
+ const indexPath = path.join(REPO_ROOT, 'index.json')
343
+ if (fs.existsSync(indexPath)) {
344
+ try { return JSON.parse(fs.readFileSync(indexPath, 'utf-8')) } catch {}
345
+ }
346
+ return null
347
+ }
348
+
338
349
  function listCommand(type) {
339
- const listSkills = () => {
340
- console.log('Skills:\n')
341
- for (const cat of SKILL_CATEGORIES) {
342
- const catDir = path.join(REPO_ROOT, 'skills', cat)
343
- if (!fs.existsSync(catDir)) continue
344
- const files = getFiles(catDir).filter(f => !SUPPORTED_LANGS.some(l => f.includes(`/${l}/`)))
345
- console.log(` ${cat}/ (${files.length})`)
346
- for (const f of files) console.log(` ${f}`)
350
+ const index = loadIndex()
351
+
352
+ if (index) {
353
+ // Fast path: use pre-built index.json
354
+ const enOnly = (arr) => arr.filter(i => !i.lang || i.lang === 'en')
355
+
356
+ const listSkills = () => {
357
+ const byCategory = {}
358
+ for (const s of enOnly(index.skills)) {
359
+ if (!byCategory[s.category]) byCategory[s.category] = []
360
+ byCategory[s.category].push(s)
361
+ }
362
+ console.log('Skills:\n')
363
+ for (const [cat, items] of Object.entries(byCategory)) {
364
+ console.log(` ${cat}/ (${items.length})`)
365
+ for (const s of items) console.log(` ${s.id.split('/').slice(1).join('/')}.md`)
366
+ }
367
+ console.log(`\n Total: ${enOnly(index.skills).length} skills in ${Object.keys(byCategory).length} categories`)
347
368
  }
348
- }
349
369
 
350
- const listAgents = () => {
351
- console.log('Agents:\n')
352
- const agentsDir = path.join(REPO_ROOT, 'agents')
353
- for (const cat of fs.readdirSync(agentsDir, { withFileTypes: true })) {
354
- if (!cat.isDirectory() || SUPPORTED_LANGS.includes(cat.name)) continue
355
- const files = getFiles(path.join(agentsDir, cat.name)).filter(f => !SUPPORTED_LANGS.some(l => f.includes(`/${l}/`)))
356
- console.log(` ${cat.name}/ (${files.length})`)
357
- for (const f of files) console.log(` ${f}`)
370
+ const listAgents = () => {
371
+ const agents = enOnly(index.agents)
372
+ const byCategory = {}
373
+ for (const a of agents) {
374
+ const cat = a.id.split('/')[0]
375
+ if (!byCategory[cat]) byCategory[cat] = []
376
+ byCategory[cat].push(a)
377
+ }
378
+ console.log('Agents:\n')
379
+ for (const [cat, items] of Object.entries(byCategory)) {
380
+ console.log(` ${cat}/ (${items.length})`)
381
+ for (const a of items) console.log(` ${a.title}`)
382
+ }
358
383
  }
359
- }
360
384
 
361
- const listHooks = () => {
362
- console.log('Hooks:\n')
363
- const hooksDir = path.join(REPO_ROOT, 'hooks')
364
- for (const cat of fs.readdirSync(hooksDir, { withFileTypes: true })) {
365
- if (!cat.isDirectory()) continue
366
- const files = fs.readdirSync(path.join(hooksDir, cat.name)).filter(f => f.endsWith('.sh'))
367
- console.log(` ${cat.name}/ (${files.length})`)
368
- for (const f of files) console.log(` ${f}`)
385
+ const listHooks = () => {
386
+ const byCategory = {}
387
+ for (const h of index.hooks) {
388
+ if (!byCategory[h.category]) byCategory[h.category] = []
389
+ byCategory[h.category].push(h)
390
+ }
391
+ console.log('Hooks:\n')
392
+ for (const [cat, items] of Object.entries(byCategory)) {
393
+ console.log(` ${cat}/ (${items.length})`)
394
+ for (const h of items) console.log(` ${h.id.split('/')[1]}.sh`)
395
+ }
369
396
  }
397
+
398
+ const listRules = () => {
399
+ const rules = enOnly(index.rules)
400
+ const byCategory = {}
401
+ for (const r of rules) {
402
+ if (!byCategory[r.category]) byCategory[r.category] = []
403
+ byCategory[r.category].push(r)
404
+ }
405
+ console.log('Rules:\n')
406
+ for (const [cat, items] of Object.entries(byCategory)) {
407
+ console.log(` ${cat}/ (${items.length})`)
408
+ for (const r of items) console.log(` ${r.slug}.md`)
409
+ }
410
+ }
411
+
412
+ const listAll = () => {
413
+ listSkills(); console.log()
414
+ listAgents(); console.log()
415
+ listRules(); console.log()
416
+ listHooks(); console.log()
417
+ console.log(`Generated: ${index.generated}`)
418
+ console.log(`Version: claudient@${index.version}`)
419
+ }
420
+
421
+ switch (type) {
422
+ case 'agents': listAgents(); break
423
+ case 'hooks': listHooks(); break
424
+ case 'rules': listRules(); break
425
+ case 'skills': listSkills(); break
426
+ default: if (!type) listAll(); else listSkills()
427
+ }
428
+ return
370
429
  }
371
430
 
372
- const listRules = () => {
373
- console.log('Rules:\n')
374
- const rulesDir = path.join(REPO_ROOT, 'rules')
375
- for (const cat of fs.readdirSync(rulesDir, { withFileTypes: true })) {
376
- if (!cat.isDirectory() || SUPPORTED_LANGS.includes(cat.name)) continue
377
- const files = fs.readdirSync(path.join(rulesDir, cat.name)).filter(f => f.endsWith('.md'))
378
- console.log(` ${cat.name}/ (${files.length})`)
431
+ // Fallback: filesystem scan (repo dev context without index.json)
432
+ const listSkillsFs = () => {
433
+ console.log('Skills:\n')
434
+ for (const cat of SKILL_CATEGORIES) {
435
+ const catDir = path.join(REPO_ROOT, 'skills', cat)
436
+ if (!fs.existsSync(catDir)) continue
437
+ const files = getFiles(catDir).filter(f => !SUPPORTED_LANGS.some(l => f.includes(`/${l}/`)))
438
+ console.log(` ${cat}/ (${files.length})`)
379
439
  for (const f of files) console.log(` ${f}`)
380
440
  }
381
441
  }
382
442
 
383
443
  switch (type) {
384
- case 'agents': listAgents(); break
385
- case 'hooks': listHooks(); break
386
- case 'rules': listRules(); break
387
- case 'skills':
444
+ case 'agents':
445
+ case 'hooks':
446
+ case 'rules':
447
+ console.log('(index.json not found — run: npm run build-index)')
448
+ break
388
449
  default:
389
- if (!type) {
390
- listSkills(); console.log(); listAgents(); console.log(); listRules(); console.log(); listHooks()
391
- } else {
392
- listSkills()
393
- }
450
+ listSkillsFs()
394
451
  }
395
452
  }
396
453