@rolexjs/local-platform 0.4.0 → 0.5.0

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/dist/index.d.ts CHANGED
@@ -29,6 +29,9 @@ declare class LocalPlatform implements Platform {
29
29
  plan: Plan | null;
30
30
  tasks: Task[];
31
31
  }) | null;
32
+ allActiveGoals(roleId: string): Goal[];
33
+ getFocusedGoal(roleId: string): string | null;
34
+ setFocusedGoal(roleId: string, name: string): void;
32
35
  createGoal(roleId: string, name: string, source: string, testable?: boolean): Goal;
33
36
  createPlan(roleId: string, source: string): Plan;
34
37
  createTask(roleId: string, name: string, source: string, testable?: boolean): Task;
@@ -38,6 +41,7 @@ declare class LocalPlatform implements Platform {
38
41
  private loadConfig;
39
42
  private saveConfig;
40
43
  private resolveRoleDir;
44
+ private loadGoalIfActive;
41
45
  private getActiveGoalDir;
42
46
  private toFeature;
43
47
  private extractScenarios;
package/dist/index.js CHANGED
@@ -96,7 +96,26 @@ var LocalPlatform = class {
96
96
  const roleDir = this.resolveRoleDir(roleId);
97
97
  const goalsDir = join(roleDir, "goals");
98
98
  if (!existsSync(goalsDir)) return null;
99
+ const focusedName = this.getFocusedGoal(roleId);
100
+ if (focusedName) {
101
+ const goalDir = join(goalsDir, focusedName);
102
+ const result = this.loadGoalIfActive(goalDir);
103
+ if (result) return result;
104
+ }
99
105
  const goalDirs = readdirSync(goalsDir, { withFileTypes: true }).filter((d) => d.isDirectory()).map((d) => d.name).sort();
106
+ for (const goalName of goalDirs) {
107
+ const goalDir = join(goalsDir, goalName);
108
+ const result = this.loadGoalIfActive(goalDir);
109
+ if (result) return result;
110
+ }
111
+ return null;
112
+ }
113
+ allActiveGoals(roleId) {
114
+ const roleDir = this.resolveRoleDir(roleId);
115
+ const goalsDir = join(roleDir, "goals");
116
+ if (!existsSync(goalsDir)) return [];
117
+ const goalDirs = readdirSync(goalsDir, { withFileTypes: true }).filter((d) => d.isDirectory()).map((d) => d.name).sort();
118
+ const goals = [];
100
119
  for (const goalName of goalDirs) {
101
120
  const goalDir = join(goalsDir, goalName);
102
121
  const goalFile = this.findFeatureFile(goalDir, ".goal.feature");
@@ -105,14 +124,24 @@ var LocalPlatform = class {
105
124
  const doc = parse(source);
106
125
  if (!doc.feature) continue;
107
126
  if (doc.feature.tags.some((t) => t.name === "@done" || t.name === "@abandoned")) continue;
108
- const goal = this.toFeature(doc.feature, "goal");
109
- return {
110
- ...goal,
111
- plan: this.loadPlan(goalDir),
112
- tasks: this.loadTasks(goalDir)
113
- };
127
+ goals.push(this.toFeature(doc.feature, "goal"));
114
128
  }
115
- return null;
129
+ return goals;
130
+ }
131
+ getFocusedGoal(roleId) {
132
+ const roleDir = this.resolveRoleDir(roleId);
133
+ const focusFile = join(roleDir, "goals", ".focus");
134
+ if (!existsSync(focusFile)) return null;
135
+ return readFileSync(focusFile, "utf-8").trim() || null;
136
+ }
137
+ setFocusedGoal(roleId, name) {
138
+ const roleDir = this.resolveRoleDir(roleId);
139
+ const goalsDir = join(roleDir, "goals");
140
+ const goalDir = join(goalsDir, name);
141
+ if (!existsSync(goalDir)) {
142
+ throw new Error(`Goal not found: ${name}`);
143
+ }
144
+ writeFileSync(join(goalsDir, ".focus"), name, "utf-8");
116
145
  }
117
146
  // ========== Write ==========
118
147
  createGoal(roleId, name, source, testable) {
@@ -202,18 +231,37 @@ ${source}`;
202
231
  }
203
232
  return roleDir;
204
233
  }
234
+ loadGoalIfActive(goalDir) {
235
+ const goalFile = this.findFeatureFile(goalDir, ".goal.feature");
236
+ if (!goalFile) return null;
237
+ const source = readFileSync(goalFile, "utf-8");
238
+ const doc = parse(source);
239
+ if (!doc.feature) return null;
240
+ if (doc.feature.tags.some((t) => t.name === "@done" || t.name === "@abandoned")) return null;
241
+ const goal = this.toFeature(doc.feature, "goal");
242
+ return {
243
+ ...goal,
244
+ plan: this.loadPlan(goalDir),
245
+ tasks: this.loadTasks(goalDir)
246
+ };
247
+ }
205
248
  getActiveGoalDir(roleDir) {
206
249
  const goalsDir = join(roleDir, "goals");
207
250
  if (!existsSync(goalsDir)) return null;
251
+ const focusFile = join(goalsDir, ".focus");
252
+ if (existsSync(focusFile)) {
253
+ const focusedName = readFileSync(focusFile, "utf-8").trim();
254
+ if (focusedName) {
255
+ const focusedDir = join(goalsDir, focusedName);
256
+ if (existsSync(focusedDir) && this.loadGoalIfActive(focusedDir)) {
257
+ return focusedDir;
258
+ }
259
+ }
260
+ }
208
261
  const goalDirs = readdirSync(goalsDir, { withFileTypes: true }).filter((d) => d.isDirectory()).map((d) => d.name).sort();
209
262
  for (const goalName of goalDirs) {
210
263
  const goalDir = join(goalsDir, goalName);
211
- const goalFile = this.findFeatureFile(goalDir, ".goal.feature");
212
- if (!goalFile) continue;
213
- const source = readFileSync(goalFile, "utf-8");
214
- const doc = parse(source);
215
- if (!doc.feature) continue;
216
- if (!doc.feature.tags.some((t) => t.name === "@done" || t.name === "@abandoned")) {
264
+ if (this.loadGoalIfActive(goalDir)) {
217
265
  return goalDir;
218
266
  }
219
267
  }
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/LocalPlatform.ts"],"sourcesContent":["/**\n * LocalPlatform — Local filesystem implementation of Platform.\n *\n * Everything lives under a single .rolex/ directory.\n * rolex.json manages organization relationships (including teams).\n *\n * Directory convention:\n * <rootDir>/rolex.json ← Organization config\n * <rootDir>/<role>/identity/*.identity.feature ← Identity features\n * <rootDir>/<role>/goals/<name>/<name>.goal.feature\n * <rootDir>/<role>/goals/<name>/<name>.plan.feature\n * <rootDir>/<role>/goals/<name>/tasks/<name>.task.feature\n */\n\nimport { readdirSync, readFileSync, writeFileSync, mkdirSync, existsSync, rmSync } from \"node:fs\";\nimport { join, basename } from \"node:path\";\nimport { parse } from \"@rolexjs/parser\";\nimport type { Feature as GherkinFeature } from \"@rolexjs/parser\";\nimport type {\n Platform,\n Organization,\n RoleEntry,\n Feature,\n Scenario,\n Goal,\n Plan,\n Task,\n} from \"@rolexjs/core\";\n\ninterface RolexConfig {\n name: string;\n teams: Record<string, string[]>;\n}\n\nexport class LocalPlatform implements Platform {\n private readonly rootDir: string;\n private config: RolexConfig | null = null;\n\n constructor(rootDir: string) {\n this.rootDir = rootDir;\n }\n\n // ========== Found ==========\n\n found(name: string): void {\n mkdirSync(this.rootDir, { recursive: true });\n\n const config: RolexConfig = {\n name,\n teams: { default: [] },\n };\n\n this.saveConfig(config);\n }\n\n // ========== Organization ==========\n\n organization(): Organization {\n const config = this.loadConfig();\n const roles: RoleEntry[] = [];\n\n for (const [teamName, roleNames] of Object.entries(config.teams)) {\n for (const roleName of roleNames) {\n roles.push({\n name: roleName,\n team: teamName,\n });\n }\n }\n\n return { name: config.name, roles };\n }\n\n // ========== Born ==========\n\n born(name: string, source: string): Feature {\n const roleDir = join(this.rootDir, name);\n const identityDir = join(roleDir, \"identity\");\n mkdirSync(identityDir, { recursive: true });\n\n const filePath = join(identityDir, \"persona.identity.feature\");\n writeFileSync(filePath, source, \"utf-8\");\n\n const doc = parse(source);\n return this.toFeature(doc.feature!, \"persona\");\n }\n\n hire(name: string): void {\n const roleDir = join(this.rootDir, name);\n\n if (!existsSync(join(roleDir, \"identity\", \"persona.identity.feature\"))) {\n throw new Error(`Role not found: ${name}. Call born() first.`);\n }\n\n mkdirSync(join(roleDir, \"goals\"), { recursive: true });\n\n // Update rolex.json — add role to default team\n const config = this.loadConfig();\n const [firstTeam] = Object.keys(config.teams);\n if (!config.teams[firstTeam].includes(name)) {\n config.teams[firstTeam].push(name);\n this.saveConfig(config);\n }\n }\n\n fire(name: string): void {\n const roleDir = join(this.rootDir, name);\n const goalsDir = join(roleDir, \"goals\");\n\n if (!existsSync(goalsDir)) {\n throw new Error(`Role not hired: ${name}`);\n }\n\n rmSync(goalsDir, { recursive: true, force: true });\n\n // Update rolex.json — remove role from team\n const config = this.loadConfig();\n for (const teamName of Object.keys(config.teams)) {\n const idx = config.teams[teamName].indexOf(name);\n if (idx !== -1) {\n config.teams[teamName].splice(idx, 1);\n break;\n }\n }\n this.saveConfig(config);\n }\n\n // ========== Growup ==========\n\n growup(\n roleId: string,\n type: \"knowledge\" | \"experience\" | \"voice\",\n name: string,\n source: string\n ): Feature {\n const roleDir = this.resolveRoleDir(roleId);\n const dir = join(roleDir, \"identity\");\n mkdirSync(dir, { recursive: true });\n\n const filePath = join(dir, `${name}.${type}.identity.feature`);\n writeFileSync(filePath, source, \"utf-8\");\n\n const doc = parse(source);\n return this.toFeature(doc.feature!, type);\n }\n\n // ========== Query ==========\n\n identity(roleId: string): Feature[] {\n const roleDir = this.resolveRoleDir(roleId);\n const dir = join(roleDir, \"identity\");\n if (!existsSync(dir)) return [];\n\n return readdirSync(dir)\n .filter((f) => f.endsWith(\".identity.feature\"))\n .sort()\n .map((f) => {\n const source = readFileSync(join(dir, f), \"utf-8\");\n const doc = parse(source);\n return this.toFeature(doc.feature!, this.detectIdentityType(f));\n });\n }\n\n activeGoal(roleId: string): (Goal & { plan: Plan | null; tasks: Task[] }) | null {\n const roleDir = this.resolveRoleDir(roleId);\n const goalsDir = join(roleDir, \"goals\");\n if (!existsSync(goalsDir)) return null;\n\n const goalDirs = readdirSync(goalsDir, { withFileTypes: true })\n .filter((d) => d.isDirectory())\n .map((d) => d.name)\n .sort();\n\n for (const goalName of goalDirs) {\n const goalDir = join(goalsDir, goalName);\n const goalFile = this.findFeatureFile(goalDir, \".goal.feature\");\n if (!goalFile) continue;\n\n const source = readFileSync(goalFile, \"utf-8\");\n const doc = parse(source);\n if (!doc.feature) continue;\n\n if (doc.feature.tags.some((t) => t.name === \"@done\" || t.name === \"@abandoned\")) continue;\n\n const goal = this.toFeature(doc.feature, \"goal\") as Goal;\n return {\n ...goal,\n plan: this.loadPlan(goalDir),\n tasks: this.loadTasks(goalDir),\n };\n }\n\n return null;\n }\n\n // ========== Write ==========\n\n createGoal(roleId: string, name: string, source: string, testable?: boolean): Goal {\n const roleDir = this.resolveRoleDir(roleId);\n const goalDir = join(roleDir, \"goals\", name);\n mkdirSync(goalDir, { recursive: true });\n\n if (testable) source = `@testable\\n${source}`;\n const filePath = join(goalDir, `${name}.goal.feature`);\n writeFileSync(filePath, source, \"utf-8\");\n\n const doc = parse(source);\n return this.toFeature(doc.feature!, \"goal\") as Goal;\n }\n\n createPlan(roleId: string, source: string): Plan {\n const roleDir = this.resolveRoleDir(roleId);\n const goalDir = this.getActiveGoalDir(roleDir);\n if (!goalDir) throw new Error(\"No active goal\");\n\n const goalName = basename(goalDir);\n const filePath = join(goalDir, `${goalName}.plan.feature`);\n writeFileSync(filePath, source, \"utf-8\");\n\n const doc = parse(source);\n return this.toFeature(doc.feature!, \"plan\") as Plan;\n }\n\n createTask(roleId: string, name: string, source: string, testable?: boolean): Task {\n const roleDir = this.resolveRoleDir(roleId);\n const goalDir = this.getActiveGoalDir(roleDir);\n if (!goalDir) throw new Error(\"No active goal\");\n\n const tasksDir = join(goalDir, \"tasks\");\n mkdirSync(tasksDir, { recursive: true });\n\n if (testable) source = `@testable\\n${source}`;\n const filePath = join(tasksDir, `${name}.task.feature`);\n writeFileSync(filePath, source, \"utf-8\");\n\n const doc = parse(source);\n return this.toFeature(doc.feature!, \"task\") as Task;\n }\n\n // ========== Close ==========\n\n completeGoal(roleId: string, experience?: string): void {\n const roleDir = this.resolveRoleDir(roleId);\n const goalDir = this.getActiveGoalDir(roleDir);\n if (!goalDir) throw new Error(\"No active goal\");\n\n const goalFile = this.findFeatureFile(goalDir, \".goal.feature\")!;\n this.addDoneTag(goalFile);\n\n if (experience) {\n const goalName = basename(goalDir);\n this.growup(roleId, \"experience\", goalName, experience);\n }\n }\n\n abandonGoal(roleId: string, experience?: string): void {\n const roleDir = this.resolveRoleDir(roleId);\n const goalDir = this.getActiveGoalDir(roleDir);\n if (!goalDir) throw new Error(\"No active goal\");\n\n const goalFile = this.findFeatureFile(goalDir, \".goal.feature\")!;\n this.addTag(goalFile, \"@abandoned\");\n\n if (experience) {\n const goalName = basename(goalDir);\n this.growup(roleId, \"experience\", goalName, experience);\n }\n }\n\n completeTask(roleId: string, name: string): void {\n const roleDir = this.resolveRoleDir(roleId);\n const goalDir = this.getActiveGoalDir(roleDir);\n if (!goalDir) throw new Error(\"No active goal\");\n\n const tasksDir = join(goalDir, \"tasks\");\n const taskFile = join(tasksDir, `${name}.task.feature`);\n if (!existsSync(taskFile)) throw new Error(`Task not found: ${name}`);\n\n this.addDoneTag(taskFile);\n }\n\n // ========== Internal ==========\n\n private loadConfig(): RolexConfig {\n if (this.config) return this.config;\n\n const configPath = join(this.rootDir, \"rolex.json\");\n if (existsSync(configPath)) {\n this.config = JSON.parse(readFileSync(configPath, \"utf-8\"));\n return this.config!;\n }\n\n throw new Error(`No rolex.json found in ${this.rootDir}. Call found() first.`);\n }\n\n private saveConfig(config: RolexConfig): void {\n writeFileSync(join(this.rootDir, \"rolex.json\"), JSON.stringify(config, null, 2), \"utf-8\");\n this.config = config;\n }\n\n private resolveRoleDir(roleId: string): string {\n const roleDir = join(this.rootDir, roleId);\n if (!existsSync(roleDir)) {\n throw new Error(`Role directory not found: ${roleDir}`);\n }\n return roleDir;\n }\n\n private getActiveGoalDir(roleDir: string): string | null {\n const goalsDir = join(roleDir, \"goals\");\n if (!existsSync(goalsDir)) return null;\n\n const goalDirs = readdirSync(goalsDir, { withFileTypes: true })\n .filter((d) => d.isDirectory())\n .map((d) => d.name)\n .sort();\n\n for (const goalName of goalDirs) {\n const goalDir = join(goalsDir, goalName);\n const goalFile = this.findFeatureFile(goalDir, \".goal.feature\");\n if (!goalFile) continue;\n\n const source = readFileSync(goalFile, \"utf-8\");\n const doc = parse(source);\n if (!doc.feature) continue;\n\n if (!doc.feature.tags.some((t) => t.name === \"@done\" || t.name === \"@abandoned\")) {\n return goalDir;\n }\n }\n\n return null;\n }\n\n private toFeature(gherkin: GherkinFeature, type: Feature[\"type\"]): Feature {\n return {\n ...gherkin,\n type,\n scenarios: this.extractScenarios(gherkin),\n };\n }\n\n private extractScenarios(feature: GherkinFeature): Scenario[] {\n const featureTestable = feature.tags.some((t) => t.name === \"@testable\");\n return (feature.children || [])\n .filter((c) => c.scenario)\n .map((c) => ({\n ...c.scenario!,\n verifiable: featureTestable || c.scenario!.tags.some((t) => t.name === \"@testable\"),\n }));\n }\n\n private loadPlan(goalDir: string): Plan | null {\n const planFile = this.findFeatureFile(goalDir, \".plan.feature\");\n if (!planFile) return null;\n\n const source = readFileSync(planFile, \"utf-8\");\n const doc = parse(source);\n if (!doc.feature) return null;\n\n return this.toFeature(doc.feature, \"plan\") as Plan;\n }\n\n private loadTasks(goalDir: string): Task[] {\n const tasksDir = join(goalDir, \"tasks\");\n if (!existsSync(tasksDir)) return [];\n\n return readdirSync(tasksDir)\n .filter((f) => f.endsWith(\".task.feature\"))\n .sort()\n .map((f) => {\n const source = readFileSync(join(tasksDir, f), \"utf-8\");\n const doc = parse(source);\n return this.toFeature(doc.feature!, \"task\") as Task;\n });\n }\n\n private detectIdentityType(filename: string): Feature[\"type\"] {\n if (filename === \"persona.identity.feature\") return \"persona\";\n if (filename.endsWith(\".knowledge.identity.feature\")) return \"knowledge\";\n if (filename.endsWith(\".experience.identity.feature\")) return \"experience\";\n if (filename.endsWith(\".voice.identity.feature\")) return \"voice\";\n return \"knowledge\";\n }\n\n private findFeatureFile(dir: string, suffix: string): string | null {\n if (!existsSync(dir)) return null;\n const file = readdirSync(dir).find((f) => f.endsWith(suffix));\n return file ? join(dir, file) : null;\n }\n\n private addTag(filePath: string, tag: string): void {\n const content = readFileSync(filePath, \"utf-8\");\n const updated = content.replace(/^(Feature:)/m, `${tag}\\n$1`);\n writeFileSync(filePath, updated, \"utf-8\");\n }\n\n private addDoneTag(filePath: string): void {\n this.addTag(filePath, \"@done\");\n }\n}\n"],"mappings":";AAcA,SAAS,aAAa,cAAc,eAAe,WAAW,YAAY,cAAc;AACxF,SAAS,MAAM,gBAAgB;AAC/B,SAAS,aAAa;AAkBf,IAAM,gBAAN,MAAwC;AAAA,EAC5B;AAAA,EACT,SAA6B;AAAA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AAU,OAAO;AAC9C,UAAM,UAAU,QAAQ,QAAQ,gBAAgB,GAAG,GAAG;AAAA,GAAM;AAC5D,kBAAc,UAAU,SAAS,OAAO;AAAA,EAC1C;AAAA,EAEQ,WAAW,UAAwB;AACzC,SAAK,OAAO,UAAU,OAAO;AAAA,EAC/B;AACF;","names":[]}
1
+ {"version":3,"sources":["../src/LocalPlatform.ts"],"sourcesContent":["/**\n * LocalPlatform — Local filesystem implementation of Platform.\n *\n * Everything lives under a single .rolex/ directory.\n * rolex.json manages organization relationships (including teams).\n *\n * Directory convention:\n * <rootDir>/rolex.json ← Organization config\n * <rootDir>/<role>/identity/*.identity.feature ← Identity features\n * <rootDir>/<role>/goals/<name>/<name>.goal.feature\n * <rootDir>/<role>/goals/<name>/<name>.plan.feature\n * <rootDir>/<role>/goals/<name>/tasks/<name>.task.feature\n */\n\nimport { readdirSync, readFileSync, writeFileSync, mkdirSync, existsSync, rmSync } from \"node:fs\";\nimport { join, basename } from \"node:path\";\nimport { parse } from \"@rolexjs/parser\";\nimport type { Feature as GherkinFeature } from \"@rolexjs/parser\";\nimport type {\n Platform,\n Organization,\n RoleEntry,\n Feature,\n Scenario,\n Goal,\n Plan,\n Task,\n} from \"@rolexjs/core\";\n\ninterface RolexConfig {\n name: string;\n teams: Record<string, string[]>;\n}\n\nexport class LocalPlatform implements Platform {\n private readonly rootDir: string;\n private config: RolexConfig | null = null;\n\n constructor(rootDir: string) {\n this.rootDir = rootDir;\n }\n\n // ========== Found ==========\n\n found(name: string): void {\n mkdirSync(this.rootDir, { recursive: true });\n\n const config: RolexConfig = {\n name,\n teams: { default: [] },\n };\n\n this.saveConfig(config);\n }\n\n // ========== Organization ==========\n\n organization(): Organization {\n const config = this.loadConfig();\n const roles: RoleEntry[] = [];\n\n for (const [teamName, roleNames] of Object.entries(config.teams)) {\n for (const roleName of roleNames) {\n roles.push({\n name: roleName,\n team: teamName,\n });\n }\n }\n\n return { name: config.name, roles };\n }\n\n // ========== Born ==========\n\n born(name: string, source: string): Feature {\n const roleDir = join(this.rootDir, name);\n const identityDir = join(roleDir, \"identity\");\n mkdirSync(identityDir, { recursive: true });\n\n const filePath = join(identityDir, \"persona.identity.feature\");\n writeFileSync(filePath, source, \"utf-8\");\n\n const doc = parse(source);\n return this.toFeature(doc.feature!, \"persona\");\n }\n\n hire(name: string): void {\n const roleDir = join(this.rootDir, name);\n\n if (!existsSync(join(roleDir, \"identity\", \"persona.identity.feature\"))) {\n throw new Error(`Role not found: ${name}. Call born() first.`);\n }\n\n mkdirSync(join(roleDir, \"goals\"), { recursive: true });\n\n // Update rolex.json — add role to default team\n const config = this.loadConfig();\n const [firstTeam] = Object.keys(config.teams);\n if (!config.teams[firstTeam].includes(name)) {\n config.teams[firstTeam].push(name);\n this.saveConfig(config);\n }\n }\n\n fire(name: string): void {\n const roleDir = join(this.rootDir, name);\n const goalsDir = join(roleDir, \"goals\");\n\n if (!existsSync(goalsDir)) {\n throw new Error(`Role not hired: ${name}`);\n }\n\n rmSync(goalsDir, { recursive: true, force: true });\n\n // Update rolex.json — remove role from team\n const config = this.loadConfig();\n for (const teamName of Object.keys(config.teams)) {\n const idx = config.teams[teamName].indexOf(name);\n if (idx !== -1) {\n config.teams[teamName].splice(idx, 1);\n break;\n }\n }\n this.saveConfig(config);\n }\n\n // ========== Growup ==========\n\n growup(\n roleId: string,\n type: \"knowledge\" | \"experience\" | \"voice\",\n name: string,\n source: string\n ): Feature {\n const roleDir = this.resolveRoleDir(roleId);\n const dir = join(roleDir, \"identity\");\n mkdirSync(dir, { recursive: true });\n\n const filePath = join(dir, `${name}.${type}.identity.feature`);\n writeFileSync(filePath, source, \"utf-8\");\n\n const doc = parse(source);\n return this.toFeature(doc.feature!, type);\n }\n\n // ========== Query ==========\n\n identity(roleId: string): Feature[] {\n const roleDir = this.resolveRoleDir(roleId);\n const dir = join(roleDir, \"identity\");\n if (!existsSync(dir)) return [];\n\n return readdirSync(dir)\n .filter((f) => f.endsWith(\".identity.feature\"))\n .sort()\n .map((f) => {\n const source = readFileSync(join(dir, f), \"utf-8\");\n const doc = parse(source);\n return this.toFeature(doc.feature!, this.detectIdentityType(f));\n });\n }\n\n activeGoal(roleId: string): (Goal & { plan: Plan | null; tasks: Task[] }) | null {\n const roleDir = this.resolveRoleDir(roleId);\n const goalsDir = join(roleDir, \"goals\");\n if (!existsSync(goalsDir)) return null;\n\n // If a focused goal is set, try to load it first\n const focusedName = this.getFocusedGoal(roleId);\n if (focusedName) {\n const goalDir = join(goalsDir, focusedName);\n const result = this.loadGoalIfActive(goalDir);\n if (result) return result;\n }\n\n // Fallback: first uncompleted goal alphabetically\n const goalDirs = readdirSync(goalsDir, { withFileTypes: true })\n .filter((d) => d.isDirectory())\n .map((d) => d.name)\n .sort();\n\n for (const goalName of goalDirs) {\n const goalDir = join(goalsDir, goalName);\n const result = this.loadGoalIfActive(goalDir);\n if (result) return result;\n }\n\n return null;\n }\n\n allActiveGoals(roleId: string): Goal[] {\n const roleDir = this.resolveRoleDir(roleId);\n const goalsDir = join(roleDir, \"goals\");\n if (!existsSync(goalsDir)) return [];\n\n const goalDirs = readdirSync(goalsDir, { withFileTypes: true })\n .filter((d) => d.isDirectory())\n .map((d) => d.name)\n .sort();\n\n const goals: Goal[] = [];\n for (const goalName of goalDirs) {\n const goalDir = join(goalsDir, goalName);\n const goalFile = this.findFeatureFile(goalDir, \".goal.feature\");\n if (!goalFile) continue;\n\n const source = readFileSync(goalFile, \"utf-8\");\n const doc = parse(source);\n if (!doc.feature) continue;\n\n if (doc.feature.tags.some((t) => t.name === \"@done\" || t.name === \"@abandoned\")) continue;\n\n goals.push(this.toFeature(doc.feature, \"goal\") as Goal);\n }\n\n return goals;\n }\n\n getFocusedGoal(roleId: string): string | null {\n const roleDir = this.resolveRoleDir(roleId);\n const focusFile = join(roleDir, \"goals\", \".focus\");\n if (!existsSync(focusFile)) return null;\n return readFileSync(focusFile, \"utf-8\").trim() || null;\n }\n\n setFocusedGoal(roleId: string, name: string): void {\n const roleDir = this.resolveRoleDir(roleId);\n const goalsDir = join(roleDir, \"goals\");\n const goalDir = join(goalsDir, name);\n\n if (!existsSync(goalDir)) {\n throw new Error(`Goal not found: ${name}`);\n }\n\n writeFileSync(join(goalsDir, \".focus\"), name, \"utf-8\");\n }\n\n // ========== Write ==========\n\n createGoal(roleId: string, name: string, source: string, testable?: boolean): Goal {\n const roleDir = this.resolveRoleDir(roleId);\n const goalDir = join(roleDir, \"goals\", name);\n mkdirSync(goalDir, { recursive: true });\n\n if (testable) source = `@testable\\n${source}`;\n const filePath = join(goalDir, `${name}.goal.feature`);\n writeFileSync(filePath, source, \"utf-8\");\n\n const doc = parse(source);\n return this.toFeature(doc.feature!, \"goal\") as Goal;\n }\n\n createPlan(roleId: string, source: string): Plan {\n const roleDir = this.resolveRoleDir(roleId);\n const goalDir = this.getActiveGoalDir(roleDir);\n if (!goalDir) throw new Error(\"No active goal\");\n\n const goalName = basename(goalDir);\n const filePath = join(goalDir, `${goalName}.plan.feature`);\n writeFileSync(filePath, source, \"utf-8\");\n\n const doc = parse(source);\n return this.toFeature(doc.feature!, \"plan\") as Plan;\n }\n\n createTask(roleId: string, name: string, source: string, testable?: boolean): Task {\n const roleDir = this.resolveRoleDir(roleId);\n const goalDir = this.getActiveGoalDir(roleDir);\n if (!goalDir) throw new Error(\"No active goal\");\n\n const tasksDir = join(goalDir, \"tasks\");\n mkdirSync(tasksDir, { recursive: true });\n\n if (testable) source = `@testable\\n${source}`;\n const filePath = join(tasksDir, `${name}.task.feature`);\n writeFileSync(filePath, source, \"utf-8\");\n\n const doc = parse(source);\n return this.toFeature(doc.feature!, \"task\") as Task;\n }\n\n // ========== Close ==========\n\n completeGoal(roleId: string, experience?: string): void {\n const roleDir = this.resolveRoleDir(roleId);\n const goalDir = this.getActiveGoalDir(roleDir);\n if (!goalDir) throw new Error(\"No active goal\");\n\n const goalFile = this.findFeatureFile(goalDir, \".goal.feature\")!;\n this.addDoneTag(goalFile);\n\n if (experience) {\n const goalName = basename(goalDir);\n this.growup(roleId, \"experience\", goalName, experience);\n }\n }\n\n abandonGoal(roleId: string, experience?: string): void {\n const roleDir = this.resolveRoleDir(roleId);\n const goalDir = this.getActiveGoalDir(roleDir);\n if (!goalDir) throw new Error(\"No active goal\");\n\n const goalFile = this.findFeatureFile(goalDir, \".goal.feature\")!;\n this.addTag(goalFile, \"@abandoned\");\n\n if (experience) {\n const goalName = basename(goalDir);\n this.growup(roleId, \"experience\", goalName, experience);\n }\n }\n\n completeTask(roleId: string, name: string): void {\n const roleDir = this.resolveRoleDir(roleId);\n const goalDir = this.getActiveGoalDir(roleDir);\n if (!goalDir) throw new Error(\"No active goal\");\n\n const tasksDir = join(goalDir, \"tasks\");\n const taskFile = join(tasksDir, `${name}.task.feature`);\n if (!existsSync(taskFile)) throw new Error(`Task not found: ${name}`);\n\n this.addDoneTag(taskFile);\n }\n\n // ========== Internal ==========\n\n private loadConfig(): RolexConfig {\n if (this.config) return this.config;\n\n const configPath = join(this.rootDir, \"rolex.json\");\n if (existsSync(configPath)) {\n this.config = JSON.parse(readFileSync(configPath, \"utf-8\"));\n return this.config!;\n }\n\n throw new Error(`No rolex.json found in ${this.rootDir}. Call found() first.`);\n }\n\n private saveConfig(config: RolexConfig): void {\n writeFileSync(join(this.rootDir, \"rolex.json\"), JSON.stringify(config, null, 2), \"utf-8\");\n this.config = config;\n }\n\n private resolveRoleDir(roleId: string): string {\n const roleDir = join(this.rootDir, roleId);\n if (!existsSync(roleDir)) {\n throw new Error(`Role directory not found: ${roleDir}`);\n }\n return roleDir;\n }\n\n private loadGoalIfActive(goalDir: string): (Goal & { plan: Plan | null; tasks: Task[] }) | null {\n const goalFile = this.findFeatureFile(goalDir, \".goal.feature\");\n if (!goalFile) return null;\n\n const source = readFileSync(goalFile, \"utf-8\");\n const doc = parse(source);\n if (!doc.feature) return null;\n\n if (doc.feature.tags.some((t) => t.name === \"@done\" || t.name === \"@abandoned\")) return null;\n\n const goal = this.toFeature(doc.feature, \"goal\") as Goal;\n return {\n ...goal,\n plan: this.loadPlan(goalDir),\n tasks: this.loadTasks(goalDir),\n };\n }\n\n private getActiveGoalDir(roleDir: string): string | null {\n const goalsDir = join(roleDir, \"goals\");\n if (!existsSync(goalsDir)) return null;\n\n // Respect focused goal\n const focusFile = join(goalsDir, \".focus\");\n if (existsSync(focusFile)) {\n const focusedName = readFileSync(focusFile, \"utf-8\").trim();\n if (focusedName) {\n const focusedDir = join(goalsDir, focusedName);\n if (existsSync(focusedDir) && this.loadGoalIfActive(focusedDir)) {\n return focusedDir;\n }\n }\n }\n\n // Fallback: first uncompleted goal\n const goalDirs = readdirSync(goalsDir, { withFileTypes: true })\n .filter((d) => d.isDirectory())\n .map((d) => d.name)\n .sort();\n\n for (const goalName of goalDirs) {\n const goalDir = join(goalsDir, goalName);\n if (this.loadGoalIfActive(goalDir)) {\n return goalDir;\n }\n }\n\n return null;\n }\n\n private toFeature(gherkin: GherkinFeature, type: Feature[\"type\"]): Feature {\n return {\n ...gherkin,\n type,\n scenarios: this.extractScenarios(gherkin),\n };\n }\n\n private extractScenarios(feature: GherkinFeature): Scenario[] {\n const featureTestable = feature.tags.some((t) => t.name === \"@testable\");\n return (feature.children || [])\n .filter((c) => c.scenario)\n .map((c) => ({\n ...c.scenario!,\n verifiable: featureTestable || c.scenario!.tags.some((t) => t.name === \"@testable\"),\n }));\n }\n\n private loadPlan(goalDir: string): Plan | null {\n const planFile = this.findFeatureFile(goalDir, \".plan.feature\");\n if (!planFile) return null;\n\n const source = readFileSync(planFile, \"utf-8\");\n const doc = parse(source);\n if (!doc.feature) return null;\n\n return this.toFeature(doc.feature, \"plan\") as Plan;\n }\n\n private loadTasks(goalDir: string): Task[] {\n const tasksDir = join(goalDir, \"tasks\");\n if (!existsSync(tasksDir)) return [];\n\n return readdirSync(tasksDir)\n .filter((f) => f.endsWith(\".task.feature\"))\n .sort()\n .map((f) => {\n const source = readFileSync(join(tasksDir, f), \"utf-8\");\n const doc = parse(source);\n return this.toFeature(doc.feature!, \"task\") as Task;\n });\n }\n\n private detectIdentityType(filename: string): Feature[\"type\"] {\n if (filename === \"persona.identity.feature\") return \"persona\";\n if (filename.endsWith(\".knowledge.identity.feature\")) return \"knowledge\";\n if (filename.endsWith(\".experience.identity.feature\")) return \"experience\";\n if (filename.endsWith(\".voice.identity.feature\")) return \"voice\";\n return \"knowledge\";\n }\n\n private findFeatureFile(dir: string, suffix: string): string | null {\n if (!existsSync(dir)) return null;\n const file = readdirSync(dir).find((f) => f.endsWith(suffix));\n return file ? join(dir, file) : null;\n }\n\n private addTag(filePath: string, tag: string): void {\n const content = readFileSync(filePath, \"utf-8\");\n const updated = content.replace(/^(Feature:)/m, `${tag}\\n$1`);\n writeFileSync(filePath, updated, \"utf-8\");\n }\n\n private addDoneTag(filePath: string): void {\n this.addTag(filePath, \"@done\");\n }\n}\n"],"mappings":";AAcA,SAAS,aAAa,cAAc,eAAe,WAAW,YAAY,cAAc;AACxF,SAAS,MAAM,gBAAgB;AAC/B,SAAS,aAAa;AAkBf,IAAM,gBAAN,MAAwC;AAAA,EAC5B;AAAA,EACT,SAA6B;AAAA,EAErC,YAAY,SAAiB;AAC3B,SAAK,UAAU;AAAA,EACjB;AAAA;AAAA,EAIA,MAAM,MAAoB;AACxB,cAAU,KAAK,SAAS,EAAE,WAAW,KAAK,CAAC;AAE3C,UAAM,SAAsB;AAAA,MAC1B;AAAA,MACA,OAAO,EAAE,SAAS,CAAC,EAAE;AAAA,IACvB;AAEA,SAAK,WAAW,MAAM;AAAA,EACxB;AAAA;AAAA,EAIA,eAA6B;AAC3B,UAAM,SAAS,KAAK,WAAW;AAC/B,UAAM,QAAqB,CAAC;AAE5B,eAAW,CAAC,UAAU,SAAS,KAAK,OAAO,QAAQ,OAAO,KAAK,GAAG;AAChE,iBAAW,YAAY,WAAW;AAChC,cAAM,KAAK;AAAA,UACT,MAAM;AAAA,UACN,MAAM;AAAA,QACR,CAAC;AAAA,MACH;AAAA,IACF;AAEA,WAAO,EAAE,MAAM,O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AACF;","names":[]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rolexjs/local-platform",
3
- "version": "0.4.0",
3
+ "version": "0.5.0",
4
4
  "description": "Local filesystem Platform for RoleX — stores roles in .rolex/ directories",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -19,11 +19,11 @@
19
19
  "clean": "rm -rf dist"
20
20
  },
21
21
  "dependencies": {
22
- "@rolexjs/core": "^0.4.0",
23
- "@rolexjs/parser": "^0.4.0"
22
+ "@rolexjs/core": "^0.5.0",
23
+ "@rolexjs/parser": "^0.5.0"
24
24
  },
25
25
  "devDependencies": {
26
- "rolexjs": "^0.4.0"
26
+ "rolexjs": "^0.5.0"
27
27
  },
28
28
  "publishConfig": {
29
29
  "access": "public"