@sulhadin/orchestrator 3.1.3 → 3.1.4

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/index.js CHANGED
@@ -231,7 +231,8 @@ function extractOrchestraSection(content) {
231
231
  /**
232
232
  * Smart merge for user directories (skills, rules, blueprints):
233
233
  * - entries present in template = system files → always updated from template
234
- * - entries not in template = user files → preserved
234
+ * - .orchestra.md files = legacy system files → skip (backward compat)
235
+ * - remaining entries = user files → preserved
235
236
  */
236
237
  function smartMergeDir(backupPath, restorePath, templateDirPath) {
237
238
  const templateFiles = fs.existsSync(templateDirPath)
@@ -241,16 +242,22 @@ function smartMergeDir(backupPath, restorePath, templateDirPath) {
241
242
  let restored = 0;
242
243
 
243
244
  for (const file of backupFiles) {
244
- // User-created entries: not in template preserve
245
- if (!templateFiles.includes(file)) {
246
- const srcFile = path.join(backupPath, file);
245
+ // Skip system entries: in template OR legacy .orchestra.md files
246
+ if (templateFiles.includes(file) || file.endsWith(".orchestra.md")) continue;
247
+
248
+ const srcFile = path.join(backupPath, file);
249
+ try {
250
+ const stat = fs.lstatSync(srcFile);
247
251
  const destFile = path.join(restorePath, file);
248
- if (fs.statSync(srcFile).isDirectory()) {
252
+ if (stat.isDirectory()) {
249
253
  copyDirRecursive(srcFile, destFile);
250
- } else {
254
+ } else if (stat.isFile()) {
251
255
  fs.copyFileSync(srcFile, destFile);
252
256
  }
257
+ // Skip broken symlinks and other non-regular entries
253
258
  restored++;
259
+ } catch {
260
+ // Entry inaccessible — skip silently
254
261
  }
255
262
  }
256
263
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sulhadin/orchestrator",
3
- "version": "3.1.3",
3
+ "version": "3.1.4",
4
4
  "description": "AI Team Orchestration System — multi-role coordination for Claude Code",
5
5
  "bin": "bin/index.js",
6
6
  "scripts": {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "orchestra",
3
3
  "description": "AI Team Orchestration — multi-role coordination with milestones, phases, and quality gates for Claude Code",
4
- "version": "3.1.3",
4
+ "version": "3.1.4",
5
5
  "author": {
6
6
  "name": "Sulhadin Öney"
7
7
  },