test
This commit is contained in:
parent
57d4348a30
commit
37b3fe3cb4
@ -8,20 +8,15 @@ source "$SCRIPTDIR/common/load-defaults.sh"
|
||||
|
||||
|
||||
get_tz() {
|
||||
|
||||
local tz_type="$1"
|
||||
|
||||
printf "$COL_LIGHT_BLUE" "* Checking Current Timezone in $tz_type"
|
||||
|
||||
if [ "$tz_type" == "/etc/timezone" ]; then
|
||||
current_timezone=`cat /etc/timezone`
|
||||
elif [ "$tz_type" == "timedatectl" ]; then
|
||||
current_timezone=$(timedatectl | grep "zone" | sed -e 's/^[ ]*Time zone: \(.*\) (.*)$/\1/g')
|
||||
fi
|
||||
|
||||
printf "$COL_LIGHT_BLUE" "* Timezone in $tz_type is set to $current_timezone"
|
||||
|
||||
|
||||
return $current_timezone
|
||||
}
|
||||
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user