This new release of Log adds support for log/slog, and per-instance styles, and includes bug fixes. You can now use Log as a log/slog handler in your applications. Log comes with its own JSON and Logfmt formatters, on the other hand, Slog uses different handlers for these formats.
Breaking Changes!
Bump the minimum GoLang version to 1.19
Change the default timestamp key from ts to time to match log/slog
Change the default level key from lvl to level to match log/slog
ParseLevel() now returns an error if parse failed to find a level in string
Default levels values changed to be increments of 4 i.e. DebugLevel = -4, InfoLevel = 0, WarnLevel = 4, ...
Global styles are replaced with DefaultStyles() and SetStyles()
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
Bumps github.com/charmbracelet/log from 0.2.5 to 0.3.0.
Release notes
Sourced from github.com/charmbracelet/log's releases.
Commits
1231b7b
fix: lintd1330ba
Merge branch 'main' into slogd96bea2
refactor!: return Error from ParseLevel (#83)bd09619
feat: set custom styles (#84)cafb9c6
chore!: change default timestamp and level key names707eb77
fix: add emoji test9c25f94
refactor: rename files85d52ab
doc: add slog support1487437
chore: downgrade the minimum go version to go1.19588043a
feat: add slog testsDependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting
@dependabot rebase
.Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show