@yemi33/minions 0.1.583 → 0.1.584

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/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.1.584 (2026-04-08)
4
+
5
+ ### Fixes
6
+ - add conditional block support to playbook renderer
7
+
3
8
  ## 0.1.583 (2026-04-08)
4
9
 
5
10
  ### Fixes
@@ -283,6 +283,12 @@ function renderPlaybook(type, vars) {
283
283
  };
284
284
  const allVars = { ...projectVars, ...vars };
285
285
 
286
+ // Process conditional blocks: {{#key}}...{{/key}} — include block only if key is truthy
287
+ content = content.replace(/\{\{#(\w+)\}\}([\s\S]*?)\{\{\/\1\}\}/g, (_, key, block) => {
288
+ const val = allVars[key];
289
+ return (val && String(val).trim()) ? block : '';
290
+ });
291
+
286
292
  // Substitute variables
287
293
  for (const [key, val] of Object.entries(allVars)) {
288
294
  content = content.replace(new RegExp(`\\{\\{${key}\\}\\}`, 'g'), String(val));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yemi33/minions",
3
- "version": "0.1.583",
3
+ "version": "0.1.584",
4
4
  "description": "Multi-agent AI dev team that runs from ~/.minions/ — five autonomous agents share a single engine, dashboard, and knowledge base",
5
5
  "bin": {
6
6
  "minions": "bin/minions.js"