From 570fc6a4354dd78a79d5d9d7a5797987a6007248 Mon Sep 17 00:00:00 2001 From: yage Date: Mon, 23 Oct 2023 12:47:53 -0600 Subject: [PATCH] v3.6.6 ===================================================================== --- Changes ------------------------------ - Allow CI more leniency in preparing aws environment --- zsh/lib/cloud/aws/cli.module.zsh | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/zsh/lib/cloud/aws/cli.module.zsh b/zsh/lib/cloud/aws/cli.module.zsh index 4274e3b..a84cb9b 100644 --- a/zsh/lib/cloud/aws/cli.module.zsh +++ b/zsh/lib/cloud/aws/cli.module.zsh @@ -9,11 +9,15 @@ REQUIRED_ENV+=() ##################################################################### AWS() { - REQUIRED_ENV=(AWS_REGION AWS_ACCOUNT AWS_PROFILE) CHECK_ENVIRONMENT || return 1 + local ARGS=() - aws \ - --profile $AWS_PROFILE \ - --region $AWS_REGION \ - --output json \ - $@ + ARGS+=(--output json) + + [ ! $CI ] && { + REQUIRED_ENV=(AWS_REGION AWS_ACCOUNT AWS_PROFILE) CHECK_ENVIRONMENT || return 1 + ARGS+=(--profile $AWS_PROFILE) + ARGS+=(--region $AWS_REGION) + } + + aws ${ARGS[@]} $@ }