Fatal logs an error message and exits the program with code 1.
It uses slog.Error internally and then calls os.Exit(1).
This provides backward compatibility with log.Fatal behavior.
Fatalf logs a formatted error message and exits the program with code 1.
It uses slog.Error internally and then calls os.Exit(1).
This provides backward compatibility with log.Fatalf behavior.
Init initializes slog using environment variables:
- GNSSTOOLS_LOG_FORMAT: "text" (default) or "json"
- GNSSTOOLS_LOG_LEVEL: "debug", "info" (default), "warn", "error"
- GNSSTOOLS_LOG_SOURCE: "true" to include source information