fix(.claude/): resolve npm install failure for claude-dir-installer

Fixes issue where npm install -g or ccs update would fail to copy
.claude/ directory to ~/.ccs/.claude/, causing symlink installation
errors. ClaudeDirInstaller now ensures source exists before
ClaudeSymlinkManager attempts linking.
This commit is contained in:
kaitranntt
2025-11-16 06:48:39 -05:00
parent fb3deeff38
commit d8645c71e4
9 changed files with 125 additions and 6 deletions
+11
View File
@@ -103,6 +103,17 @@ function createConfigFiles() {
}
console.log('');
// Copy .claude/ directory from package to ~/.ccs/.claude/ (v4.1.1)
try {
const ClaudeDirInstaller = require('../bin/utils/claude-dir-installer');
const installer = new ClaudeDirInstaller();
const packageDir = path.join(__dirname, '..');
installer.install(packageDir);
} catch (err) {
console.warn('[!] Failed to install .claude/ directory:', err.message);
console.warn(' CCS items may not be available');
}
// Install CCS items to ~/.claude/ (v4.1.0)
try {
const ClaudeSymlinkManager = require('../bin/utils/claude-symlink-manager');