aboutsummaryrefslogtreecommitdiff
path: root/toolsrc/src/commands_cache.cpp
diff options
context:
space:
mode:
authorThomas Fussell <thomas.fussell@gmail.com>2017-03-12 17:44:06 -0400
committerThomas Fussell <thomas.fussell@gmail.com>2017-03-12 17:44:06 -0400
commit2f42035ab43dd50cd863b51944aa099a99ae60f0 (patch)
tree4b6cfd43955e946721c58028fd8564c861d5c331 /toolsrc/src/commands_cache.cpp
parente02e85626f3206feda86a6f5757009005e0cfe3e (diff)
parent1c9873a0daf625f67474aaf3e163c592c27ecb65 (diff)
downloadvcpkg-2f42035ab43dd50cd863b51944aa099a99ae60f0.tar.gz
vcpkg-2f42035ab43dd50cd863b51944aa099a99ae60f0.zip
Merge branch 'master' of git://github.com/Microsoft/vcpkg
Diffstat (limited to 'toolsrc/src/commands_cache.cpp')
-rw-r--r--toolsrc/src/commands_cache.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/toolsrc/src/commands_cache.cpp b/toolsrc/src/commands_cache.cpp
index 1a10b93cf..e255b5dff 100644
--- a/toolsrc/src/commands_cache.cpp
+++ b/toolsrc/src/commands_cache.cpp
@@ -1,10 +1,11 @@
+#include "pch.h"
#include "vcpkg_Commands.h"
#include "vcpkg_System.h"
#include "vcpkg_Files.h"
#include "Paragraphs.h"
#include "BinaryParagraph.h"
-namespace vcpkg
+namespace vcpkg::Commands::Cache
{
static std::vector<BinaryParagraph> read_all_binary_paragraphs(const vcpkg_paths& paths)
{
@@ -34,11 +35,12 @@ namespace vcpkg
return output;
}
- void cache_command(const vcpkg_cmd_arguments& args, const vcpkg_paths& paths)
+ void perform_and_exit(const vcpkg_cmd_arguments& args, const vcpkg_paths& paths)
{
static const std::string example = Strings::format(
- "The argument should be a substring to search for, or no argument to display all cached libraries.\n%s", create_example_string("cache png"));
+ "The argument should be a substring to search for, or no argument to display all cached libraries.\n%s", Commands::Help::create_example_string("cache png"));
args.check_max_arg_count(1, example);
+ args.check_and_get_optional_command_arguments({});
const std::vector<BinaryParagraph> binary_paragraphs = read_all_binary_paragraphs(paths);
if (binary_paragraphs.empty())