aboutsummaryrefslogtreecommitdiff
path: root/toolsrc/src
diff options
context:
space:
mode:
authorAlexander Karatarakis <alkarata@microsoft.com>2017-05-02 15:34:14 -0700
committerAlexander Karatarakis <alkarata@microsoft.com>2017-05-02 15:34:14 -0700
commit22b1733a4aa6a3b8732a1cac6de8bade7a5c8044 (patch)
treeac90ced4185736cdb0bac67c53ab38498d9f9303 /toolsrc/src
parent7abc557eb2e89d8bf8e1a5ce6eaa735dd17c9adb (diff)
downloadvcpkg-22b1733a4aa6a3b8732a1cac6de8bade7a5c8044.tar.gz
vcpkg-22b1733a4aa6a3b8732a1cac6de8bade7a5c8044.zip
`exprot`: --nuget now provides additional next-step instructions
Diffstat (limited to 'toolsrc/src')
-rw-r--r--toolsrc/src/commands_export.cpp13
1 files changed, 11 insertions, 2 deletions
diff --git a/toolsrc/src/commands_export.cpp b/toolsrc/src/commands_export.cpp
index 3cc0809d5..3263de31c 100644
--- a/toolsrc/src/commands_export.cpp
+++ b/toolsrc/src/commands_export.cpp
@@ -109,6 +109,7 @@ namespace vcpkg::Commands::Export
}
static fs::path do_nuget_export(const VcpkgPaths& paths,
+ const std::string& nuget_id,
const fs::path& raw_exported_dir,
const fs::path& output_dir)
{
@@ -123,7 +124,6 @@ namespace vcpkg::Commands::Export
const fs::path targets_redirect = paths.buildsystems / "tmp" / "vcpkg.export.nuget.targets";
fs.write_contents(targets_redirect, targets_redirect_content);
- const std::string nuget_id = raw_exported_dir.filename().string();
const std::string nuspec_file_content =
create_nuspec_file_contents(raw_exported_dir.string(), targets_redirect.string(), nuget_id, NUPKG_VERSION);
const fs::path nuspec_file_path = paths.buildsystems / "tmp" / "vcpkg.export.nuspec";
@@ -334,9 +334,18 @@ namespace vcpkg::Commands::Export
if (nuget)
{
System::println("Creating nuget package... ");
- const fs::path output_path = do_nuget_export(paths, raw_exported_dir_path, export_to_path);
+
+ const std::string nuget_id = raw_exported_dir_path.filename().string();
+ const fs::path output_path = do_nuget_export(paths, nuget_id, raw_exported_dir_path, export_to_path);
System::println(System::Color::success, "Creating nuget package... done");
System::println(System::Color::success, "Nuget package exported at: %s", output_path.generic_string());
+
+ System::println(R"(
+With a project open, go to Tools->NuGet Package Manager->Package Manager Console and paste:
+ Install-Package %s -Source "%s"
+)",
+ nuget_id,
+ output_path.parent_path().u8string());
}
if (zip)