fix: lower intervals in raw files 'already downloaded in the last X minutes'

This commit is contained in:
olli 2024-02-07 09:13:27 +01:00
parent f396df65fe
commit 58c1ed1bcf

View File

@ -3,7 +3,7 @@ function get_asset {
g_echo_note "RUNNING FUNCTION ${FUNCNAME} $@" g_echo_note "RUNNING FUNCTION ${FUNCNAME} $@"
local f_ASSET="$1" local f_ASSET="$1"
# write asset hist file with macd and rsi # write asset hist file
local f_ASSET_HIST_FILE="asset-histories/${f_ASSET}.history-raw.csv" local f_ASSET_HIST_FILE="asset-histories/${f_ASSET}.history-raw.csv"
if find "${f_ASSET_HIST_FILE}" -mmin -${INTERVAL_MIN} | grep -q "${f_ASSET_HIST_FILE}" if find "${f_ASSET_HIST_FILE}" -mmin -${INTERVAL_MIN} | grep -q "${f_ASSET_HIST_FILE}"
@ -43,14 +43,11 @@ function get_asset {
[ ${FULL_LOOP} == 0 ] && return 0 [ ${FULL_LOOP} == 0 ] && return 0
f_ASSET_HIST_FILE="asset-histories/${f_ASSET}.history.csv" f_ASSET_HIST_FILE="asset-histories/${f_ASSET}.history.csv"
#if [ ${f_linecount} -lt 30 ] && [ ${f_lines} -ge 50 ] && [ ${INTERVAL} -lt 300 ] if find "${f_ASSET_HIST_FILE}" -mmin -${INTERVAL_MIN} | grep -q "${f_ASSET_HIST_FILE}"
#then then
# g_echo_note "${f_ASSET_HIST_FILE}: set price to 5 minute period" g_echo_note "${f_ASSET_HIST_FILE} already downloaded in the last ${INTERVAL_MIN} minutes"
# if ! echo "${f_timestamp}" | egrep -q ":[0-5]0:|:[0-5]5:" return 0
# then fi
# return 0
# fi
#fi
# headline # headline
#[ -s "${f_ASSET_HIST_FILE}" ] || echo "${csv_headline}" >"${f_ASSET_HIST_FILE}" #[ -s "${f_ASSET_HIST_FILE}" ] || echo "${csv_headline}" >"${f_ASSET_HIST_FILE}"