Add markdown output format for CI environments with key features summary #630
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Overview
Adds a new markdown output format (
-f markdown
) to Application Inspector that is specifically designed for CI/CD environments. This format provides a concise, well-organized summary of analysis results that renders beautifully in GitHub/GitLab PRs and issues.Fixes #604
Motivation
The existing output formats (HTML, JSON, text, SARIF) are optimized for different use cases:
However, none of these formats are ideal for posting analysis results directly in CI environments where you want:
Changes
Core Implementation
AnalyzeMarkdownWriter.cs
: New writer class that formats analysis results in markdown with organized sectionsWriterFactory.cs
: Added markdown format support to the writer factoryCLICmdOptions.cs
: Updated help text to include markdown in available formatsProgram.cs
: Added markdown to the valid formats validation listTesting
TestMarkdownWriter.cs
: Unit test verifying markdown output structure and contentDocumentation
README.md
: Added example of using markdown output formatUsage
Output Format
The markdown format includes:
1. Summary
2. Key Statistics (Table)
3. Key Features Detected
4. Detected Technologies
5. Target Platforms
6. Dependencies
7. Detailed Tag Counters (Table)
Example Output
Benefits for CI/CD
✅ Readable in PRs: Markdown renders beautifully in GitHub/GitLab comments
✅ Concise: Focuses on key findings, not overwhelming detail
✅ Actionable: Easy to identify security-relevant features
✅ Machine-friendly: Can be parsed for automated policy checks
✅ Version control: Can be committed to track changes over time
✅ Minimal changes: Surgical implementation following existing patterns
Testing Coverage
Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.