`integrate`: Use paths.get_nuget_exe()
MODIFY
src/commands_integrate.cpp
src/commands_integrate.cpp
@@ -249,7 +249,7 @@ namespace vcpkg::Commands::Integrate
static void integrate_project(const vcpkg_paths& paths)
{
- Environment::ensure_nuget_on_path(paths);
+ const fs::path& nuget_exe = paths.get_nuget_exe();
const fs::path& buildsystems_dir = paths.buildsystems;
const fs::path tmp_dir = buildsystems_dir / "tmp";
@@ -267,7 +267,7 @@ namespace vcpkg::Commands::Integrate
std::ofstream(nuspec_file_path) << create_nuspec_file(paths.root, nuget_id, nupkg_version);
// Using all forward slashes for the command line
- const std::wstring cmd_line = Strings::wformat(LR"(nuget.exe pack -OutputDirectory "%s" "%s" > nul)", buildsystems_dir.native(), nuspec_file_path.native());
+ const std::wstring cmd_line = Strings::wformat(LR"("%s" pack -OutputDirectory "%s" "%s" > nul)", nuget_exe.native(), buildsystems_dir.native(), nuspec_file_path.native());
const int exit_code = System::cmd_execute(cmd_line);

`integrate`: Use paths.get_nuget_exe()