From dcffc895806f5c2aaade3fce09772e1c9f52504e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20Cornell=C3=A0?= Date: Thu, 30 Jan 2020 13:31:33 +0100 Subject: [PATCH] aws: fix array assignment in asp function Older zsh versions require this syntax change. Fixes #8525 --- plugins/aws/aws.plugin.zsh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plugins/aws/aws.plugin.zsh b/plugins/aws/aws.plugin.zsh index 231ac5ad2..567311372 100644 --- a/plugins/aws/aws.plugin.zsh +++ b/plugins/aws/aws.plugin.zsh @@ -10,7 +10,8 @@ function asp() { return fi - local available_profiles=($(aws_profiles)) + local -a available_profiles + available_profiles=($(aws_profiles)) if [[ -z "${available_profiles[(r)$1]}" ]]; then echo "${fg[red]}Profile '$1' not found in '${AWS_CONFIG_FILE:-$HOME/.aws/config}'" >&2 echo "Available profiles: ${(j:, :)available_profiles:-no profiles found}${reset_color}" >&2