title: Get license information for all used NuGet packages in .NET Core outside of Visual Studio
body: <p>We have a requirement in our project to list all of the licensed nuget packages. It would be ideal to generate them to some kind of csv, json, xml file. It would have to be done by build or by CI/CD tool. The problem is the only way I found to get that listing is by calling:</p>
  
  <pre><code>Get-Package | Select-Object Id,LicenseUrl
  </code></pre>
  
  <p>inside Visual studios package manager. I found also some sample powershell scripts but they are all based on versions of .net prior to .net core and are based on reading packages folder which in .net core version no longr exists.</p>
  
  <p>Is there any way to achieve what we need in .NET Core ?</p>
  
  <p>Regards.</p>