aboutsummaryrefslogtreecommitdiff
path: root/toolsrc/include
diff options
context:
space:
mode:
authormartin-s <webmaster@macside.net>2019-07-02 05:51:07 +0000
committerVictor Romero <romerosanchezv@gmail.com>2019-07-01 22:51:07 -0700
commit91da4aab4c74af1d30c68896a058100257910e8d (patch)
treebdd4457dec608a07691c6b8b5ca075b652c051f9 /toolsrc/include
parent96994f8edeace0064b8d80489643e3cb79514390 (diff)
downloadvcpkg-91da4aab4c74af1d30c68896a058100257910e8d.tar.gz
vcpkg-91da4aab4c74af1d30c68896a058100257910e8d.zip
Allow redirection of the scripts folder. (#6552)
* Allow redirection of the scripts folder with an environment variable. * - Updated feature from environment variable to argument. * Fix crash when no scripts override is given and use --scripts-root=<PATH> format * Update help messages to use --scripts-root=<PATH> format
Diffstat (limited to 'toolsrc/include')
-rw-r--r--toolsrc/include/vcpkg/vcpkgcmdarguments.h1
-rw-r--r--toolsrc/include/vcpkg/vcpkgpaths.h3
2 files changed, 3 insertions, 1 deletions
diff --git a/toolsrc/include/vcpkg/vcpkgcmdarguments.h b/toolsrc/include/vcpkg/vcpkgcmdarguments.h
index ff13ae6bf..fe7911ae3 100644
--- a/toolsrc/include/vcpkg/vcpkgcmdarguments.h
+++ b/toolsrc/include/vcpkg/vcpkgcmdarguments.h
@@ -86,6 +86,7 @@ namespace vcpkg
static VcpkgCmdArguments create_from_arg_sequence(const std::string* arg_begin, const std::string* arg_end);
std::unique_ptr<std::string> vcpkg_root_dir;
+ std::unique_ptr<std::string> scripts_root_dir;
std::unique_ptr<std::string> triplet;
std::unique_ptr<std::vector<std::string>> overlay_ports;
std::unique_ptr<std::vector<std::string>> overlay_triplets;
diff --git a/toolsrc/include/vcpkg/vcpkgpaths.h b/toolsrc/include/vcpkg/vcpkgpaths.h
index a30e0c653..ce442858b 100644
--- a/toolsrc/include/vcpkg/vcpkgpaths.h
+++ b/toolsrc/include/vcpkg/vcpkgpaths.h
@@ -47,7 +47,8 @@ namespace vcpkg
struct VcpkgPaths
{
- static Expected<VcpkgPaths> create(const fs::path& vcpkg_root_dir,
+ static Expected<VcpkgPaths> create(const fs::path& vcpkg_root_dir,
+ const Optional<fs::path>& vcpkg_scripts_root_dir,
const std::string& default_vs_path,
const std::vector<std::string>* triplets_dirs);