From a7cc305a3a6e2886a4f7ec7b8fd9943ff45f286d Mon Sep 17 00:00:00 2001 From: Klaus Aehlig Date: Tue, 20 Feb 2024 12:00:57 +0100 Subject: git repo fetch: support "inherit env" When fetching git repositories, just-mr routinely shells out to git. In this case, allow the user to specify via "inherit env", which environment variables from the host environment should be made available in this action. Typical variables to inherit are ones providing credentials, like SSH_AUTH_SOCK. As the repository description specifies the commit that will be taken, and hence the resulting tree, correctness is not affected by the environement leaking in here. --- src/other_tools/root_maps/commit_git_map.hpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src/other_tools/root_maps/commit_git_map.hpp') diff --git a/src/other_tools/root_maps/commit_git_map.hpp b/src/other_tools/root_maps/commit_git_map.hpp index fd1530af..423393fb 100644 --- a/src/other_tools/root_maps/commit_git_map.hpp +++ b/src/other_tools/root_maps/commit_git_map.hpp @@ -35,6 +35,7 @@ struct GitRepoInfo { std::string repo_url{}; std::string branch{}; std::string subdir{}; /* key */ + std::vector inherit_env{}; std::vector mirrors{}; // name of repository for which work is done; used in progress reporting std::string origin{}; -- cgit v1.2.3