- https://stackoverflow.com/questions/4752353/how-do-i-encode-characters-into-numeric-character-reference-format-in-perl
- https://stackoverflow.com/a/4753600/3119172
$ echo 'foobar' | perl -pe "s/./ sprintf '&#x%04x;', ord($&) /ge"
$ echo 'foobar' | perl -pe "s/./ sprintf '&#x%04x;', ord($&) /ge"