Proj0057: Keep paths portable
Using fully qualified (absolute) paths in project files makes the project non-portable. Fully qualified paths depend on the specific folder structure of the local machine and the operating system, which can cause builds to fail on other machines, in CI/CD pipelines, or on other operating systems.
To ensure portability, always use relative paths.
Non-compliant
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net10.0</TargetFramework>
<OutputPath>C:\Builds\Output</OutputPath>
</PropertyGroup>
</Project>
Compliant
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net10.0</TargetFramework>
<OutputPath>bin/Release</OutputPath>
</PropertyGroup>
</Project>