fixes
This commit is contained in:
parent
98f3373325
commit
95d9ce2a6c
@ -59,7 +59,7 @@ function analyze {
|
|||||||
do
|
do
|
||||||
if [ "${ANALYZE_VERBOSE}" -eq "0" ]
|
if [ "${ANALYZE_VERBOSE}" -eq "0" ]
|
||||||
then
|
then
|
||||||
check_sell_conditions ${g_tmp}/${tmpfile} "${f_strategy}" >>${g_tmp}/output-${tmpfile} 2>&1
|
check_sell_conditions ${g_tmp}/${tmpfile} "${f_strategy}" >>${g_tmp}/output-${tmpfile} #2>&1
|
||||||
else
|
else
|
||||||
check_sell_conditions ${g_tmp}/${tmpfile} "${f_strategy}" 2>&1 | tee -a ${g_tmp}/output-${tmpfile}
|
check_sell_conditions ${g_tmp}/${tmpfile} "${f_strategy}" 2>&1 | tee -a ${g_tmp}/output-${tmpfile}
|
||||||
fi
|
fi
|
||||||
@ -68,16 +68,11 @@ function analyze {
|
|||||||
if ! [ -f "${g_tmp}/open-${tmpfile}" ]
|
if ! [ -f "${g_tmp}/open-${tmpfile}" ]
|
||||||
then
|
then
|
||||||
f_market_performance=$(grep "^$time" data/botdata/MARKET_PERFORMANCE | tail -n1 | cut -d: -f4 | cut -d"%" -f1 | sed 's/ *//')
|
f_market_performance=$(grep "^$time" data/botdata/MARKET_PERFORMANCE | tail -n1 | cut -d: -f4 | cut -d"%" -f1 | sed 's/ *//')
|
||||||
if [ -z "${f_market_performance}" ]
|
|
||||||
then
|
|
||||||
g_echo_note "No market performanvce data found - forcing good market (100)"
|
|
||||||
f_market_performance=100
|
|
||||||
fi
|
|
||||||
for f_strategy in $(find strategies -name "buy.*.conf" -type f)
|
for f_strategy in $(find strategies -name "buy.*.conf" -type f)
|
||||||
do
|
do
|
||||||
if [ "${ANALYZE_VERBOSE}" -eq "0" ]
|
if [ "${ANALYZE_VERBOSE}" -eq "0" ]
|
||||||
then
|
then
|
||||||
check_buy_conditions ${g_tmp}/${tmpfile} "${f_strategy}" >>${g_tmp}/output-${tmpfile} 2>&1 || break
|
check_buy_conditions ${g_tmp}/${tmpfile} "${f_strategy}" >>${g_tmp}/output-${tmpfile} #2>&1 || break
|
||||||
else
|
else
|
||||||
check_buy_conditions ${g_tmp}/${tmpfile} "${f_strategy}" 2>&1 | tee -a ${g_tmp}/output-${tmpfile}
|
check_buy_conditions ${g_tmp}/${tmpfile} "${f_strategy}" 2>&1 | tee -a ${g_tmp}/output-${tmpfile}
|
||||||
fi
|
fi
|
||||||
|
@ -35,6 +35,19 @@ function get_vars_from_csv {
|
|||||||
get_var_from_line price_change_14_day 20
|
get_var_from_line price_change_14_day 20
|
||||||
get_var_from_line price_change_30_day 21
|
get_var_from_line price_change_30_day 21
|
||||||
|
|
||||||
|
if [ -z "${f_market_performance}" ]
|
||||||
|
then
|
||||||
|
if [ -z "${BOT}" ]
|
||||||
|
then
|
||||||
|
g_echo_note "Analyze: No market performanvce data found - forcing good market (100)"
|
||||||
|
f_market_performance=100
|
||||||
|
else
|
||||||
|
g_echo_note "Bot: No market performanvce data found - forcing bad market (-100)"
|
||||||
|
f_market_performance=-100
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function get_var_from_line {
|
function get_var_from_line {
|
||||||
|
Loading…
Reference in New Issue
Block a user