OMG Ubuntu 18.04 LTS wraps all my files up in single quotes!

created May 14, 2018, last updated May 14, 2018.


Don’t panic.

Coretutils 8.25+ adds single quotes to filenames containing spaces  when listed with ls

ls -al
-rw-r–r– 1 root root 0 May 14 11:41 ‘file with spaces’

When you first see this you may think “WTF has happened to my files” – stay frosty :

  • It was introduced in coreutils v8.25, and alignment improved in v8.26
  • It only happens when outputting to terminals so doesn’t break scripts
  • It disambiguates the output for users for files containing whitespace
  • It sanitizes output so it is safe to copy and paste
  • Output is now always valid to copy and paste back to shell
  • you can get back to the old format by adding -N to the ls alias or set export QUOTING_STYLE=literal in your .bashrc

And relax – all is well…

Taken from


  1. Ron says:

    This BS changes breaks 45+ years of Unix tradition, and the Principle of Least Surprise. “If a necessary feature has a high astonishment factor, it may be necessary to redesign the feature.”

This site uses Akismet to reduce spam. Learn how your comment data is processed.