@sylphx/flow 1.4.0 → 1.4.1

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,14 @@
1
1
  # @sylphx/flow
2
2
 
3
+ ## 1.4.1
4
+
5
+ ### Patch Changes
6
+
7
+ - Fix rules scanning showing all project markdown files:
8
+ - Skip rules scanning for Claude Code (rules embedded in agent files)
9
+ - Only scan when target has explicit rulesFile config
10
+ - Prevent scanning entire project directory
11
+
3
12
  ## 1.4.0
4
13
 
5
14
  ### Minor Changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sylphx/flow",
3
- "version": "1.4.0",
3
+ "version": "1.4.1",
4
4
  "description": "AI-powered development workflow automation with autonomous loop mode and smart configuration",
5
5
  "type": "module",
6
6
  "bin": {
@@ -90,15 +90,28 @@ export async function buildSyncManifest(cwd: string, target: Target): Promise<Sy
90
90
  }
91
91
  }
92
92
 
93
- // Rules files - check individual files
94
- const rulesDir = path.dirname(target.config.rulesFile || '');
95
- if (rulesDir && fs.existsSync(path.join(cwd, rulesDir))) {
96
- const files = fs.readdirSync(path.join(cwd, rulesDir), { withFileTypes: true });
97
- const ruleFiles = files
98
- .filter((f) => f.isFile() && f.name.endsWith('.md'))
99
- .map((f) => path.join(cwd, rulesDir, f.name));
100
-
101
- manifest.rules = categorizeFiles(ruleFiles, FLOW_RULES);
93
+ // Rules files - only for targets with separate rules directory
94
+ // Claude Code has rules in agent files, so skip
95
+ if (target.config.rulesFile) {
96
+ const rulesPath = path.join(cwd, target.config.rulesFile);
97
+
98
+ // Check if it's a directory or file
99
+ if (fs.existsSync(rulesPath)) {
100
+ const stat = fs.statSync(rulesPath);
101
+
102
+ if (stat.isDirectory()) {
103
+ // Scan directory for rule files
104
+ const files = fs.readdirSync(rulesPath, { withFileTypes: true });
105
+ const ruleFiles = files
106
+ .filter((f) => f.isFile() && f.name.endsWith('.md'))
107
+ .map((f) => path.join(rulesPath, f.name));
108
+
109
+ manifest.rules = categorizeFiles(ruleFiles, FLOW_RULES);
110
+ } else {
111
+ // Single rules file - check if it matches Flow templates
112
+ manifest.rules = categorizeFiles([rulesPath], FLOW_RULES);
113
+ }
114
+ }
102
115
  }
103
116
 
104
117
  // MCP servers