@@ -57,32 +57,48 @@ def invoke(self, ctx):
57
57
58
58
# Print a separation header
59
59
util .log (f'\n \n { "-" * 50 } ' )
60
- util .log (cmd_name )
61
- util .log (f'{ "-" * 50 } \n \n ' )
60
+ util .log (f"\n { cmd_name } \n " )
62
61
63
62
if cmd_name in skip or cmd_name .replace ("-" , "_" ) in skip :
64
63
util .log ("*** Skipping based on skip config" )
64
+ util .log (f'{ "-" * 50 } \n \n ' )
65
65
return
66
66
67
67
# Handle all of the parameters
68
68
for param in self .commands [cmd_name ].get_params (ctx ):
69
+ name = param .name
70
+ assert name is not None
71
+
69
72
# Defer to env var overrides
70
73
if param .envvar and os .environ .get (str (param .envvar )):
74
+ value = os .environ [str (param .envvar )]
75
+ if "token" in name .lower ():
76
+ value = "***"
77
+ util .log (f"Using env value for { name } : { value } " )
71
78
continue
72
- name = param . name
73
- assert name is not None
79
+
80
+ # Handle cli and options overrides.
74
81
if name in options or name .replace ("_" , "-" ) in options :
75
82
arg = f"--{ name .replace ('_' , '-' )} "
76
83
# Defer to cli overrides
77
84
if arg not in ctx .args :
78
85
val = options .get (name , options .get (name .replace ("_" , "-" )))
86
+ util .log (f"Adding option override for { arg } " )
79
87
if isinstance (val , list ):
80
88
for v in val :
81
89
ctx .args .append (arg )
82
90
ctx .args .append (v )
83
91
else :
84
92
ctx .args .append (arg )
85
93
ctx .args .append (val )
94
+ continue
95
+ else :
96
+ util .log (f"Using cli arg for { name } " )
97
+ continue
98
+
99
+ util .log (f"Using default value for { name } " )
100
+
101
+ util .log (f'{ "-" * 50 } \n \n ' )
86
102
87
103
# Handle before hooks
88
104
before = f"before-{ cmd_name } "
0 commit comments