Commit Graph

3 Commits

Author SHA1 Message Date
Jeffrey Paul f8bd3147a4 Refactored logging to use custom logger and set default logger. 2024-05-14 04:46:27 -07:00
Jeffrey Paul 24c6ebe407 aider: Add init() function to replace default logger in custom_logger.go.
# Aider chat conversation:

USER: the init() function in `custom_logger.go` is missing, on package initialization it should replace the log/slog default logger.

ASSISTANT: To add the `init()` function in `custom_logger.go` that replaces the default logger in the `log/slog` package, we need to modify the `custom_logger.go` file.

Here is the *SEARCH/REPLACE block*:

custom_logger.go
```go
<<<<<<< SEARCH
func NewCustomLogger() *CustomLogger {
=======
func init() {
	slog.SetDefaultLogger(NewCustomLogger())
}

func NewCustomLogger() *CustomLogger {
>>>>>>> REPLACE
```
2024-05-14 04:41:27 -07:00
Jeffrey Paul f21c916eb3 initial 2024-05-13 21:43:47 -07:00