Skip to content

Instantly share code, notes, and snippets.

@miglen
Created May 2, 2018 11:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save miglen/3b949f73e03ea2d81a1ec20e769d53f9 to your computer and use it in GitHub Desktop.
Save miglen/3b949f73e03ea2d81a1ec20e769d53f9 to your computer and use it in GitHub Desktop.
AWS Helper dotfiles
# Export AWS Credentials File
function export_aws(){
# usage: export_aws filename.csv
# default will be set to credentials.csv if not specified
file="${1:-credentials.csv}"
export AWS_ACCESS_KEY_ID=$(tail -1 ${file} | cut -d, -f 3)
export AWS_SECRET_ACCESS_KEY=$(tail -1 ${file} | cut -d, -f 4)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment