(09/2022)
- New: Wildcard patterns for namespaces.
(07/2022)
- New: ParentCanDependOnChildImplicitly config attribute.
(03/2022)
- Fix: #60 - Statically imported type dependency not detected.
(06/2021)
The big change in this version is that the implementation changed from MSBuild task + Visual Studio Extension to a standard Roslyn analyzer.
- NsDepCop must be added to a project as a NuGet package.
- Appears in Solution Explorer: project / Dependencies / Analyzers / NsDepCop.Analyzer
- Issue severities can be configured that same way as other analyzers (use Visual Studio or .editorconfig files).
- Works both at build time and inside Visual Studio editor.
- Requires Visual Studio 2019 (16.10.0 or later).
- Supports .NET Core / .NET 5 / etc. projects too.
- Uses Roslyn 3.9.0.
Stuff that was removed:
- No need for the NsDepCop Visual Studio Extension any more.
- No need for the out-of-process service host any more.
- Dropped support for VS 2015/2017. For those, use NsDepCop v1.11.0.
- Config attributes no longer supported (ignored): CodeIssueKind, MaxIssueCountSeverity, InfoImportance, AnalyzerServiceCallRetryTimeSpans.
Other info:
- AutoLowerMaxIssueCount feature is temporarily not supported.
(04/2020)
- New: Disable/force NsDepCop with MSBuild property.
(02/2020)
- Fix: #51 - RemotingException when using different NsDepCop NuGet and VSIX version.
(04/2019)
- New: Support Visual Studio 2019
(03/2019)
- New: Support incremental build - don't run the tool if there was no change in the source/config files.
- New: Global turn off switch - DisableNsDepCop environment variable.
- New: Excluding files from analysis - ExcludedFiles attribute in config.nsdepcop.
(01/2019)
- Fix: #43 (for real this time) - RemotingException when path contains space.
(12/2018)
- Fix: #43 - RemotingException when path contains space.
(07/2018)
- Enhancements in launching the out-of-process service host (configurable retry intervals, allow access for any user).
- MaxIssueCountSeverity - enables breaking the build when a threshold number of dependency violations has been reached.
- AutoLowerMaxIssueCount - automatically lower MaxIssueCount to encourage cleaning up dependency problems and prohibit introducing new ones.
- Supports C# up to 7.3.
- The Visual Studio Extension (VSIX) requires 15.7.4 or higher.
(07/2017)
- Performance enhancement when run by MSBuild.
- The analyzer keeps running in its own process to avoid repeated creation cost. Shuts down with parent process.
(07/2017)
- New: C# 7 support.
- New: Visual Studio 2017 support.
- Removed: MSI installer.
- Config XML schema support is now available as a Visual Studio Extension (only for VS2017).
- Global MSBuild-integration is discontinued. Please use per-project MSBuild integration via the NuGet package.
(04/2017)
- Fix: Type without a name caused exception in analyzer.
(03/2017)
- New: NuGet package.
- Enables per-project MSBuild integration.
- Enables zero install on build machine.
- New: Multi-level config file.
- Use the InheritanceDepth config attribute to specify the number of parent folder levels to merge config files from.
- Use it to get rid of redundant rules and settings in nsdepcop.config files and move them to a common place, eg. to solution level or repo root level.
- Changed: MSI installer modified.
- Option (default on): config.nsdepcop XML schema support updated.
- Option (default off): Machine-wide MSBuild integration. Not recommended any more, use the NuGet (per-project) distribution instead.
- Removed option: Visual Studio 2015 integration. Use the VSIX package directly instead.
- Fixed:
- Types in enum and delegate declarations were not analyzed.
- Constructed generic, array and pointer types are now analyzed recursively.
- Source and metadata file load errors are now handled gracefully.
- Changed: Roslyn version updated to 1.3.2.
- Changed: Removed NRefactory as a parser choice.
- To upgrade please uninstall the previous version first.
- Your existing config.nsdepcop files will be preserved.
- Then install the new version.
- Recommended: change to per-project MSBuild integration with NuGet. See README.md for details.
- Please note that if you don't uninstall the previous version then its machine-wide MSBuild integration will override the per-project integration provided by the NuGet package and the old analyzer version will run at build time.
(06/2016)
- Supports Visual Studio 2015 only.
- New: Use the VisibleMembers element to fine-tune the allowed dependencies at the type level.
- New: Added config.nsdepcop XML schema support to Visual Studio so it can validate config syntax and provide IntelliSense.
- Fixed: adding an nsdepcop.config file to a project now works for all C# projects (incl. portable lib).
- Changed: Roslyn version updated to 1.2.2.
(08/2015)
- Supports Visual Studio 2015 only.
- New: Info messages' level can be configured to suppress/enable them in the MSBuild output.
- New: ChildCanDependOnParentImplicitly config attribute.
- Fixed:
- MSBuild return code was success even if an error was detected.
- Extension method declaring type was not checked.
- Changed: Roslyn version updated to 1.0.
- Icons (tadaaa! :)
(01/2015)
- Supports Visual Studio 2013 only.
- New: Disallowed rules.
(08/2014)
- Supports Visual Studio 2013 only.
- Requires the Roslyn End User Preview of April 2014.
(07/2013)
- Supports Visual Studio 2012 only.
- Requires Roslyn September 2012 CTP.
- New: Added NRefactory as the default parser for the MSBuild task.
(03/2013)
- Supports Visual Studio 2012 only.
- Requires Roslyn September 2012 CTP.