@fermindi/pwn-cli 0.9.9 → 0.9.11
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/package.json
CHANGED
|
@@ -626,6 +626,9 @@ export async function runBatch(options = {}, cwd = process.cwd()) {
|
|
|
626
626
|
markStoryDone(task.id, taskWorktreePath);
|
|
627
627
|
appendProgress(progressPath, task.id, 'All quality gates passed');
|
|
628
628
|
|
|
629
|
+
// Remove symlinks before commit so git add . doesn't stage them
|
|
630
|
+
unprepareWorktree(taskWorktreePath);
|
|
631
|
+
|
|
629
632
|
const config = loadConfig(mainCwd);
|
|
630
633
|
if (config.auto_commit) {
|
|
631
634
|
await commitTask(task, {}, taskWorktreePath);
|
|
@@ -14,8 +14,8 @@ import { getState, updateState, hasWorkspace } from '../core/state.js';
|
|
|
14
14
|
|
|
15
15
|
const execAsync = promisify(exec);
|
|
16
16
|
|
|
17
|
-
// ---
|
|
18
|
-
const METADATA_IGNORE_ENTRIES = ['.ai/batch/', '.ai/state.json', 'logs/'];
|
|
17
|
+
// --- Patterns that should never be tracked by git ---
|
|
18
|
+
const METADATA_IGNORE_ENTRIES = ['.ai/batch/', '.ai/state.json', 'logs/', 'node_modules/', '.venv/', 'venv/', 'vendor/'];
|
|
19
19
|
|
|
20
20
|
// --- Git Helpers ---
|
|
21
21
|
|
|
@@ -809,7 +809,18 @@ export async function runQualityGate(gate, cwd = process.cwd(), { configCwd } =
|
|
|
809
809
|
command
|
|
810
810
|
};
|
|
811
811
|
} catch (error) {
|
|
812
|
-
//
|
|
812
|
+
// Custom commands must not be silently skipped — "not found" is a real failure
|
|
813
|
+
if (customCmd) {
|
|
814
|
+
return {
|
|
815
|
+
success: false,
|
|
816
|
+
error: error.message,
|
|
817
|
+
output: error.stdout,
|
|
818
|
+
stderr: error.stderr,
|
|
819
|
+
command
|
|
820
|
+
};
|
|
821
|
+
}
|
|
822
|
+
|
|
823
|
+
// For default/fallback commands: if command not found, try next variant
|
|
813
824
|
if (error.message?.includes('not found') ||
|
|
814
825
|
error.message?.includes('ENOENT') ||
|
|
815
826
|
error.message?.includes('missing script')) {
|
|
@@ -827,7 +838,7 @@ export async function runQualityGate(gate, cwd = process.cwd(), { configCwd } =
|
|
|
827
838
|
}
|
|
828
839
|
}
|
|
829
840
|
|
|
830
|
-
// No command variant worked
|
|
841
|
+
// No default command variant worked (only reached for non-custom gates)
|
|
831
842
|
return {
|
|
832
843
|
success: true, // Skip if no command available
|
|
833
844
|
skipped: true,
|