Skip to content

Instantly share code, notes, and snippets.

@garystafford
Last active December 29, 2022 22:51
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 garystafford/0f469d787770de43e7f2728f5ea909fe to your computer and use it in GitHub Desktop.
Save garystafford/0f469d787770de43e7f2728f5ea909fe to your computer and use it in GitHub Desktop.
# Purpose: Unzip raw data files and copy to s3
# Author: Gary A. Stafford
# Date: 2022-12-29
# sh ./raw_date_to_s3.sh
# ** REPLACE ME! **
s3_bucket="<your_s3_bucket_name>"
pushd raw_tickit_data/
unzip tickit_data.zip
popd
declare -a TableArray=("category" "date" "event" "listing" "sale" "user" "venue")
for table in "${TableArray[@]}"; do
aws s3 cp ./raw_tickit_data/$table.txt s3://$s3_bucket/raw_tickit_data/$table/
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment