Last active
June 20, 2022 05:00
-
-
Save shuymn/974d0fb4e04921954e459d5286caddee to your computer and use it in GitHub Desktop.
aws-vault utility functions
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ExportAwsVault() { | |
local profile | |
profile=$(aws-vault list --profiles | fzf) && | |
unset AWS_VAULT && | |
export $(aws-vault exec "$profile" --prompt=osascript -- env | grep AWS_) | |
} | |
# alias eva='ExportAwsVault' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
UnsetAwsVault() { | |
unset $(env | grep AWS_ | sed 's/=.*//g') | |
} | |
# alias uva='UnsetAwsVault' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment