From 4dc1de8d1494536a2503ae56469d53af946a121f Mon Sep 17 00:00:00 2001 From: Matthew Batchelder Date: Tue, 16 Feb 2021 21:39:59 -0500 Subject: [PATCH] Change order of arguments --- commands/exists.sh | 2 +- commands/ls.sh | 2 +- commands/rm.sh | 2 +- commands/sync.sh | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/commands/exists.sh b/commands/exists.sh index d4ccc4d..737280c 100755 --- a/commands/exists.sh +++ b/commands/exists.sh @@ -9,7 +9,7 @@ fi echo "Checking for file existence at s3://${S3_BUCKET}/${FILE} at the ${S3_ENDPOINT}" -the_command="aws s3api head-object --bucket ${S3_BUCKET} --key ${FILE} ${S3_PROFILE} ${ENDPOINT_APPEND} $*" +the_command="aws ${S3_PROFILE} ${ENDPOINT_APPEND} s3api head-object --bucket ${S3_BUCKET} --key ${FILE} $*" echo $the_command diff --git a/commands/ls.sh b/commands/ls.sh index 8936184..624d4da 100755 --- a/commands/ls.sh +++ b/commands/ls.sh @@ -7,7 +7,7 @@ if [ -z "$FILE" ]; then exit 1 fi -the_command="aws s3 ls s3://${S3_BUCKET}/${FILE} ${S3_PROFILE} ${ENDPOINT_APPEND} $*" +the_command="aws ${S3_PROFILE} ${ENDPOINT_APPEND} s3 ls s3://${S3_BUCKET}/${FILE} $*" echo $the_command diff --git a/commands/rm.sh b/commands/rm.sh index d4ee2cd..604dffe 100755 --- a/commands/rm.sh +++ b/commands/rm.sh @@ -7,7 +7,7 @@ if [ -z "$FILE" ]; then exit 1 fi -the_command="aws s3 rm s3://${S3_BUCKET}/${FILE} ${S3_PROFILE} ${ENDPOINT_APPEND} $*" +the_command="aws ${S3_PROFILE} ${ENDPOINT_APPEND} s3 rm s3://${S3_BUCKET}/${FILE} $*" echo $the_command diff --git a/commands/sync.sh b/commands/sync.sh index 346dce6..8942f26 100755 --- a/commands/sync.sh +++ b/commands/sync.sh @@ -2,7 +2,7 @@ set -e -the_command="aws s3 sync ${SOURCE_DIR:-.} s3://${S3_BUCKET}/${DEST_DIR} ${S3_PROFILE} --no-progress ${ENDPOINT_APPEND} $*" +the_command="aws ${S3_PROFILE} ${ENDPOINT_APPEND} s3 sync ${SOURCE_DIR:-.} s3://${S3_BUCKET}/${DEST_DIR} --no-progress $*" echo $the_command