Fix pattern matching to remove preceding slashes

This commit is contained in:
Hannes Körber
2019-05-20 23:19:23 +02:00
parent 063c14c215
commit de4caeea7e

View File

@@ -4,6 +4,8 @@ set -o nounset
set -o errexit set -o errexit
set -o xtrace set -o xtrace
shopt -s extglob
dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
if [[ ! -e "${dir}/venv" ]] ; then if [[ ! -e "${dir}/venv" ]] ; then
@@ -74,5 +76,5 @@ timestamp="$(date --utc -Iseconds)"
s3 cp \ s3 cp \
--storage-class DEEP_ARCHIVE \ --storage-class DEEP_ARCHIVE \
- \ - \
"s3://${bucket}/${name}-${timestamp}/${filepath##*(/)}.tar.gz.gpg" "s3://${bucket}/${name}-${timestamp}/${filepath##+(/)}.tar.gz.gpg"
done done