all repos — searchix @ 29c4303590879d523c6bb04271389dda7f9cd24b

Search engine for NixOS, nix-darwin, home-manager and NUR users

refactor: split subcommand output lines more efficiently

Alan Pearce
commit

29c4303590879d523c6bb04271389dda7f9cd24b

parent

90f16010ba6c54f9e215ed48873686a428bcb746

1 file changed, 2 insertions(+), 2 deletions(-)

changed files
M internal/importer/main.gointernal/importer/main.go
@@ -81,8 +81,8 @@ files, err := fetcher.FetchIfNeeded(ctx, sourceMeta)
if err != nil { var exerr *exec.ExitError if errors.As(err, &exerr) { - lines := strings.Split(strings.TrimSpace(string(exerr.Stderr)), "\n") - for _, line := range lines { + lines := strings.SplitSeq(strings.TrimSpace(string(exerr.Stderr)), "\n") + for line := range lines { logger.Error( "importer fetch failed", "fetcher",