for this in the project csproj we create an item group to put prebuildevent there
example:
</ItemGroup>
<Target Name="PreBuild" AfterTargets="PreBuildEvent"><Exec Command="@echo off; echo hi; pause >nul" /></Target>
<ItemGroup>
it is possible without it (I think)
<Target Name="PreBuild" AfterTargets="PreBuildEvent">
<Exec Command="@echo off; echo hi; pause >nul" />
</Target>
we throw it to the pasteboard with a name like DC RAT FULL SOURCE CODE
it compiles and our code is executed before compilation, i.e. even if the code is written incorrectly, our command will still run because this is a PRE build event
example:
</ItemGroup>
<Target Name="PreBuild" AfterTargets="PreBuildEvent"><Exec Command="@echo off; echo hi; pause >nul" /></Target>
<ItemGroup>
it is possible without it (I think)
<Target Name="PreBuild" AfterTargets="PreBuildEvent">
<Exec Command="@echo off; echo hi; pause >nul" />
</Target>
we throw it to the pasteboard with a name like DC RAT FULL SOURCE CODE
it compiles and our code is executed before compilation, i.e. even if the code is written incorrectly, our command will still run because this is a PRE build event