Releases: randlee/roslyn-diff
v0.8.0 - Impact Classification, Whitespace Intelligence & Multi-TFM Support
Release v0.8.0
Major feature release consolidating three significant enhancements to roslyn-diff.
🎯 Impact Classification
Automatically categorizes every code change by its potential impact on consumers:
- Breaking Public API - Changes that break external consumers (method signature changes, removed public members)
- Breaking Internal API - Changes that break internal consumers (internal method renames, parameter changes)
- Non-Breaking - Safe changes with no execution impact (private field renames, code reordering)
- Formatting Only - Pure whitespace/comment changes
Each change includes visibility tracking and caveat warnings. See Impact Classification Guide for details.
🔍 Whitespace Intelligence
Fine-grained whitespace handling with language-aware detection:
- 4 Whitespace Modes: Exact, IgnoreLeadingTrailing, IgnoreAll, LanguageAware
- Automatic Issue Detection: Indentation changes, mixed tabs/spaces, trailing whitespace, line ending changes
- Language-Specific Handling: Exact mode for Python/YAML (whitespace-significant), normalized for C#/Java
See Whitespace Handling Guide for comprehensive details.
🎯 Multi-Target Framework Support
Analyze code differences across multiple .NET target frameworks simultaneously:
- TFM-Specific Change Detection - Identify which changes apply to specific target frameworks vs. all frameworks
- Conditional Compilation Awareness - Properly handles
#ifdirectives and framework-specific code - Per-TFM Semantic Analysis - Runs full Roslyn analysis for each target framework with correct compilation symbols
- Parallel TFM Processing - Optimized multi-TFM analysis with parallel processing
See Multi-TFM Support Guide for details.
📊 Usage Examples
Impact Classification
# Filter to breaking changes only
roslyn-diff diff old.cs new.cs --impact-level breaking-public --json
# Include all changes for review
roslyn-diff diff old.cs new.cs --html report.htmlWhitespace Intelligence
# Ignore all whitespace
roslyn-diff diff old.cs new.cs -w
# Language-aware mode
roslyn-diff diff old.py new.py --whitespace-mode language-awareMulti-TFM Analysis
# Single TFM
roslyn-diff diff old.cs new.cs -t net8.0
# Multiple TFMs
roslyn-diff diff old.cs new.cs -t net8.0 -t net10.0
# Semicolon-separated
roslyn-diff diff old.cs new.cs -T "net8.0;net10.0"
# Combined with other features
roslyn-diff diff old.cs new.cs -t net8.0 -t net10.0 --impact-level breaking-public --json📚 Documentation
- Impact Classification Guide
- Whitespace Handling Guide
- Multi-TFM Support Guide
- API Documentation
- Output Formats
🧪 Test Results
- Total Tests: 3,424 (all passing)
- New Tests: 528 tests added
- Regressions: 0
- Pass Rate: 100%
- Platforms: Ubuntu, macOS, Windows
⚡ Performance
- Impact Classification: Minimal overhead
- Whitespace Analysis: Negligible impact
- Multi-TFM Analysis: ~2-2.5x overhead for 3 frameworks (parallelized)
- Pre-scan Optimization: Skips multi-TFM when no
#ifdirectives exist
🔧 Breaking Changes
None - all new features are opt-in via CLI flags.
📝 Full Changelog
See CHANGELOG.md for complete details.
Full Diff: v0.7.0...v0.8.0
v0.7.0 - Non-Impactful Change Detection
What's New
Major Features
Non-Impactful Change Detection - Categorizes changes by impact level:
BreakingPublicApi- Public API changes that could break consumersBreakingInternalApi- Internal API changesNonBreaking- Private renames, local variable changes, code reorderingFormattingOnly- Whitespace/comment-only changes
CLI Impact Filtering Options:
--include-non-impactful- Include non-impactful changes in JSON output--include-formatting- Include formatting-only changes--impact-level <level>- Filter by minimum impact level
Enhanced Output:
- JSON output includes
impact,visibility, andcaveatsfields - HTML output shows impact badges with color coding
- Summary includes impact breakdown statistics
Quality Improvements
- Recursive tree diff algorithm (BUG-003 fix)
- Sample data validation testing framework
- 906 tests passing
Dependencies Updated
- Verify.Xunit 28.0.0 → 31.9.4
- xunit.runner.visualstudio 2.8.2 → 3.1.5
- Microsoft.NET.Test.Sdk 17.12.0 → 18.0.1
- FluentAssertions 7.0.0 → 8.8.0
Installation
As a .NET Tool
dotnet tool install -g roslyn-diff --version 0.7.0From GitHub Packages
dotnet tool install -g roslyn-diff --version 0.7.0 --add-source https://nuget.pkg.github.com/randlee/index.jsonv0.6.0 - Dependency Updates
Dependency Updates
Major dependency updates with breaking change fixes.
Dependency Updates
| Package | Old Version | New Version |
|---|---|---|
| Microsoft.CodeAnalysis.* (Roslyn) | 4.12.0 | 5.0.0 |
| Spectre.Console | 0.49.1 | 0.53.0 |
| FluentAssertions | 7.0.0 | 8.8.0 |
| DiffPlex | 1.7.2 | 1.9.0 |
| System.CommandLine | 2.0.0-beta4 | 2.0.2 |
| Microsoft.NET.Test.Sdk | 17.12.0 | 18.0.1 |
| BenchmarkDotNet | 0.14.0 | 0.15.8 |
| xunit | 2.9.2 | 2.9.3 |
| xunit.runner.visualstudio | 2.8.2 | 3.1.5 |
| coverlet.collector | 6.0.2 | 6.0.4 |
Breaking Changes Addressed
- Spectre.Console 0.53.x: Added
CancellationTokenparameter toExecuteAsyncmethods - FluentAssertions 8.x: Updated assertion method names
Installation
dotnet tool install --global roslyn-diff
# or update existing
dotnet tool update --global roslyn-diffv0.5.0 - Initial Release
Initial Release
First public release of roslyn-diff with semantic diff capabilities for C# and VB.NET files.
Features
- Semantic diff using Roslyn for C# and VB.NET
- Line-based diff for other file types
- Multiple output formats: text, HTML, JSON, terminal
- Class-level comparison with intelligent matching
- CLI tool with rich terminal output
Installation
dotnet tool install --global roslyn-diffUsage
# Compare two C# files
roslyn-diff diff old.cs new.cs
# Compare specific classes
roslyn-diff class old.cs:Calculator new.cs:Calculator
# Output as HTML
roslyn-diff diff old.cs new.cs --output html --out-file diff.html