Skip to content

Instantly share code, notes, and snippets.

Avatar
:shipit:
oof

Ameer Shaikh TheNetJedi

:shipit:
oof
View GitHub Profile
@TheNetJedi
TheNetJedi / ExportLambdaFunctions.sh
Last active Feb 3, 2020
Bash script to download all your Lambda functions.
View ExportLambdaFunctions.sh
#!/usr/bin/env bash
#You need to have aws-cli installed and configured
#Credits to Reddit user u/aa93 for the suggestions
mkdir code
aws lambda list-functions | \
grep FunctionName | \
cut -d '"' -f4 | \
while read -r name; do
aws lambda get-function --function-name $name | tail -n 3 | egrep -o 'https?://[^ ]+' | sed 's/"//' | xargs wget -O ./code/$name.zip