You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Formats a token count as a compact human-readable string. Zero values render as `"-"` to indicate no data; non-zero values use SI suffixes for readability.
777
+
778
+
```go
779
+
console.FormatTokens(0) // "-"
780
+
console.FormatTokens(500) // "500"
781
+
console.FormatTokens(1500) // "1.5K"
782
+
console.FormatTokens(1200000) // "1.2M"
783
+
```
784
+
773
785
### `ToRelativePath(path string) string`
774
786
775
787
Converts an absolute path to a path relative to the current working directory. If the relative path would require traversing parent directories (`..`), the original absolute path is returned unchanged.
@@ -803,6 +815,22 @@ Returns the `gh aw` ASCII art banner as a styled string.
803
815
804
816
Prints the banner to `os.Stderr`.
805
817
818
+
### `SetTimeLocation(location *time.Location)`
819
+
820
+
Configures the `time.Location` used when rendering `time.Time` values in `RenderStruct`. When set, rendered timestamps include the UTC offset (e.g. `"2026-01-15 09:30:00 UTC+09:00"`). Pass `nil` to reset to the default (`"2006-01-02 15:04:05"` in the local zone).
821
+
822
+
### `ResetTimeLocation()`
823
+
824
+
Clears any configured time location override, restoring the default formatting behaviour.
0 commit comments