@xn-intenton-z2a/agentic-lib 7.1.8 → 7.1.9

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.
Files changed (2) hide show
  1. package/bin/agentic-lib.js +14 -13
  2. package/package.json +1 -1
@@ -625,6 +625,19 @@ function initCopyDirRecursive(srcPath, dstPath, label, excludes = []) {
625
625
  }
626
626
  }
627
627
 
628
+ function removeStaleWorkflows(templateWorkflows) {
629
+ const KEEP = new Set(["init.yml"]);
630
+ const targetWorkflowsDir = resolve(target, ".github/workflows");
631
+ if (!existsSync(targetWorkflowsDir)) return;
632
+ for (const f of readdirSync(targetWorkflowsDir)) {
633
+ if (f.endsWith(".yml") && !templateWorkflows.has(f) && !KEEP.has(f)) {
634
+ if (!dryRun) rmSync(resolve(targetWorkflowsDir, f));
635
+ console.log(` REMOVE stale: workflows/${f}`);
636
+ initChanges++;
637
+ }
638
+ }
639
+ }
640
+
628
641
  function initWorkflows() {
629
642
  console.log("--- Workflows ---");
630
643
  const workflowsDir = resolve(srcDir, "workflows");
@@ -636,24 +649,12 @@ function initWorkflows() {
636
649
  initCopyFile(resolve(workflowsDir, f), resolve(target, ".github/workflows", f), `workflows/${f}`);
637
650
  }
638
651
  }
639
- // Also copy test.yml from seeds to workflows if it exists
640
652
  const seedTest = resolve(srcDir, "seeds/test.yml");
641
653
  if (existsSync(seedTest)) {
642
654
  templateWorkflows.add("test.yml");
643
655
  initCopyFile(seedTest, resolve(target, ".github/workflows/test.yml"), "workflows/test.yml (from seeds)");
644
656
  }
645
- // Delete stale workflows not in the template (skip init.yml — maintained by consumer)
646
- const KEEP = new Set(["init.yml"]);
647
- const targetWorkflowsDir = resolve(target, ".github/workflows");
648
- if (existsSync(targetWorkflowsDir)) {
649
- for (const f of readdirSync(targetWorkflowsDir)) {
650
- if (f.endsWith(".yml") && !templateWorkflows.has(f) && !KEEP.has(f)) {
651
- if (!dryRun) rmSync(resolve(targetWorkflowsDir, f));
652
- console.log(` REMOVE stale: workflows/${f}`);
653
- initChanges++;
654
- }
655
- }
656
- }
657
+ removeStaleWorkflows(templateWorkflows);
657
658
  }
658
659
 
659
660
  function initActions(agenticDir) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xn-intenton-z2a/agentic-lib",
3
- "version": "7.1.8",
3
+ "version": "7.1.9",
4
4
  "description": "Agentic-lib Agentic Coding Systems SDK powering automated GitHub workflows.",
5
5
  "type": "module",
6
6
  "scripts": {