toga-ai 1.0.22 → 1.0.24
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/package.json +2 -2
- package/scripts/install.js +25 -16
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "toga-ai",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.24",
|
|
4
4
|
"description": "TOGA Technology Team Claude Knowledge System — shared AI coding harness with skills, knowledge base CLI, and project installer for Claude Code.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"claude",
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"homepage": "https://togatech.com",
|
|
16
16
|
"repository": {
|
|
17
17
|
"type": "git",
|
|
18
|
-
"url": "https://github.com/
|
|
18
|
+
"url": "https://github.com/agilantsolutions/claude"
|
|
19
19
|
},
|
|
20
20
|
"license": "UNLICENSED",
|
|
21
21
|
"private": false,
|
package/scripts/install.js
CHANGED
|
@@ -510,22 +510,15 @@ function main() {
|
|
|
510
510
|
|
|
511
511
|
const bundleVersion = getBundleVersion();
|
|
512
512
|
|
|
513
|
-
// Warn if
|
|
514
|
-
//
|
|
513
|
+
// Warn if npx served a stale cached version (common on Windows). Never block — install
|
|
514
|
+
// the current bundle now and let the user update afterwards.
|
|
515
515
|
if (!isPostInstall) {
|
|
516
516
|
const latestVersion = getLatestNpmVersion();
|
|
517
517
|
if (latestVersion && semverLt(bundleVersion, latestVersion)) {
|
|
518
518
|
console.log('');
|
|
519
|
-
console.log('⚠
|
|
520
|
-
console.log('
|
|
521
|
-
console.log('
|
|
522
|
-
console.log(' Your npx cache has an old version. Run the following to fix it:');
|
|
523
|
-
console.log('');
|
|
524
|
-
console.log(' npm cache clean --force');
|
|
525
|
-
console.log(' npx toga-ai@latest');
|
|
526
|
-
console.log('');
|
|
527
|
-
console.log(' (This is a common npx caching issue on Windows.)');
|
|
528
|
-
process.exit(1);
|
|
519
|
+
console.log(' ⚠ Running toga-ai@' + bundleVersion + ' — toga-ai@' + latestVersion + ' is available.');
|
|
520
|
+
console.log(' Update with: npm cache clean --force && npx toga-ai@latest');
|
|
521
|
+
console.log(' (Continuing install with current bundle...)');
|
|
529
522
|
}
|
|
530
523
|
}
|
|
531
524
|
|
|
@@ -679,12 +672,28 @@ function main() {
|
|
|
679
672
|
|
|
680
673
|
// Knowledge — git repo if available (has team-captured docs), else npm bundle
|
|
681
674
|
// .claude/knowledge/ is a mirror — update when content changes so teammates get captured docs
|
|
682
|
-
const knowledgeSrc = path.join(knowledgeDir, 'knowledge');
|
|
683
675
|
const knowledgeDest = path.join(claudeDir, 'knowledge');
|
|
684
676
|
let knowledgeStats = { added: 0, updated: 0, unchanged: 0 };
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
677
|
+
|
|
678
|
+
// Always install npm bundle knowledge first — this guarantees every file published
|
|
679
|
+
// in this version is present, regardless of what the git repo contains.
|
|
680
|
+
const bundleKnowledgeSrc = path.join(PACKAGE_ROOT, 'knowledge');
|
|
681
|
+
if (fs.existsSync(bundleKnowledgeSrc)) {
|
|
682
|
+
try { knowledgeStats = copyDir(bundleKnowledgeSrc, knowledgeDest, { updateIfChanged: true }); }
|
|
683
|
+
catch (e) { errors.push('knowledge (bundle): ' + e.message); }
|
|
684
|
+
}
|
|
685
|
+
|
|
686
|
+
// Then overlay git repo on top — picks up any docs newer than this npm bundle.
|
|
687
|
+
// Git is additive only: it never removes files the bundle already installed.
|
|
688
|
+
if (knowledgeDir !== PACKAGE_ROOT) {
|
|
689
|
+
const gitKnowledgeSrc = path.join(knowledgeDir, 'knowledge');
|
|
690
|
+
if (fs.existsSync(gitKnowledgeSrc)) {
|
|
691
|
+
try {
|
|
692
|
+
const gitStats = copyDir(gitKnowledgeSrc, knowledgeDest, { updateIfChanged: true });
|
|
693
|
+
knowledgeStats.added += gitStats.added;
|
|
694
|
+
knowledgeStats.updated += gitStats.updated;
|
|
695
|
+
} catch (e) { /* non-fatal — bundle layer already installed */ }
|
|
696
|
+
}
|
|
688
697
|
}
|
|
689
698
|
console.log(' ✓ Knowledge (' + countMd(knowledgeDest) + ' docs): ' + fmtStats(knowledgeStats));
|
|
690
699
|
|