I tried other scripts I found on the internet (* the ones I found), but without success. So I want to know from some of you how to do this automated / recursive task.
Shell Script Retrieved from: link
set meta-flag on
set output-meta on
set convert-meta off
#!/bin/bash
NOMBRES_FICHEROS=$(ls)
for i in $NOMBRES_FICHEROS
do
echo '...TRATANDO EL FICHERO: '$i'...'
cat $i | tr [:upper:] [:lower:] > def_$i
cat $i | tr "ÁÉÍÓÚÑ" "AEIOUN" > def_$i
mv def_$i $i
done
No comments, it did not work! Maybe I do not have Mr. Bash as a CLI command interpreter.
Shell Script Retrieved from: link
#!/bin/bash
for file in *;
do
newname='echo "$file" | iconv -t 'ascii//TRANSLIT''
mv "$file" "$newname"
done
This other one I found also did not run on my system, I do not think I could even have the Bash interpreter, just Ash linked to Bash.
Shell Script Retrieved from: link
#!/bin/sh
for i in *
do
# ^ Quando esse chapeuzinho aparece no início de uma lista de caracteres significa negação;
j='echo "$i" | sed 's/[^A-Za-z0-9_.]//g''
# Vai remover todos os acentos das letras indicadas - https://www.vivaolinux.com.br/topico/Shell-Script/Script-para-retirar-acentos
j='echo "$j" | sed 'y/áÁàÀãÃâÂéÉêÊíÍóÓõÕôÔúÚçÇ/aAaAaAaAeEeEiIoOoOoOuUcC/''
mv "$i" "$j"
echo "Acento(s) removido de: $i"
done
This has already worked in parts, I say this, because the change makes a bit weird change, change until characters without accent also [where it does not have].
These were the ones I found.