Right now, I could not find a way to use environment variables in .bazelrc.
What i want to do is
$export GIT_ROOT=/workspace/project_name
and then in /workspace/project_name/.bazelrc
$cat /workspace/project_name/.bazelrc
build --action_env=GIT_ROOT="$GIT_ROOT" # where $GIT_ROOT is the environment variable.
Pass on Environment variable to a bazel rule which runs a script.
Description of the problem / feature request:
Right now, I could not find a way to use environment variables in .bazelrc.
What i want to do is
Feature requests: what underlying problem are you trying to solve with this feature?
Pass on Environment variable to a bazel rule which runs a script.
Bugs: what's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
What operating system are you running Bazel on?
Linux and mac
What's the output of
bazel info release?latest
If
bazel info releasereturns "development version" or "(@Non-Git)", tell us how you built Bazel.What's the output of
git remote get-url origin ; git rev-parse master ; git rev-parse HEAD?Have you found anything relevant by searching the web?
Read,
Any other information, logs, or outputs that you want to share?