@@ -144,12 +144,10 @@ def tf_default_args(paths: PathsHandler) -> tuple:
144144 parameters for OpenTofu/Terraform.
145145 """
146146 common_config_files = tuple (
147- f"-var-file={ common_file .as_posix ()} "
148- for common_file in paths .common_config_dir .glob ("*.tfvars" )
147+ f"-var-file={ common_file .as_posix ()} " for common_file in paths .common_config_dir .glob ("*.tfvars" )
149148 )
150149 account_config_files = tuple (
151- f"-var-file={ account_file .as_posix ()} "
152- for account_file in paths .account_config_dir .glob ("*.tfvars" )
150+ f"-var-file={ account_file .as_posix ()} " for account_file in paths .account_config_dir .glob ("*.tfvars" )
153151 )
154152 return common_config_files + account_config_files
155153
@@ -314,10 +312,12 @@ def validate_for_all_commands(layer, skip_validation=False):
314312 """
315313 logger .debug (f"Checking layer { layer } ..." )
316314 if not skip_validation and not _validate_layout (layer ):
317- raise ExitError (1 ,
315+ raise ExitError (
316+ 1 ,
318317 "Layer configuration doesn't seem to be valid. Exiting.\n "
319318 "If you are sure your configuration is actually correct "
320- "you may skip this validation using the --skip-validation flag." )
319+ "you may skip this validation using the --skip-validation flag." ,
320+ )
321321
322322
323323# ###########################################################################
@@ -352,6 +352,7 @@ def _plan(tf: TFRunner, paths: PathsHandler, args: Sequence[str], working_dir: P
352352 if exit_code := tf .run ("plan" , * tf_default_args (), * args , working_dir = working_dir ):
353353 raise Exit (exit_code )
354354
355+
355356def has_a_plan_file (args : Sequence [str ]) -> bool :
356357 """Determine whether the list of arguments has a plan file at the end.
357358
0 commit comments