diff options
| author | Alexander Karatarakis <alkarata@microsoft.com> | 2017-01-12 17:41:50 -0800 |
|---|---|---|
| committer | Alexander Karatarakis <alkarata@microsoft.com> | 2017-01-12 17:47:53 -0800 |
| commit | 8e1ed2c9a95fa5b9e0bb0a9849a6e20878696f8c (patch) | |
| tree | 63f05d6d03d0a2b6567deb8ece99012ef89bb270 | |
| parent | df2a05e8546281135c6ea12430734d74371bcf46 (diff) | |
| download | vcpkg-8e1ed2c9a95fa5b9e0bb0a9849a6e20878696f8c.tar.gz vcpkg-8e1ed2c9a95fa5b9e0bb0a9849a6e20878696f8c.zip | |
Place contact and version commands in different cpp files
| -rw-r--r-- | toolsrc/src/commands_contact.cpp | 13 | ||||
| -rw-r--r-- | toolsrc/src/commands_help.cpp | 18 | ||||
| -rw-r--r-- | toolsrc/src/commands_version.cpp | 16 | ||||
| -rw-r--r-- | toolsrc/vcpkg/vcpkg.vcxproj | 2 | ||||
| -rw-r--r-- | toolsrc/vcpkg/vcpkg.vcxproj.filters | 6 |
5 files changed, 37 insertions, 18 deletions
diff --git a/toolsrc/src/commands_contact.cpp b/toolsrc/src/commands_contact.cpp new file mode 100644 index 000000000..5bd1c1a67 --- /dev/null +++ b/toolsrc/src/commands_contact.cpp @@ -0,0 +1,13 @@ +#include "vcpkg_Commands.h" +#include "vcpkg_System.h" +#include "vcpkg_info.h" + +namespace vcpkg::Commands +{ + void contact_command(const vcpkg_cmd_arguments& args) + { + args.check_exact_arg_count(0); + System::println("Send an email to %s with any feedback.", Info::email()); + exit(EXIT_SUCCESS); + } +} diff --git a/toolsrc/src/commands_help.cpp b/toolsrc/src/commands_help.cpp index 5baec62c7..a0881e64d 100644 --- a/toolsrc/src/commands_help.cpp +++ b/toolsrc/src/commands_help.cpp @@ -1,19 +1,8 @@ #include "vcpkg_Commands.h" #include "vcpkg_System.h" -#include "vcpkg_info.h" namespace vcpkg::Commands { - void version_command(const vcpkg_cmd_arguments& args) - { - args.check_exact_arg_count(0); - System::println("Vcpkg package management program version %s\n" - "\n" - "See LICENSE.txt for license information.", Info::version() - ); - exit(EXIT_SUCCESS); - } - void help_command(const vcpkg_cmd_arguments& args, const vcpkg_paths& paths) { args.check_max_arg_count(1); @@ -36,13 +25,6 @@ namespace vcpkg::Commands exit(EXIT_SUCCESS); } - void contact_command(const vcpkg_cmd_arguments& args) - { - args.check_exact_arg_count(0); - System::println("Send an email to %s with any feedback.", Info::email()); - exit(EXIT_SUCCESS); - } - void help_topic_valid_triplet(const vcpkg_paths& paths) { System::println("Available architecture triplets:"); diff --git a/toolsrc/src/commands_version.cpp b/toolsrc/src/commands_version.cpp new file mode 100644 index 000000000..03cce32d4 --- /dev/null +++ b/toolsrc/src/commands_version.cpp @@ -0,0 +1,16 @@ +#include "vcpkg_Commands.h" +#include "vcpkg_System.h" +#include "vcpkg_info.h" + +namespace vcpkg::Commands +{ + void version_command(const vcpkg_cmd_arguments& args) + { + args.check_exact_arg_count(0); + System::println("Vcpkg package management program version %s\n" + "\n" + "See LICENSE.txt for license information.", Info::version() + ); + exit(EXIT_SUCCESS); + } +} diff --git a/toolsrc/vcpkg/vcpkg.vcxproj b/toolsrc/vcpkg/vcpkg.vcxproj index 0b6e2b752..79d348910 100644 --- a/toolsrc/vcpkg/vcpkg.vcxproj +++ b/toolsrc/vcpkg/vcpkg.vcxproj @@ -134,6 +134,7 @@ <ClCompile Include="..\src\commands_build.cpp" /> <ClCompile Include="..\src\commands_build_external.cpp" /> <ClCompile Include="..\src\commands_cache.cpp" /> + <ClCompile Include="..\src\commands_contact.cpp" /> <ClCompile Include="..\src\commands_create.cpp" /> <ClCompile Include="..\src\commands_edit.cpp" /> <ClCompile Include="..\src\commands_hash.cpp" /> @@ -144,6 +145,7 @@ <ClCompile Include="..\src\commands_remove.cpp" /> <ClCompile Include="..\src\commands_search.cpp" /> <ClCompile Include="..\src\commands_update.cpp" /> + <ClCompile Include="..\src\commands_version.cpp" /> <ClCompile Include="..\src\vcpkg_cmd_arguments.cpp" /> <ClCompile Include="..\src\commands_helpers.cpp" /> <ClCompile Include="..\src\vcpkg_Dependencies.cpp" /> diff --git a/toolsrc/vcpkg/vcpkg.vcxproj.filters b/toolsrc/vcpkg/vcpkg.vcxproj.filters index df8c48f8b..71b0635ab 100644 --- a/toolsrc/vcpkg/vcpkg.vcxproj.filters +++ b/toolsrc/vcpkg/vcpkg.vcxproj.filters @@ -93,6 +93,12 @@ <ClCompile Include="..\src\commands_available_commands.cpp"> <Filter>Source Files</Filter> </ClCompile> + <ClCompile Include="..\src\commands_version.cpp"> + <Filter>Source Files</Filter> + </ClCompile> + <ClCompile Include="..\src\commands_contact.cpp"> + <Filter>Source Files</Filter> + </ClCompile> </ItemGroup> <ItemGroup> <ClInclude Include="..\include\post_build_lint.h"> |
