Improve output again
This commit is contained in:
parent
5a00aee3f2
commit
f7ebc0409f
13
badgy
13
badgy
@ -68,20 +68,23 @@ getCapitalTime()
|
||||
st=$(date --date="${starts}" +'%s')
|
||||
ends=$(echo ${cl} | jq -rc ".end")
|
||||
echo
|
||||
echo " $(date --date=${starts} +"%A %d %B %Y:")"
|
||||
echo " Start: $(date --date=${starts} +'%H:%M')"
|
||||
echo -n " $(date --date=${starts} +"%A %d %B %Y") "
|
||||
echo -n "$(date --date=${starts} +'%H:%M') to "
|
||||
if [ "${ends}" != "null" ];then
|
||||
ed=$(date --date="${ends}" +'%s')
|
||||
echo " End: $(date --date=${ends} +'%H:%M')"
|
||||
echo -n "$(date --date=${ends} +'%H:%M')"
|
||||
else
|
||||
ed=$(date +'%s')
|
||||
echo " End: running"
|
||||
echo -n "....."
|
||||
fi
|
||||
dr=$(( dr + (ed - st)))
|
||||
timerCount="$((ed - st))"
|
||||
echo -n " ($(s2h ${timerCount}))"
|
||||
dr=$(( dr + timerCount))
|
||||
done
|
||||
|
||||
nbl=$(getNewBalance "${sl}" "${dr}")
|
||||
|
||||
echo
|
||||
echo
|
||||
echo "Your time balance is: ${sl}"
|
||||
echo "Today you worked: $(s2h ${dr})"
|
||||
|
Loading…
Reference in New Issue
Block a user