fix(sxmo): simplify sxmo_timezonechange.sh to always use the Alpine flow
SXMO_OS is always bananarchy (an Alpine derivative) on this device, so the SXMO_OS case, the change_systemd branch, and the nixos branch were dead code. Drop them and always run the Alpine flow (doas setup-timezone -z), which is what bananarchy uses.
This commit is contained in:
@@ -15,15 +15,6 @@ change_alpine() {
|
|||||||
echo "Timezone changed ok"
|
echo "Timezone changed ok"
|
||||||
}
|
}
|
||||||
|
|
||||||
change_systemd() {
|
|
||||||
echo "Changing timezone to $1"
|
|
||||||
|
|
||||||
timedatectl set-timezone "$1"
|
|
||||||
sxmo_hook_statusbar.sh time
|
|
||||||
|
|
||||||
echo "Timezone changed ok"
|
|
||||||
}
|
|
||||||
|
|
||||||
menu() {
|
menu() {
|
||||||
zoneinfo_dir=$(xdg_data_path zoneinfo)
|
zoneinfo_dir=$(xdg_data_path zoneinfo)
|
||||||
T="$(
|
T="$(
|
||||||
@@ -39,12 +30,7 @@ if [ $# -gt 0 ]; then
|
|||||||
trap "read -r" EXIT
|
trap "read -r" EXIT
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
case "$SXMO_OS" in
|
change_alpine "$@"
|
||||||
alpine|postmarketos|bananarchy) change_alpine "$@";;
|
|
||||||
arch|archarm|debian) change_systemd "$@";;
|
|
||||||
nixos) echo "Change the timezone in configuration.nix with time.timeZone = \"[timezone]\"";;
|
|
||||||
*) echo "Changing the timezone isn't implemented on your distro yet";;
|
|
||||||
esac
|
|
||||||
else
|
else
|
||||||
menu
|
menu
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user