fix(parse-prd): resolves issue preventing --append flag from properly working in the CLI context. Adds changeset.

This commit is contained in:
Eyal Toledano
2025-05-07 14:17:41 -04:00
parent 8ae772086d
commit 0288311965
2 changed files with 13 additions and 6 deletions

View File

@@ -0,0 +1,7 @@
---
'task-master-ai': patch
---
Small fixes
- `next` command no longer incorrectly suggests that subtasks be broken down into subtasks in the CLI
- fixes the `append` flag so it properly works in the CLI

View File

@@ -516,8 +516,8 @@ function registerCommands(programInstance) {
const outputPath = options.output;
const force = options.force || false;
const append = options.append || false;
let useForce = false;
let useAppend = false;
let useForce = force;
let useAppend = append;
// Helper function to check if tasks.json exists and confirm overwrite
async function confirmOverwriteIfNeeded() {
@@ -547,8 +547,8 @@ function registerCommands(programInstance) {
console.log(chalk.blue(`Generating ${numTasks} tasks...`));
spinner = ora('Parsing PRD and generating tasks...').start();
await parsePRD(defaultPrdPath, outputPath, numTasks, {
useAppend,
useForce
append: useAppend, // Changed key from useAppend to append
force: useForce // Changed key from useForce to force
});
spinner.succeed('Tasks generated successfully!');
return;
@@ -609,8 +609,8 @@ function registerCommands(programInstance) {
spinner = ora('Parsing PRD and generating tasks...').start();
await parsePRD(inputFile, outputPath, numTasks, {
append: useAppend,
force: useForce
useAppend: useAppend,
useForce: useForce
});
spinner.succeed('Tasks generated successfully!');
} catch (error) {