diff options
author | kaotisk <kaotisk@arching-kaos.org> | 2025-03-20 00:23:02 +0200 |
---|---|---|
committer | kaotisk <kaotisk@arching-kaos.org> | 2025-03-20 00:23:02 +0200 |
commit | 5469f4d66493433043b780c01ace5d6f48547e84 (patch) | |
tree | c0ffe1b28a728c5e65751fc1bb15e7737f12a2db /lib/_ak_utils | |
parent | 31c7f04352ef2fd47c2962be9c043a8fe902f574 (diff) | |
download | arching-kaos-tools-5469f4d66493433043b780c01ace5d6f48547e84.tar.gz arching-kaos-tools-5469f4d66493433043b780c01ace5d6f48547e84.tar.bz2 arching-kaos-tools-5469f4d66493433043b780c01ace5d6f48547e84.zip |
Possible fix of inability to fetch today's values from YIA
Diffstat (limited to 'lib/_ak_utils')
-rwxr-xr-x | lib/_ak_utils | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/_ak_utils b/lib/_ak_utils index d9204e9..98f6ca0 100755 --- a/lib/_ak_utils +++ b/lib/_ak_utils @@ -33,6 +33,10 @@ function _ak_datetime_human_date_only(){ date -u +%Y%m%d } +function _ak_datetime_human_date_only_yesterday(){ + date --date=yesterday -u +%Y%m%d 2>/dev/null || date -v -1d -u +%Y%m%d 2>/dev/null +} + function _ak_datetime_unix_to_human(){ if [ ! -z $1 ] && [ -n "$1" ] && [ "$(echo $1 | sed -e 's/[0-9]\{10\}//g')" == "" ] then |