/*
goredo -- djb's redo implementation on pure Go
-Copyright (C) 2020-2023 Sergey Matveev <stargrave@stargrave.org>
+Copyright (C) 2020-2024 Sergey Matveev <stargrave@stargrave.org>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
"bufio"
"bytes"
"encoding/hex"
+ "errors"
"flag"
"fmt"
"io"
+ "io/fs"
"log"
"os"
"os/signal"
LogLock = os.Getenv(EnvLogLock) == "1"
LogJS = os.Getenv(EnvLogJS) == "1"
if Debug || os.Getenv(EnvLogPid) == "1" {
- MyPid = os.Getpid()
+ MyPID = os.Getpid()
}
var traced bool
if flagTraceAll != nil && *flagTraceAll {
var dos []string
dos, err = whichdo(tgts[0])
if err != nil {
- break
+ if errors.Is(err, fs.ErrNotExist) {
+ err = nil
+ ok = false
+ } else {
+ break
+ }
}
- sort.Strings(dos)
for _, do := range dos {
fmt.Println(do)
}