1

I am writing a dotnet core tool and need to find a sibling nuget package from my tool. If i was on full .net framework i could have found it with

Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.UserProfile),".nuget...");

Anyone have a sugestion to find the package folder when not having the Environment stuff avaible? (If nothing exists, i can live with it not working on unix)

the dotnet core tools can be used in project.json tools section.

Set
  • 47,577
  • 22
  • 132
  • 150
Poul K. Sørensen
  • 16,950
  • 21
  • 126
  • 283

1 Answers1

3

In Nuget 3-3.5 you may use the following to get cache folder location

nuget locals packages-cache -list

After Nuget 3.5 this is currently not supported, but accordingly to this opened issue, Nuget team will consider those feature in future.

Set
  • 47,577
  • 22
  • 132
  • 150