diff --git a/VERSION b/VERSION index 56d0235..27bdbf2 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -2.0.8,prepare crypto sim enhanced +2.0.9,prepare crypto sim enhanced diff --git a/research/load_crypto_md.sh b/research/load_crypto_md.sh index 46e3735..dd36a89 100755 --- a/research/load_crypto_md.sh +++ b/research/load_crypto_md.sh @@ -1,7 +1,10 @@ #!/usr/bin/env bash usage() { - echo "Usage: $0 [-h ] [-d (yesterday*)] [-s (cvttdata/cloud21*)>]" + echo -n "Usage: $0 [-h ]" + echo -n " [-d (yesterday*)]" + echo -n " [-s (cvttdata/cloud21*)>]" + echo " [-t (/opt/jupyter_gpu/data/crypto_md)]" exit 1 } @@ -19,11 +22,15 @@ is_valid() { return 1 } +# ------- D E F A U L T S date="" host=hs01 source=cloud21 +TargetDir="/opt/jupyter_gpu/data/crypto_md" +# ------- D E F A U L T S -while getopts ":h:d:s:" opt; do + +while getopts ":h:d:s:t:" opt; do case ${opt} in d ) date=$OPTARG @@ -34,6 +41,9 @@ while getopts ":h:d:s:" opt; do s ) source=$OPTARG ;; + t ) + TargetDir=$OPTARG + ;; \? ) echo "Invalid option: -$OPTARG" >&2 usage @@ -82,7 +92,6 @@ SourceFile=$(date -d ${date} "+%Y%m%d.mktdata.db") SourceFileZip="${SourceFile}.gz" SourceFilePath=$(date -d ${date} "+${SourceRootDir}/%Y/%m/${SourceFileZip}") -TargetDir="/opt/jupyter_gpu/data/crypto_md" TargetFile=$(date -d ${date} "+%Y%m%d.mktdata.ohlcv.db") TargetFilePath="${TargetDir}/${TargetFile}"