You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm wondering if we could add an option to preserve non-ascii characters as-is. Currently, the tool transforms them to HTML entities. For example é becomes é. I would rather have it stay as é.
I tried looking into the source code on how to implement this change but I am a bit lost. I looked at the functions about html entities but they are about decoding rather than encoding. I also tried bypassing the CGI.escapeHTML to no avail. Would you have a direction to point me in?
Thank you!
The text was updated successfully, but these errors were encountered:
I currently have a super hacky bash script to help me with this:
# scripts/html2haml.sh
ls $1| sed 'p;s/.erb$/.haml/'| xargs -n2 bundle exec html2haml --ruby19-attributes -E utf-8:utf-8
ls $1| sed 's/.erb$/.haml/'| xargs sed -i '''s/é/é/g'
ls $1| sed 's/.erb$/.haml/'| xargs sed -i '''s/è/è/g'
ls $1| sed 's/.erb$/.haml/'| xargs sed -i '''s/ /\ /g'
ls $1| sed 's/.erb$/.haml/'| xargs sed -i '''s/«/«/g'
ls $1| sed 's/.erb$/.haml/'| xargs sed -i '''s/»/»/g'
ls $1| sed 's/.erb$/.haml/'| xargs sed -i '''s/à/à/g'
ls $1| sed 's/.erb$/.haml/'| xargs sed -i '''s/’/ʼ/g'
ls $1| sed 's/.erb$/.haml/'| xargs sed -i '''s/fi/fi/g'
ls $1| sed 's/.erb$/.haml/'| xargs sed -i '''s/œ/œ/g'
ls $1| sed 's/.erb$/.haml/'| xargs sed -i '''s/î/î/g'
ls $1| sed 's/.erb$/.haml/'| xargs sed -i '''s/\À/À/g'
(please don't judge my absolute lack of shell scripting skills)
Hello! Thanks for a super convenient tool
I'm wondering if we could add an option to preserve non-ascii characters as-is. Currently, the tool transforms them to HTML entities. For example
é
becomesé
. I would rather have it stay asé
.I tried looking into the source code on how to implement this change but I am a bit lost. I looked at the functions about html entities but they are about decoding rather than encoding. I also tried bypassing the
CGI.escapeHTML
to no avail. Would you have a direction to point me in?Thank you!
The text was updated successfully, but these errors were encountered: