From e602c010c6bf5bce6c15a309294ae836309d91e4 Mon Sep 17 00:00:00 2001 From: Michael Anckaert Date: Tue, 8 May 2018 14:24:36 +0200 Subject: [PATCH] Added first version of aws plugin --- plugins/aws/aws.plugin.sh | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 plugins/aws/aws.plugin.sh diff --git a/plugins/aws/aws.plugin.sh b/plugins/aws/aws.plugin.sh new file mode 100644 index 0000000..a74ed86 --- /dev/null +++ b/plugins/aws/aws.plugin.sh @@ -0,0 +1,20 @@ +# aws.plugin.sh +# Author: Michael Anckaert +# Based on oh-my-zsh AWS plugin +# +# command 'agp' returns the selected AWS profile (aws get profile) +# command 'asp' sets the AWS profile to use (aws set profile) +# + +export AWS_HOME=~/.aws + +function agp { + echo $AWS_DEFAULT_PROFILE +} + +function asp { + local rprompt=${RPROMPT//} + + export AWS_DEFAULT_PROFILE=$1 + export AWS_PROFILE=$1 +}