I have a number of files in a folder, and I want to replace every space character in all file names with underscores. How can I achieve this?
The easiest way to replace a string (space character in your case) with another string in Linux is using sed. You can do it as follows
Linux
sed
sed -i 's/\s/_/g' *
Hope this helps.