avoid quoting spaces in git-annex find output to terminal

That's too much quoting, the user expects the filename to be copy and
pasteable. It would be ok to slash-escape space ('\ ')
which is what gnu find does, but it doesn't seem necessary either.

${escaped_file} has always quoted spaces though, so keep on doing it
there.

Sponsored-by: Nicholas Golder-Manning on Patreon
This commit is contained in:
Joey Hess 2023-04-26 00:12:38 -04:00
parent 4358545a3e
commit 4d6c918eff
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
5 changed files with 6 additions and 6 deletions

View file

@ -105,7 +105,7 @@ showFormatted (IsTerminal isterminal) format unformatted vars =
case format of
Nothing -> do
liftIO $ S8.putStrLn $ if isterminal
then Utility.Format.escapedFormat unformatted
then Utility.Format.encode_c (const False) unformatted
else unformatted
Just formatter -> liftIO $ putStr $
Utility.Format.format formatter $