jettypod 3.0.2 → 3.0.3

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.
@@ -1220,13 +1220,14 @@ async function main() {
1220
1220
 
1221
1221
  if (!featureId || isNaN(featureId)) {
1222
1222
  console.error('Error: Feature ID is required');
1223
- console.log('Usage: jettypod work implement <feature-id> [--prototypes="file1,file2"] [--winner="file.js"]');
1223
+ console.log('Usage: jettypod work implement <feature-id> [--prototypes="file1,file2"] [--winner="file.js"] [--rationale="why this approach"]');
1224
1224
  process.exit(1);
1225
1225
  }
1226
1226
 
1227
- // Parse optional --prototypes and --winner flags
1227
+ // Parse optional --prototypes, --winner, and --rationale flags
1228
1228
  const prototypesIndex = args.findIndex(a => a.startsWith('--prototypes='));
1229
1229
  const winnerIndex = args.findIndex(a => a.startsWith('--winner='));
1230
+ const rationaleIndex = args.findIndex(a => a.startsWith('--rationale='));
1230
1231
 
1231
1232
  const prototypes = prototypesIndex !== -1
1232
1233
  ? args[prototypesIndex].split('=')[1].replace(/^["']|["']$/g, '').split(',').map(p => p.trim())
@@ -1234,6 +1235,9 @@ async function main() {
1234
1235
  const winner = winnerIndex !== -1
1235
1236
  ? args[winnerIndex].split('=')[1].replace(/^["']|["']$/g, '')
1236
1237
  : null;
1238
+ const rationale = rationaleIndex !== -1
1239
+ ? args[rationaleIndex].split('=')[1].replace(/^["']|["']$/g, '')
1240
+ : null;
1237
1241
 
1238
1242
  db.get(`SELECT * FROM work_items WHERE id = ?`, [featureId], (err, feature) => {
1239
1243
  if (err) {
@@ -1297,10 +1301,11 @@ async function main() {
1297
1301
  // Transition to implementation phase, set mode to speed
1298
1302
  const prototypeFilesValue = prototypes.length > 0 ? JSON.stringify(prototypes) : null;
1299
1303
  const winnerValue = winner || null;
1304
+ const rationaleValue = rationale || null;
1300
1305
 
1301
1306
  db.run(
1302
- `UPDATE work_items SET phase = 'implementation', mode = 'speed', prototype_files = ?, discovery_winner = ? WHERE id = ?`,
1303
- [prototypeFilesValue, winnerValue, featureId],
1307
+ `UPDATE work_items SET phase = 'implementation', mode = 'speed', prototype_files = ?, discovery_winner = ?, discovery_rationale = ? WHERE id = ?`,
1308
+ [prototypeFilesValue, winnerValue, rationaleValue, featureId],
1304
1309
  (err) => {
1305
1310
  if (err) {
1306
1311
  console.error(`Error: ${err.message}`);
@@ -1321,6 +1326,9 @@ async function main() {
1321
1326
  if (winner) {
1322
1327
  console.log(`Winner: ${winner}`);
1323
1328
  }
1329
+ if (rationale) {
1330
+ console.log(`Rationale: ${rationale}`);
1331
+ }
1324
1332
  console.log('');
1325
1333
  console.log('━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━');
1326
1334
  console.log('🚀 Speed Mode: Prove It Works');
@@ -0,0 +1,24 @@
1
+ // Migration: Add discovery_rationale field for feature discovery decisions
2
+ // Created: 2025-01-06
3
+ // Purpose: Track rationale for UX approach chosen during feature discovery
4
+ // Related: Feature-discover skill - records why an approach was selected
5
+
6
+ module.exports = {
7
+ id: '009-discovery-rationale-field',
8
+ description: 'Add discovery_rationale field for feature discovery decisions',
9
+
10
+ up: (db) => {
11
+ return new Promise((resolve, reject) => {
12
+ db.run(
13
+ `ALTER TABLE work_items ADD COLUMN discovery_rationale TEXT`,
14
+ (err) => {
15
+ if (err && !err.message.includes('duplicate column')) {
16
+ return reject(err);
17
+ }
18
+ console.log('Added discovery_rationale column to work_items');
19
+ resolve();
20
+ }
21
+ );
22
+ });
23
+ }
24
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jettypod",
3
- "version": "3.0.2",
3
+ "version": "3.0.3",
4
4
  "description": "Simplified development mode manager",
5
5
  "main": "jettypod.js",
6
6
  "bin": {