Files
katenary/doc/docs/packages/internal/logger.md

188 lines
2.9 KiB
Markdown
Raw Normal View History

2025-09-15 13:36:22 +02:00
<!-- Code generated by gomarkdoc. DO NOT EDIT -->
# logger
```go
import "katenary.io/internal/logger"
```
Package logger provides simple logging functions with icons and colors.
2026-05-03 21:21:38 +02:00
## Constants
<a name="ColorGreen"></a>
```go
const (
ColorGreen = "\033[38;5;34m"
ColorRed = "\033[38;5;196m"
ColorOrange = "\033[38;5;214m"
ColorWarning = "\033[38;5;214m"
)
```
<a name="Failure"></a>
## func Failure
2025-09-15 13:36:22 +02:00
```go
func Failure(msg ...any)
```
Failure prints a failure message.
<a name="Failuref"></a>
2026-05-03 21:21:38 +02:00
## func Failuref
```go
func Failuref(format string, msg ...any)
```
Failuref prints a formatted failure message.
<a name="Fatal"></a>
2026-05-03 21:21:38 +02:00
## func Fatal
```go
func Fatal(msg ...any)
```
Fatal prints a fatal error message and exits with code 1.
<a name="Fatalf"></a>
2026-05-03 21:21:38 +02:00
## func Fatalf
```go
func Fatalf(format string, msg ...any)
```
Fatalf prints a fatal error message with formatting and exits with code 1.
2026-05-03 21:21:38 +02:00
<a name="FlushWarnings"></a>
## func FlushWarnings
```go
func FlushWarnings()
```
FlushWarnings prints all collected warnings at the end of the conversion.
2025-09-15 13:36:22 +02:00
<a name="Info"></a>
2026-05-03 21:21:38 +02:00
## func Info
2025-09-15 13:36:22 +02:00
```go
func Info(msg ...any)
```
Info prints an informational message.
<a name="Infof"></a>
2026-05-03 21:21:38 +02:00
## func Infof
```go
func Infof(format string, msg ...any)
```
Infof prints a formatted informational message.
2025-09-15 13:36:22 +02:00
<a name="Log"></a>
2026-05-03 21:21:38 +02:00
## func Log
2025-09-15 13:36:22 +02:00
```go
func Log(icon Icon, msg ...any)
```
Log prints a message with a custom icon.
<a name="Logf"></a>
2026-05-03 21:21:38 +02:00
## func Logf
```go
func Logf(icon Icon, format string, msg ...any)
```
Logf prints a formatted message with a custom icon.
<a name="Print"></a>
2026-05-03 21:21:38 +02:00
## func Print
```go
func Print(msg ...any)
```
Print prints a message without icon.
<a name="Printf"></a>
2026-05-03 21:21:38 +02:00
## func Printf
```go
func Printf(format string, msg ...any)
```
Printf prints a formatted message without icon.
2025-09-15 13:36:22 +02:00
<a name="Success"></a>
2026-05-03 21:21:38 +02:00
## func Success
2025-09-15 13:36:22 +02:00
```go
func Success(msg ...any)
```
Success prints a success message.
<a name="Successf"></a>
2026-05-03 21:21:38 +02:00
## func Successf
```go
func Successf(format string, msg ...any)
```
Successf prints a formatted success message.
2025-09-15 13:36:22 +02:00
<a name="Warn"></a>
2026-05-03 21:21:38 +02:00
## func Warn
2025-09-15 13:36:22 +02:00
```go
func Warn(msg ...any)
```
Warn prints a warning message.
<a name="Warnf"></a>
2026-05-03 21:21:38 +02:00
## func Warnf
```go
func Warnf(format string, msg ...any)
```
Warnf prints a formatted warning message.
2025-09-15 13:36:22 +02:00
<a name="Icon"></a>
2026-05-03 21:21:38 +02:00
## type Icon
2025-09-15 13:36:22 +02:00
Icon is a unicode icon
```go
type Icon string
```
<a name="IconSuccess"></a>Icons used in katenary.
```go
const (
IconSuccess Icon = "✅"
IconFailure Icon = "❌"
IconWarning Icon = "❕"
IconNote Icon = "📝"
IconWorld Icon = "🌐"
IconPlug Icon = "🔌"
IconPackage Icon = "📦"
IconCabinet Icon = "🗄️"
IconInfo Icon = "🔵"
IconSecret Icon = "🔒"
IconConfig Icon = "🔧"
IconDependency Icon = "🔗"
)
```
Generated by [gomarkdoc](<https://github.com/princjef/gomarkdoc>)