timezone

package
v1.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 4, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package timezone sets the process default timezone from environment variables. Call InitFromEnv immediately after loading .env so time.Local and time.Now match APP_TIMEZONE or TZ.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitFromEnv

func InitFromEnv() error

InitFromEnv sets TZ for the process from APP_TIMEZONE (if set), else TZ, else UTC. The value must be a valid IANA zone name (e.g. America/New_York, UTC).

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL