Skip to content

PORTW-22: Handle --dry-run edge cases for protected and invisible targets - #27

Merged
JtheGunner merged 1 commit into
mainfrom
fix/PORTW-22-dry-run-edge-cases
Nov 12, 2026
Merged

JtheGunner merged 1 commit into
mainfrom
fix/PORTW-22-dry-run-edge-cases

Conversation

@JtheGunner

Copy link
Copy Markdown
Owner

Issue: https://youtrack.xn--wrm-hoa.li/issue/PORTW-22

  • --dry-run names the protection reason for PID 1 and the own process instead of "would execute".
  • An invisible owner is reported as a hint, not a kill failure, in --dry-run; a real run still exits 3.
  • The confirmation prompt now depends on stdin and stderr being a TTY (previously stdout).

Behaviour change: with stdout piped, the prompt now works when stdin and stderr are terminals. Touches internal/cli/run.go like other open PRs of this batch.

Commits:

  • fix: make --dry-run report protected and invisible targets and respect stderr TTY

Review: independent review PASS on 2e01216.

…t stderr TTY

Dry run now names the protection reason for PID 1 and self instead of
claiming it would execute, reports an invisible owner as a hint without a
kill-failure exit, and the confirmation prompt requires stdin and stderr
(where it is written) to be terminals instead of stdout.
@JtheGunner
JtheGunner merged commit d492135 into main Nov 12, 2026
3 checks passed
@JtheGunner
JtheGunner deleted the fix/PORTW-22-dry-run-edge-cases branch November 12, 2026 13:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant