Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Setup ¶
Setup configures the global slog logger based on the given log level.
Supported levels: "off", "debug", "info", "warn", "error".
Logging is DISABLED by default: when level is "off", "none" or empty, every log call becomes a no-op (records are discarded). This keeps the terminal UI clean unless the user explicitly opts in via --log-level or rysh.config.yaml.
When level is "debug", logs are written to /tmp/rysh/logs/ in addition to stderr. The log file is named rysh-<session>-<timestamp>.log.
For "info", "warn" and "error", logs go to stderr only (colorized via tint).
func ValidLevel ¶
ValidLevel returns true if the level string is a recognized log level. "off" and "none" are accepted as explicit ways to disable logging.
Types ¶
This section is empty.