joshmedeski / sesh

Smart session manager for the terminal
MIT License
410 stars 16 forks source link

chore: Add logger #128

Open alcb1310 opened 6 days ago

alcb1310 commented 6 days ago

Adds a structured logger to the project

Usage

Define your logs by priority: Debug, Info, Warn and Error by adding the following to the code

import "log/slog"

slog.Debug("Debug message")
slog.Info("Info message")
slog.Warn("Warn message")
slog.Error("Error message")

To set the debug level when running:

ENV=debug sesh

Just need to change the debug text for info or warn, error logs will always be logged