Open NicoWeio opened 2 years ago
The problem is that failure to chdir into a directory isn't generally a fatal error. It can happen at any time during program execution such as during filesystem traversal any number of directories deep (via --recurse) or after having successfully processed the first n directories listed as command line arguments but failing on argument n+1.
Given all this I choose to treat failure to chdir as a warning instead of an error.
I agree, that's understandable. Nonetheless, one might consider…
A command like
fdupes x y
printsto stderr if the directories x and y do not exist, but the process has the exit code 0, despite obviously failing. This caused me quite a headache today, because it just assumed that fdupes would give another exit code in such a case.
I don't see anything about exit codes in this GitHub repo nor the man page, so I assume that there are none at the moment. How exactly the error codes should be defined is a question I'm not qualified to answer, but I sure hope they will be added in the future. Thank you!