Created
May 19, 2023 22:50
-
-
Save nelsonaloysio/aeac243702a73b5d05b9b313d082ef96 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # Downloads and extracts Microsoft core fonts. | |
| # To make it available, move the output files to: | |
| # | |
| # User-wide: ~/.local/share/fonts [or] ~/.fonts | |
| # System-wide: /usr/share/fonts | |
| # | |
| # Requires `cabextract`. | |
| # | |
| # Original source: | |
| # https://discussion.fedoraproject.org/t/ms-core-fonts-on-silverblue/1916/5 | |
| mkdir -p mscorefonts | |
| cd mscorefonts | |
| url="http://downloads.sourceforge.net/corefonts" | |
| fonts=(\ | |
| andale | |
| arial | |
| arialb | |
| comic | |
| courie | |
| georgi | |
| impact | |
| times | |
| trebuc | |
| verdan | |
| webdin) | |
| for i in "${fonts[@]}"; do | |
| wget "${url}/${i}32.exe" | |
| cabextract "${i}32.exe" -d mscorefonts | |
| rm "${i}32.exe" | |
| break | |
| done | |
| mv mscorefonts/*{ttf,TTF} . | |
| rm -d mscorefonts/*{DLL,exe,EXE,inf,TXT} mscorefonts |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment