Home-manager not respecting system TZ?

I’m setting up home-manager overlaying my Fedora 33, all’s going well, everything’s nice enough, except that Emacs thinks my timezone offset is 0 which makes org-mode timestamps, etc, quite a bit more of a pain than I’d like. I briefly home-managed coreutils for date, which also had the 0 offset. my understanding is that this isn’t the expected behavior. :slight_smile:

(current-time-zone) reports (0 "America")
(getenv "TZ") reports America/Los_Angeles

I’m experimenting with dynamically generating my home.nix so I can’t just link to the whole thing simply to evaluate without needing to copy it somewhere, but here’s the template.

{ config, pkgs, lib, ... }:

with builtins;
in rec {
  programs.home-manager.enable = true;
  home.stateVersion = "21.05";

  manual.html.enable = true;
  manual.json.enable = true;
  news.display = "silent";



  home.username = "rrix";
  home.homeDirectory = "/home/rrix";

  home.language.base = "en_US";
  home.language.time = "en_GB";

  programs.emacs = {
    enable = true;
    extraPackages = (epkgs: with epkgs; [

I have asked around and I can’t really make heads or tails of this, i know that this isn’t the expected or intended behavior; it’s not like setting LC_TIME is going to affect the tzdata itself, i just want a 24 hour clock… not even sure what leads to chase here…

1 Like

I ended up fixing this by setting TZDIR to the system TZDIR, i’m sure I could get that calculated to a nixos derivation, but this is Good Enough until I reinstall w/ nixos:

bash_profile gets:

export TZ=America/Los_Angeles
export TZDIR=/usr/share/zoneinfo
1 Like