noveriablcgen/utils/infocollector
2023-09-29 15:31:53 +02:00

11 lines
No EOL
265 B
Bash

#!/usr/bin/env bash
function parseTimestampHuman() {
local bootenv="$1"
echo $(date -d "$(echo $bootenv | cut -d_ -f2)" "+%d.%m.%Y") "- $(echo $bootenv | cut -d_ -f3 | sed 's|-|:|g')"
}
parseTimestamp() {
local bootenv="$1"
echo $bootenv | cut -d_ -f2-3
}