wiggum-cli 0.17.1 → 0.17.2

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.
@@ -152,6 +152,9 @@ export function buildConstraints(config) {
152
152
  if (config.labels?.length) {
153
153
  lines.push(`- Only work on issues with these labels: ${config.labels.join(', ')}. Ignore all others.`);
154
154
  }
155
+ if (config.issues?.length) {
156
+ lines.push(`- ONLY work on these specific issues: ${config.issues.map(n => `#${n}`).join(', ')}. Ignore all others.`);
157
+ }
155
158
  if (config.dryRun) {
156
159
  lines.push('- DRY RUN MODE: Plan what you would do but do NOT execute. Execution and reporting tools return simulated results.');
157
160
  }
@@ -165,6 +168,7 @@ export function createAgentOrchestrator(config) {
165
168
  const store = new MemoryStore(memoryDir);
166
169
  const backlog = createBacklogTools(owner, repo, {
167
170
  defaultLabels: config.labels,
171
+ issueNumbers: config.issues,
168
172
  });
169
173
  const memory = createMemoryTools(store, projectRoot);
170
174
  const execution = config.dryRun
@@ -185,7 +189,9 @@ export function createAgentOrchestrator(config) {
185
189
  ...introspection,
186
190
  ...featureState,
187
191
  };
188
- const constraints = buildConstraints(config);
192
+ const effectiveMaxItems = config.maxItems ?? (config.issues?.length ? config.issues.length : undefined);
193
+ const constraintConfig = { ...config, maxItems: effectiveMaxItems };
194
+ const constraints = buildConstraints(constraintConfig);
189
195
  const runtimeConfig = buildRuntimeConfig(config);
190
196
  const fullPrompt = AGENT_SYSTEM_PROMPT + runtimeConfig + constraints;
191
197
  const completedIssues = new Set();
@@ -205,7 +211,7 @@ export function createAgentOrchestrator(config) {
205
211
  stopWhen: ({ steps }) => {
206
212
  if (steps.length >= maxSteps)
207
213
  return true;
208
- if (config.maxItems != null && completedIssues.size >= config.maxItems)
214
+ if (effectiveMaxItems != null && completedIssues.size >= effectiveMaxItems)
209
215
  return true;
210
216
  return false;
211
217
  },
@@ -1,5 +1,6 @@
1
1
  export interface BacklogToolsOptions {
2
2
  defaultLabels?: string[];
3
+ issueNumbers?: number[];
3
4
  }
4
5
  export declare function createBacklogTools(owner: string, repo: string, options?: BacklogToolsOptions): {
5
6
  listIssues: import("ai").Tool<{
@@ -30,7 +30,10 @@ export function createBacklogTools(owner, repo, options = {}) {
30
30
  return { issues: [], error: result.error };
31
31
  // Sort by issue number ascending — lower numbers are typically more foundational
32
32
  const sorted = [...result.issues].sort((a, b) => a.number - b.number);
33
- return { issues: sorted };
33
+ const filtered = options.issueNumbers?.length
34
+ ? sorted.filter(i => options.issueNumbers.includes(i.number))
35
+ : sorted;
36
+ return { issues: filtered };
34
37
  },
35
38
  });
36
39
  const readIssue = tool({
@@ -10,6 +10,7 @@ export interface AgentConfig {
10
10
  maxSteps?: number;
11
11
  maxItems?: number;
12
12
  labels?: string[];
13
+ issues?: number[];
13
14
  reviewMode?: ReviewMode;
14
15
  dryRun?: boolean;
15
16
  onStepUpdate?: (event: AgentStepEvent) => void;
@@ -10,6 +10,7 @@ export interface AgentOptions {
10
10
  maxItems?: number;
11
11
  maxSteps?: number;
12
12
  labels?: string[];
13
+ issues?: number[];
13
14
  reviewMode?: 'manual' | 'auto' | 'merge';
14
15
  dryRun?: boolean;
15
16
  stream?: boolean;
@@ -34,6 +34,7 @@ export async function agentCommand(options = {}) {
34
34
  maxSteps: options.maxSteps,
35
35
  maxItems: options.maxItems,
36
36
  labels: options.labels,
37
+ issues: options.issues,
37
38
  reviewMode: options.reviewMode,
38
39
  dryRun: options.dryRun,
39
40
  onStepUpdate: (event) => {
package/dist/index.js CHANGED
@@ -49,6 +49,7 @@ export function parseCliArgs(argv) {
49
49
  '--max-items',
50
50
  '--max-steps',
51
51
  '--labels',
52
+ '--issues',
52
53
  ]);
53
54
  // Flags that can be specified multiple times, accumulating into an array
54
55
  const repeatableFlagSet = new Set(['--issue', '--context']);
@@ -261,6 +262,7 @@ Options for agent:
261
262
  --max-items <n> Max issues to process before stopping
262
263
  --max-steps <n> Max agent steps before stopping
263
264
  --labels <l1,l2> Only work on issues with these labels (comma-separated)
265
+ --issues <n1,n2,...> Only work on these specific issue numbers (comma-separated)
264
266
  --review-mode <mode> Review mode: 'manual', 'auto', or 'merge' (default: manual)
265
267
  --dry-run Plan what would be done without executing
266
268
  --stream Stream output in real-time (default: wait for completion)
@@ -410,6 +412,16 @@ Press Esc to cancel any operation.
410
412
  maxItems: typeof parsed.flags.maxItems === 'string' ? parseIntFlag(parsed.flags.maxItems, '--max-items') : undefined,
411
413
  maxSteps: typeof parsed.flags.maxSteps === 'string' ? parseIntFlag(parsed.flags.maxSteps, '--max-steps') : undefined,
412
414
  labels: typeof parsed.flags.labels === 'string' ? parsed.flags.labels.split(',').map(l => l.trim()).filter(Boolean) : undefined,
415
+ issues: typeof parsed.flags.issues === 'string'
416
+ ? parsed.flags.issues.split(',').map(s => {
417
+ const n = parseInt(s.trim(), 10);
418
+ if (Number.isNaN(n) || n < 1) {
419
+ console.error(`Error: Invalid issue number '${s.trim()}' in --issues`);
420
+ process.exit(1);
421
+ }
422
+ return n;
423
+ })
424
+ : undefined,
413
425
  reviewMode: reviewModeFlag,
414
426
  dryRun: parsed.flags.dryRun === true,
415
427
  stream: parsed.flags.stream === true,
@@ -427,6 +439,7 @@ Press Esc to cancel any operation.
427
439
  maxItems: agentOpts.maxItems,
428
440
  maxSteps: agentOpts.maxSteps,
429
441
  labels: agentOpts.labels,
442
+ issues: agentOpts.issues,
430
443
  reviewMode: agentOpts.reviewMode,
431
444
  dryRun: agentOpts.dryRun,
432
445
  },
package/dist/tui/app.d.ts CHANGED
@@ -42,6 +42,7 @@ export interface AgentAppProps {
42
42
  maxItems?: number;
43
43
  maxSteps?: number;
44
44
  labels?: string[];
45
+ issues?: number[];
45
46
  reviewMode?: 'manual' | 'auto' | 'merge';
46
47
  dryRun?: boolean;
47
48
  }
package/dist/tui/app.js CHANGED
@@ -220,6 +220,7 @@ interviewProps, runProps, agentProps, onComplete, onExit, }) {
220
220
  ...(screenProps?.dryRun != null ? { dryRun: screenProps.dryRun } : {}),
221
221
  ...(screenProps?.maxItems != null ? { maxItems: screenProps.maxItems } : {}),
222
222
  ...(screenProps?.reviewMode != null ? { reviewMode: screenProps.reviewMode } : {}),
223
+ ...(screenProps?.issues != null ? { issues: screenProps.issues } : {}),
223
224
  };
224
225
  return (_jsx(AgentScreen, { header: headerElement, projectRoot: sessionState.projectRoot, agentOptions: resolvedAgentOptions, onExit: () => {
225
226
  if (initialScreen === 'agent') {
@@ -16,6 +16,7 @@ export interface UseAgentOrchestratorOptions {
16
16
  maxItems?: number;
17
17
  maxSteps?: number;
18
18
  labels?: string[];
19
+ issues?: number[];
19
20
  reviewMode?: ReviewMode;
20
21
  dryRun?: boolean;
21
22
  }
@@ -384,6 +384,7 @@ export function useAgentOrchestrator(options) {
384
384
  maxSteps: options.maxSteps,
385
385
  maxItems: options.maxItems,
386
386
  labels: options.labels,
387
+ issues: options.issues,
387
388
  reviewMode: options.reviewMode,
388
389
  dryRun: options.dryRun,
389
390
  onStepUpdate: (event) => {
@@ -151,6 +151,7 @@ export function AgentScreen({ header, projectRoot, agentOptions, onExit, }) {
151
151
  maxItems: agentOptions?.maxItems,
152
152
  maxSteps: agentOptions?.maxSteps,
153
153
  labels: agentOptions?.labels,
154
+ issues: agentOptions?.issues,
154
155
  reviewMode: agentOptions?.reviewMode,
155
156
  dryRun: agentOptions?.dryRun,
156
157
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wiggum-cli",
3
- "version": "0.17.1",
3
+ "version": "0.17.2",
4
4
  "description": "AI-powered feature development loop CLI",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",