mylinuxforwork / dotfiles

The ML4W Dotfiles for Hyprland - An advanced and full-featured configuration for the dynamic tiling window manager Hyprland including an easy to use installation script for Arch based Linux distributions.
GNU General Public License v3.0
1.01k stars 80 forks source link

[BUG] Waybar clock using UTC time instead of currently set timezone #237

Closed elliottophellia closed 1 month ago

elliottophellia commented 1 month ago

Describe the bug I just re-install my Arch yesterday and then install ML4W Dotfiles from AUR, but I just realized today that my clock using UTC time, I thought maybe my Arch timezone bugged then I check timedatectl but :

❯ timedatectl
               Local time: Tue 2024-09-10 21:11:07 WIB
               Universal time: Tue 2024-09-10 14:11:07 UTC
               RTC time: Tue 2024-09-10 14:11:07
               Time zone: Asia/Jakarta (WIB, +0700)
               System clock synchronized: yes
               NTP service: active
               RTC in local TZ: no

I tried to do something about it and goto /home/lia/.config/waybar/module.json find clock and then add "timezone":"Asia/Jakarta", in it, but still got nothing.

Maybe its about RTC in local TZ: no i though, so I did sudo timedatectl set-local-rtc 1 and reload the Waybar, change its Theme, or change the fmt format, but still in UTC.

Maybe I need to reboot? so I did reboot and after login SDDM, my clock still on UTC.

To Reproduce Steps to reproduce the behavior:

  1. Go to dekstop
  2. Find out clock is on UTC ( idk maybe do fresh install and set timezone to Asia/Jakarta )

Expected behavior Clock set to UTC

Screenshots ss

Distribution (please complete the following information):

Additional context X

elliottophellia commented 1 month ago

Update: I found stupid way to fix this

cd ~/Downloads
wget https://archive.archlinux.org/packages/t/tzdata/tzdata-2024a-2-x86_64.pkg.tar.zst
sudo pacman -U tzdata-2024a-2-x86_64.pkg.tar.zst

then ignore tzdata from update

sudo sed -i '/^#IgnorePkg/s/^#//' /etc/pacman.conf
sudo sed -i '/^IgnorePkg/s/$/ tzdata/' /etc/pacman.conf

then reboot

mylinuxforwork commented 1 month ago

https://github.com/mylinuxforwork/dotfiles/wiki/Troubleshooting#wrong-timezone-in-waybar