Skip to content
Snippets Groups Projects
Unverified Commit 855cf7ee authored by Daniel Ecer's avatar Daniel Ecer Committed by GitHub
Browse files

added pdf download using file list (#56)

parent 40cf553e
No related branches found
No related tags found
No related merge requests found
#!/bin/bash
set -e
CLOUD_FILE_LIST_PATH=${1:-$CLOUD_FILE_LIST_PATH}
PDF_DIR=${2:-$PDF_DIR}
if [ -z "${CLOUD_FILE_LIST_PATH}" ]; then
echo "Error: CLOUD_FILE_LIST_PATH required"
exit 1
fi
if [ -z "${PDF_DIR}" ]; then
echo "Error: PDF_DIR required"
exit 1
fi
echo "downloading dataset pdf from ${CLOUD_FILE_LIST_PATH} to ${PDF_DIR}"
mkdir -p "${PDF_DIR}"
gsutil cat "${CLOUD_FILE_LIST_PATH}" | gsutil -m cp -I "${PDF_DIR}/"
gunzip -f "${PDF_DIR}/"*.gz || true
ls -l "${PDF_DIR}/"
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment