I am trying to get the tz database name with golang running on Debian, such as "US/Arizona" but didn't find a way. I can get timezone abbreviation but it is not what I want.
I searched online and didn't find any clue.
Any idea, folks?
I am trying to get the tz database name with golang running on Debian, such as "US/Arizona" but didn't find a way. I can get timezone abbreviation but it is not what I want.
I searched online and didn't find any clue.
Any idea, folks?
finally I go with the code below
timezone, err := exec.Command("cat", "/etc/timezone").CombinedOutput()