calm-artist-46894
01/23/2020, 5:38 AM--build-file-imports
is warn
, what’s the reason to discourage using import in BUILD file?
If I need read the environment variable (e.g. the git branch) and do different things based on if the branch is master. Something like:
def get_version(version):
import os
release = os.getenv("CIRCLE_BRANCH") == "master"
if not release:
version += ".dev"
return version
What is the recommended alternative?average-vr-56795
01/23/2020, 10:49 AMaverage-vr-56795
01/23/2020, 10:50 AMcalm-artist-46894
01/25/2020, 12:35 AM