aboutsummaryrefslogtreecommitdiff
path: root/pw_cli
diff options
context:
space:
mode:
authorRob Mohr <mohrr@google.com>2020-04-03 08:59:12 -0700
committerRob Mohr <mohrr@google.com>2020-04-03 08:59:12 -0700
commitd596a539eeb52c466c81f5b5290aa6f81e5439e7 (patch)
treecae8d00be61b9c80cd04e40581541117bf1c92c6 /pw_cli
parent9abe3c7a6a28d732f21ead4213eccbbe8f6307b1 (diff)
downloadpigweed-d596a539eeb52c466c81f5b5290aa6f81e5439e7.tar.gz
pw_env_setup: use env vars for bootstrap opts
The following environment variables are now used to pass options into pw_env_setup: * PW_CIPD_PACKAGEFILES * PW_VIRTUALENV_REQUIREMENTS * PW_VIRTUALENV_SETUPPYROOTS * PW_CARGO_PACKAGEFILES Each of these variables can contain multiple entries separated by ':' (or ';' on Windows) like PATH. However, they will also be interpreted as globs, so PW_VIRTUALENV_REQUIREMENTS="/foo/bar/*/requirements.txt" is perfectly valid. They should be full paths. Projects depending on Pigweed should prepend to these variables and then invoke Pigweed's bootstrap.sh (or bootstrap.bat). Users wanting additional setup should set these variables in their shell init files. Change-Id: Ibf0f1d5279028856a590ffc50850df2174c38e28 Bug: 138
Diffstat (limited to 'pw_cli')
-rw-r--r--pw_cli/py/pw_cli/env.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/pw_cli/py/pw_cli/env.py b/pw_cli/py/pw_cli/env.py
index 1784c60b5..613fc51ab 100644
--- a/pw_cli/py/pw_cli/env.py
+++ b/pw_cli/py/pw_cli/env.py
@@ -40,6 +40,11 @@ def pigweed_environment_parser() -> envparse.EnvironmentParser:
parser.add_var('PW_LUCI_CIPD_INSTALL_DIR')
parser.add_var('PW_CIPD_INSTALL_DIR')
+ parser.add_var('PW_CIPD_PACKAGE_FILES')
+ parser.add_var('PW_VIRTUALENV_REQUIREMENTS')
+ parser.add_var('PW_VIRTUALENV_SETUP_PY_ROOTS')
+ parser.add_var('PW_CARGO_PACKAGE_FILES')
+
return parser