@sylphx/flow 1.0.4 → 1.0.5
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 +6 -0
- package/package.json +1 -1
- package/src/commands/flow-orchestrator.ts +17 -10
- package/src/core/state-detector.ts +11 -2
package/CHANGELOG.md
CHANGED
package/package.json
CHANGED
|
@@ -99,22 +99,29 @@ export async function checkComponentIntegrity(
|
|
|
99
99
|
|
|
100
100
|
// Find missing components (target-aware)
|
|
101
101
|
const missing: string[] = [];
|
|
102
|
+
|
|
103
|
+
// Agents are always required
|
|
102
104
|
if (!state.components.agents.installed) missing.push('agents');
|
|
103
|
-
if (!state.components.rules.installed) missing.push('rules');
|
|
104
105
|
|
|
105
|
-
//
|
|
106
|
-
|
|
107
|
-
|
|
106
|
+
// For OpenCode: check rules (separate AGENTS.md file)
|
|
107
|
+
// For Claude Code: rules are included in agent files, so skip this check
|
|
108
|
+
if (state.target === 'opencode' && !state.components.rules.installed) {
|
|
109
|
+
missing.push('rules');
|
|
108
110
|
}
|
|
109
111
|
|
|
110
|
-
|
|
112
|
+
// Hooks are optional - don't check
|
|
113
|
+
// Claude Code can have hooks in .claude/hooks/*.js but they're optional
|
|
114
|
+
// OpenCode doesn't have separate hooks
|
|
111
115
|
|
|
112
|
-
//
|
|
113
|
-
if (
|
|
114
|
-
|
|
115
|
-
|
|
116
|
+
// MCP is optional now - many users don't use MCP
|
|
117
|
+
// if (!state.components.mcp.installed) missing.push('mcp');
|
|
118
|
+
|
|
119
|
+
// Output styles:
|
|
120
|
+
// - Claude Code: included in agent files, so skip check
|
|
121
|
+
// - OpenCode: included in AGENTS.md, so skip check
|
|
116
122
|
|
|
117
|
-
|
|
123
|
+
// Slash commands are optional
|
|
124
|
+
// if (!state.components.slashCommands.installed) missing.push('slash commands');
|
|
118
125
|
|
|
119
126
|
// If no missing components, we're good
|
|
120
127
|
if (missing.length === 0) return;
|
|
@@ -91,9 +91,18 @@ export class StateDetector {
|
|
|
91
91
|
} else {
|
|
92
92
|
// Claude Code (default)
|
|
93
93
|
await this.checkComponent('agents', '.claude/agents', '*.md', state);
|
|
94
|
-
|
|
94
|
+
|
|
95
|
+
// Claude Code includes rules and output styles in agent files
|
|
96
|
+
// So we mark them as installed if agents are installed
|
|
97
|
+
state.components.rules.installed = state.components.agents.installed;
|
|
98
|
+
state.components.rules.count = state.components.agents.count;
|
|
99
|
+
|
|
100
|
+
state.components.outputStyles.installed = state.components.agents.installed;
|
|
101
|
+
|
|
102
|
+
// Check hooks (optional for Claude Code)
|
|
95
103
|
await this.checkComponent('hooks', '.claude/hooks', '*.js', state);
|
|
96
|
-
|
|
104
|
+
|
|
105
|
+
// Check slash commands
|
|
97
106
|
await this.checkComponent('slashCommands', '.claude/commands', '*.md', state);
|
|
98
107
|
}
|
|
99
108
|
|