Replace utils.Once with stdlib sync.OnceValue

This commit is contained in:
Kovid Goyal
2023-08-09 12:08:42 +05:30
parent 49ea26968c
commit 4f72bb9894
22 changed files with 53 additions and 96 deletions

View File

@@ -12,6 +12,7 @@ import (
"path/filepath"
"regexp"
"strings"
"sync"
"unicode"
"kitty/tools/cli"
@@ -22,7 +23,7 @@ import (
var _ = fmt.Print
var RgExe = utils.Once(func() string {
var RgExe = sync.OnceValue(func() string {
return utils.FindExe("rg")
})