Skip to content

Commit c331818

Browse files
committed
Another approach to run NuGet restore before build.
1 parent 02a7561 commit c331818

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

SharpRepository.Repository/SharpRepository.Repository.csproj

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -176,12 +176,8 @@
176176
</ItemGroup>
177177
<ItemGroup />
178178
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
179-
<Import Project="..\.nuget\NuGet.targets"/>
180179
<PropertyGroup>
181-
<BuildDependsOn>
182-
RestorePackages;
183-
$(BuildDependsOn)
184-
</BuildDependsOn>
180+
<PreBuildEvent>$(SolutionDir).nuget\nuget.exe restore $(MSBuildThisFileDirectory)..\SharpRepository.sln</PreBuildEvent>
185181
</PropertyGroup>
186182
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
187183
Other similar extension points exist, see Microsoft.Common.targets.

0 commit comments

Comments
 (0)