Skip to content

Add Directory.Build.props with shared build settings #116

Description

@LeeCampbell

Summary

Add a Directory.Build.props file at the repository root to centralise shared MSBuild properties across all projects.

Details

This file should include:

  • EnforceCodeStyleInBuild: Set to true so .editorconfig style rules are checked during build
  • AnalysisLevel: Set to latest-recommended to enable the built-in .NET analysers
  • Nullable: Enable nullable reference types repo-wide (if not already set per-project)
  • TreatWarningsAsErrors: Consider enabling for analyser warnings (CA/IDE rules) — but assess the impact on the current codebase first
  • ImplicitUsings: Align on whether this is enabled or disabled repo-wide

The goal is to have one place for build-wide settings rather than duplicating them in each .csproj.

Acceptance Criteria

  • Directory.Build.props added at repository root
  • EnforceCodeStyleInBuild enabled
  • Built-in .NET analysers enabled at recommended level
  • Build and tests still pass (adjust severity levels if needed to avoid breaking the build)
  • Any per-project settings that are now redundant are removed from individual .csproj files

Notes

Start conservative — if enabling analysers produces too many warnings, set the severity to suggestion initially and tighten in follow-up issues.

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions