El mié, 11 ene 2023 a las 0:04, Polarian (<polarian@xxxxxxxxxxxx>) escribió:
> Hello,
Hi!
> This [....]
> contact you.
After reading your comments I took a look around the AUR to really see how much people "obfuscate" their mailing address. What I found was varied, but I would venture to say that 90% of people put their email address as is, without obfuscation.
> Hello,
Hi!
> This [....]
> contact you.
After reading your comments I took a look around the AUR to really see how much people "obfuscate" their mailing address. What I found was varied, but I would venture to say that 90% of people put their email address as is, without obfuscation.
Whether or not to use this kind of obfuscation is a complicated issue, I personally consider that it is not worth much to avoid spam (nowadays), at least not using at and dot, but it is too deep in the collective mind to try to avoid it. I can also understand that there are people who feel safer using this method since it at least avoids the representation of the email as a clickable link in many viewers, which at least ensures that if someone wants to contact you they do not do it on impulse but something slightly more meditated.
In any case, seeing that this obfuscation thing is a problem for you, you can use this simple bash, zsh and derivatives snippet:
```
deofuscator () {
# Pick all arguments as one string
args="$@"
# Remove everything before <
mail="${args#*<}"
# Remove everything after >
mail="${mail%>*}"
# Pick all arguments as one string
args="$@"
# Remove everything before <
mail="${args#*<}"
# Remove everything after >
mail="${mail%>*}"
# Replacements
# (at) -> @
mail="${mail//(at)/@}"
# (dot) -> .
mail="${mail//(dot)/.}"
# at -> @
mail="${mail// at /@}"
# dot -> .
mail="${mail// dot /.}"
# Remove remaining spaces an echo mail
echo "${mail//[[:space:]]/}"
}
# (at) -> @
mail="${mail//(at)/@}"
# (dot) -> .
mail="${mail//(dot)/.}"
# at -> @
mail="${mail// at /@}"
# dot -> .
mail="${mail// dot /.}"
# Remove remaining spaces an echo mail
echo "${mail//[[:space:]]/}"
}
```
Just paste the code into any console or if you want it to work you can always put it in your .bashrc.
Just paste the code into any console or if you want it to work you can always put it in your .bashrc.
Using it is as easy as doing:
$ deofuscator "# Maintainer: Polarian <polarian at polarian dot dev>"
$ deofuscator $(head -1 PKGBUILD)
Greetings
--
Óscar García Amor | ogarcia at moire.org | http://ogarcia.me
Greetings
--
Óscar García Amor | ogarcia at moire.org | http://ogarcia.me