Stop ls in Linux Debian Mint CentOS Ubuntu from applying quotes around filenames and directory names – rtt

Later versions of ls try to be helpful and smart to prevent errors in dealing with files with spaces that were tradtionally a pain.

However if you need the raw/real filenames, this can break scripts or if you are pasting into a csv etc….

How do you make ls not add the quotes?

Add the capital “-N” switch

ls -N

You could also add an alias to make it more permanent

Do this to add it to ~/.bashrc

alias ls="ls -N"

 

Tags:

ls, linux, debian, mint, centos, ubuntu, applying, quotes, filenames, directory, nameslater, versions, errors, spaces, tradtionally, scripts, pasting, csv, etc, quot, alias, bashrc,

Read more here: Source link