-
-
Save elijahmanor/c10e5787bf9ac6b8c276e47e6745826c to your computer and use it in GitHub Desktop.
#/bin/bash | |
echo "Normal" | |
echo "\033[1mBold\033[22m" | |
echo "\033[3mItalic\033[23m" | |
echo "\033[3;1mBold Italic\033[0m" | |
echo "\033[4mUnderline\033[24m" | |
echo "== === !== >= <= =>" | |
echo "契 勒 鈴 " |
I had some missing fonts and used nerdfix to find alternatives.
Here is the revised script, with corrected UTF codes. It is based on @msmafra's revised version of smoke-test.sh
#!/usr/bin/env bash
smoke_tests="Normal
\033[1mBold\033[22m
\033[3mItalic\033[23m
\033[3;1mBold Italic\033[0m
\033[4mUnderline\033[24m
== === !== >= <= =>
"
printf "%b" "${smoke_tests}"
zsh
indicates that there's a \n
missing at the end of the printed output.
The bang is missing in #!
Some of the icon codepoints have since changed on nerdfonts (March 2024), here's the updated string:
" "
Some of the icon codepoints have since changed on nerdfonts (March 2024), here's the updated string:
" "
Thanks
#!/usr/bin/env bash
smoke_tests="Normal
\033[1mBold\033[22m
\033[3mItalic\033[23m
\033[3;1mBold Italic\033[0m
\033[4mUnderline\033[24m
== === !== >= <= =>
Nerdfont
Fontawesome Free
"
printf "%b" "${smoke_tests}"
hi @msmafra
Thanks for the fix you gave for smoke-test.sh
i was also testing the test-fonts.sh script at
https://github.com/ryanoasis/nerd-fonts/blob/master/bin/scripts/test-fonts.sh
When i ran it, its does not show any icons and shows hex codes for all symbols
Not even a single symbol is getting rendered
I am using the JetBrainsMono Nerd Font in ITerm
See the screenshot
Also, for me, the "-e" was a requirement. So I decide to replace echo with printf since it is more portable and added the usually said as best practices crash bang.
Edit
A better one, printf "%b" can be replaced with echo -e, if desired: