Skip to content

Add output file option - #23

Merged
antonisloukis merged 1 commit into
mainfrom
feat/output-file
Aug 4, 2026
Merged

antonisloukis merged 1 commit into
mainfrom
feat/output-file

Conversation

@antonisloukis

Copy link
Copy Markdown
Owner

Summary

Adds an output-file option to RunbookProof scans so text, JSON, and SARIF results can be written directly to a UTF-8 file.

Changes

  • Added -o and --output to the scan command
  • Supports text, JSON, and SARIF output files
  • Keeps standard output unchanged when no output path is provided
  • Preserves scan exit codes when output is written to a file
  • Prevents the input Markdown file from being overwritten
  • Reports output write failures with exit code 2
  • Updated the GitHub Code Scanning workflow to use --output
  • Added tests for JSON and SARIF file output
  • Added tests for invalid and unwritable output paths

Examples

runbookproof scan README.md --format json --output report.json
runbookproof scan docs/ --format sarif -o runbookproof.sarif

@antonisloukis
antonisloukis merged commit ca3d1ba into main Aug 4, 2026
7 checks passed
@antonisloukis
antonisloukis deleted the feat/output-file branch August 4, 2026 13:08
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