feat!: deprecate rulerfmt/statfmt options (#2477)

* feat!: deprecate `rulerfmt`/`statfmt` options

These will be replaced with the ruler file (specified using the
`rulerfile` option).

* Add deprecation comments to involved functions

* Update `CHANGELOG.md`
This commit is contained in:
Joe Lim authored and GitHub committed 2026-03-31 15:23:28 +11:00
1 parent a966b1387c
commit 3db6242620
3 files changed
+6

No files matched your search

+3
View File
@@ -694,6 +694,7 @@ func (ui *ui) drawPromptLine(nav *nav) {
ui.promptWin.print(ui.screen, 0, 0, st, prompt)
}
// Deprecated: Only called by drawRuler, which will eventually be replaced by drawRulerFile
func formatRulerOpt(name, val string) string {
// handle escape character so it doesn't mess up the ruler
val = strings.ReplaceAll(val, "\033", "\033[7m\\033\033[0m")
@@ -706,6 +707,7 @@ func formatRulerOpt(name, val string) string {
return val
}
// Deprecated: Will eventually be replaced by drawRulerFile
func (ui *ui) drawStat(nav *nav) {
if ui.msg != "" {
ui.msgWin.print(ui.screen, 0, 0, tcell.StyleDefault, ui.msg)
@@ -756,6 +758,7 @@ func (ui *ui) drawStat(nav *nav) {
ui.msgWin.print(ui.screen, 0, 0, tcell.StyleDefault, fileInfo.String())
}
// Deprecated: Will eventually be replaced by drawRulerFile
func (ui *ui) drawRuler(nav *nav) {
st := tcell.StyleDefault