summaryrefslogtreecommitdiff
path: root/plugins/aws/aws.plugin.zsh
diff options
context:
space:
mode:
authorMarc Cornellà <marc.cornella@live.com>2020-01-30 13:31:33 +0100
committerMarc Cornellà <marc.cornella@live.com>2020-01-30 13:32:55 +0100
commitdcffc895806f5c2aaade3fce09772e1c9f52504e (patch)
treed5965f8a52bb962f191e8334d711be4bfe88f615 /plugins/aws/aws.plugin.zsh
parent05a38c8b99ea5bc54e7fdfc1cc1ea6d2729c05e5 (diff)
downloadzsh-dcffc895806f5c2aaade3fce09772e1c9f52504e.tar.gz
zsh-dcffc895806f5c2aaade3fce09772e1c9f52504e.tar.bz2
zsh-dcffc895806f5c2aaade3fce09772e1c9f52504e.zip
aws: fix array assignment in asp function
Older zsh versions require this syntax change. Fixes #8525
Diffstat (limited to 'plugins/aws/aws.plugin.zsh')
-rw-r--r--plugins/aws/aws.plugin.zsh3
1 files changed, 2 insertions, 1 deletions
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