@sylphx/flow 3.13.1 → 3.13.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/CHANGELOG.md CHANGED
@@ -1,5 +1,23 @@
1
1
  # @sylphx/flow
2
2
 
3
+ ## 3.13.4 (2026-02-04)
4
+
5
+ ### ♻️ Refactoring
6
+
7
+ - **builder:** replace Radix UI with Base UI in tech stack ([a4e81df](https://github.com/SylphxAI/flow/commit/a4e81dfcd382030e99c49fe60082aafe033e3981))
8
+
9
+ ## 3.13.3 (2026-02-04)
10
+
11
+ ### ♻️ Refactoring
12
+
13
+ - **builder:** replace Radix UI with Base UI in tech stack ([a4e81df](https://github.com/SylphxAI/flow/commit/a4e81dfcd382030e99c49fe60082aafe033e3981))
14
+
15
+ ## 3.13.2 (2026-02-04)
16
+
17
+ ### ♻️ Refactoring
18
+
19
+ - **builder:** replace tRPC with Hono + zod-openapi + hc ([330060b](https://github.com/SylphxAI/flow/commit/330060bc164def0e049db514f8361a6cfd1c2146))
20
+
3
21
  ## 3.13.1 (2026-02-04)
4
22
 
5
23
  ### ⚡️ Performance
@@ -46,11 +46,11 @@ State-of-the-art industrial standard. Every time. Would you stake your reputatio
46
46
 
47
47
  **Framework & Runtime:** Next.js 16+, React, Bun
48
48
 
49
- **Data & API:** tRPC (internal), Hono + @hono/zod-openapi (external REST), React Query, Drizzle ORM
49
+ **Data & API:** Hono + @hono/zod-openapi + hc (type-safe client), React Query, Drizzle ORM
50
50
 
51
51
  **Database & Infrastructure:** Neon PostgreSQL, Upstash Workflow, Vercel, Vercel Blob, Modal (serverless long-running)
52
52
 
53
- **UI & Styling:** Radix UI, Tailwind CSS v4 (CSS-first), Motion v12 (animation)
53
+ **UI & Styling:** Base UI, Tailwind CSS v4 (CSS-first), Motion v12 (animation)
54
54
 
55
55
  **AI:** AI SDK v6+
56
56
 
@@ -110,7 +110,7 @@ State-of-the-art industrial standard. Every time. Would you stake your reputatio
110
110
  ## Engineering
111
111
 
112
112
  - **Single Source of Truth** — one authoritative source for every state, behavior, and decision
113
- - **Type safety** — end-to-end across all boundaries (tRPC, Zod, strict TypeScript)
113
+ - **Type safety** — end-to-end across all boundaries (Hono RPC, Zod, strict TypeScript)
114
114
  - **Pure functions** — no side effects, deterministic output; isolate impure code at boundaries
115
115
  - **Decoupling** — minimize dependencies, use interfaces and dependency injection
116
116
  - **Modularisation** — single responsibility, clear boundaries, independent deployability
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sylphx/flow",
3
- "version": "3.13.1",
3
+ "version": "3.13.4",
4
4
  "description": "One CLI to rule them all. Unified orchestration layer for AI coding assistants. Auto-detection, auto-installation, auto-upgrade.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -114,10 +114,14 @@ export class TemplateLoader {
114
114
  const domainPath = path.join(skillsDir, domain);
115
115
  const stat = await fs.stat(domainPath);
116
116
 
117
- if (!stat.isDirectory()) return null;
117
+ if (!stat.isDirectory()) {
118
+ return null;
119
+ }
118
120
 
119
121
  const skillFile = path.join(domainPath, 'SKILL.md');
120
- if (!existsSync(skillFile)) return null;
122
+ if (!existsSync(skillFile)) {
123
+ return null;
124
+ }
121
125
 
122
126
  const content = await fs.readFile(skillFile, 'utf-8');
123
127
  return { name: `${domain}/SKILL.md`, content };
@@ -155,7 +159,9 @@ export class TemplateLoader {
155
159
  const filePath = path.join(singleFilesDir, entry);
156
160
  const stat = await fs.stat(filePath);
157
161
 
158
- if (!stat.isFile()) return null;
162
+ if (!stat.isFile()) {
163
+ return null;
164
+ }
159
165
 
160
166
  const content = await fs.readFile(filePath, 'utf-8');
161
167
  return { path: entry, content };
package/src/index.ts CHANGED
@@ -5,6 +5,8 @@
5
5
  */
6
6
 
7
7
  import { Command } from 'commander';
8
+ // @ts-expect-error - Bun resolves JSON imports
9
+ import pkg from '../package.json';
8
10
  import { executeFlow } from './commands/flow/execute-v2.js';
9
11
  import {
10
12
  doctorCommand,
@@ -17,8 +19,6 @@ import {
17
19
  import { hookCommand } from './commands/hook-command.js';
18
20
  import { settingsCommand } from './commands/settings-command.js';
19
21
  import { UserCancelledError } from './utils/errors.js';
20
- // @ts-expect-error - Bun resolves JSON imports
21
- import pkg from '../package.json';
22
22
 
23
23
  const VERSION = pkg.version;
24
24
 
@@ -79,7 +79,9 @@ export class AutoUpgrade {
79
79
  private async shouldCheck(intervalMs: number): Promise<boolean> {
80
80
  try {
81
81
  const info = await this.readVersionInfo();
82
- if (!info?.lastCheckTime) return true;
82
+ if (!info?.lastCheckTime) {
83
+ return true;
84
+ }
83
85
  return Date.now() - info.lastCheckTime >= intervalMs;
84
86
  } catch {
85
87
  return true;
@@ -111,7 +113,9 @@ export class AutoUpgrade {
111
113
  lastCheckTime: Date.now(),
112
114
  });
113
115
 
114
- if (!latestVersion) return;
116
+ if (!latestVersion) {
117
+ return;
118
+ }
115
119
 
116
120
  // Upgrade if newer version available
117
121
  if (latestVersion !== currentVersion) {
@@ -152,9 +156,15 @@ export class AutoUpgrade {
152
156
  const { stdout } = await execAsync('which flow || where flow');
153
157
  const flowPath = stdout.trim().toLowerCase();
154
158
 
155
- if (flowPath.includes('bun')) return 'bun';
156
- if (flowPath.includes('pnpm')) return 'pnpm';
157
- if (flowPath.includes('yarn')) return 'yarn';
159
+ if (flowPath.includes('bun')) {
160
+ return 'bun';
161
+ }
162
+ if (flowPath.includes('pnpm')) {
163
+ return 'pnpm';
164
+ }
165
+ if (flowPath.includes('yarn')) {
166
+ return 'yarn';
167
+ }
158
168
  } catch {
159
169
  // Fall through
160
170
  }
@@ -1,8 +1,8 @@
1
1
  import fs from 'node:fs/promises';
2
2
  import path from 'node:path';
3
3
  import { parse as parseYaml, stringify as stringifyYaml } from 'yaml';
4
- import type { MCPServerConfigUnion, TargetConfig } from '../../types.js';
5
4
  import type { FrontMatterMetadata } from '../../types/target-config.types.js';
5
+ import type { MCPServerConfigUnion, TargetConfig } from '../../types.js';
6
6
  import { readJSONCFile, writeJSONCFile } from '../files/jsonc.js';
7
7
  import { pathSecurity, sanitize } from '../security/security.js';
8
8
 
@@ -95,7 +95,9 @@ export const fileUtils = {
95
95
  * YAML utilities for targets
96
96
  */
97
97
  export const yamlUtils = {
98
- async extractFrontMatter(content: string): Promise<{ metadata: FrontMatterMetadata; content: string }> {
98
+ async extractFrontMatter(
99
+ content: string
100
+ ): Promise<{ metadata: FrontMatterMetadata; content: string }> {
99
101
  const yamlRegex = /^---\s*\n([\s\S]*?)\n---\s*\n([\s\S]*)$/;
100
102
  const match = content.match(yamlRegex);
101
103
 
@@ -140,7 +142,10 @@ export const yamlUtils = {
140
142
  return yamlRegex.test(content);
141
143
  },
142
144
 
143
- async ensureFrontMatter(content: string, defaultMetadata: FrontMatterMetadata = {}): Promise<string> {
145
+ async ensureFrontMatter(
146
+ content: string,
147
+ defaultMetadata: FrontMatterMetadata = {}
148
+ ): Promise<string> {
144
149
  if (yamlUtils.hasValidFrontMatter(content)) {
145
150
  return content;
146
151
  }
@@ -161,7 +166,10 @@ export const yamlUtils = {
161
166
  return metadata || {};
162
167
  },
163
168
 
164
- async updateAgentMetadata(content: string, updates: Partial<FrontMatterMetadata>): Promise<string> {
169
+ async updateAgentMetadata(
170
+ content: string,
171
+ updates: Partial<FrontMatterMetadata>
172
+ ): Promise<string> {
165
173
  const { metadata: existingMetadata, content: baseContent } =
166
174
  await yamlUtils.extractFrontMatter(content);
167
175
  const updatedMetadata = { ...existingMetadata, ...updates };