Project Sdk="Microsoft.NET.Sdk"
, " ". , Microsoft.NET.Sdk/Sdk.targets csproj, "BeforeBuild" "AfterBuild".
, , .
<Project>
<Import Project="Sdk.props" Sdk="Microsoft.NET.Sdk" />
<PropertyGroup>
<TargetFramework>net46</TargetFramework>
</PropertyGroup>
<Import Project="Sdk.targets" Sdk="Microsoft.NET.Sdk" />
<Target Name="BeforeBuild">
<Message Text="Should run before build" Importance="High" />
</Target>
<Target Name="AfterBuild">
<Message Text="Should run after build" Importance="High" />
</Target>
</Project>