Skip to content
This repository was archived by the owner on Jul 5, 2023. It is now read-only.

Commit 3a5c503

Browse files
committed
Replace variable print value for **** if variable name contains secret in it
1 parent 01fa2d5 commit 3a5c503

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

boostbuild/main.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,10 @@ def main() -> int:
137137
for i, cmd in enumerate(commands):
138138
variables = re.findall("{.*?}", cmd)
139139
for var in variables:
140-
cmd = cmd.replace(var, storage[var])
140+
value = "****"
141+
if "secret" not in var:
142+
value = storage[var]
143+
cmd = cmd.replace(var, value)
141144
print(Fore.GREEN + f"-> [{i + 1}/{total_commands}] - {cmd}")
142145
cmd, *args = cmd.split(" ")
143146
output = call_command(cmd, args)

0 commit comments

Comments
 (0)