Closed Loudman closed 7 years ago
Hi,
If you are still using project.json you could make changes according to the dotnet-bundle command docs: https://github.com/madskristensen/BundlerMinifier/wiki#command-line-interface-net-core
If you're moving to csproj you could declare tools in the project and set prepublish target like that:
...
<ItemGroup>
<DotNetCliToolReference Include="Microsoft.VisualStudio.Web.CodeGeneration.Tools" Version="1.0.0" />
<DotNetCliToolReference Include="BundlerMinifier.Core" Version="2.2.301" />
<DotNetCliToolReference Include="Microsoft.DotNet.Xdt.Tools" Version="1.1.0" />
</ItemGroup>
...
<Target Name="PrepublishScript" BeforeTargets="PrepareForPublish">
<Exec Command="bower install" />
<Exec Command="dotnet bundle" />
</Target>
...
Is there any way that the publish run the following script:
"prepublish": ["dotnet bundle"], or "precompile": "dotnet bundle",
I really need to run "dotnet bundle" in order to generate all the minified files