Created
February 19, 2019 14:57
-
-
Save alwalker/82747a018404b74795b216e97535e6ee to your computer and use it in GitHub Desktop.
Get Latest BLOB
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
NEWEST_BLOB=$(az storage blob list \ | |
--account-key $STORAGE_KEY \ | |
--account-name $STORAGE_ACCOUNT \ | |
-c $CONTAINER \ | |
--prefix $PREFIX \ | |
--query "[*].{name: name, date: properties.lastModified } | sort_by([*], &date) | [-1].name") | |
NEWEST_BLOB=$(echo $NEWEST_BLOB | tr -d \") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment