Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

install jetbrains mono fonts #5

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions install-jetbrains-fonts
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# Original author: Michalis Georgiou <[email protected]>
# Modified by Andrew http://www.webupd8.org <[email protected]>
# Modified by Israel Perales https://www.ingenieroperales.com <[email protected]>

_wgeturl="$(curl -s https://api.github.com/repos/JetBrains/JetBrainsMono/releases/latest | grep tarball | cut -d '"' -f 4)"
_gf="jetbrainsmono"

# make sure a file with the same name doesn't already exist
rm -f $_gf.tar.gz

echo "Connecting to Github server..."
wget $_wgeturl -O $_gf.tar.gz

# Create fonts directory
mkdir -p ~/.local/share/fonts/

# Delete previus installation
rm -r ~/.local/share/fonts/jetbrainsmono/

echo "Extracting the downloaded archive..."
tar -xf $_gf.tar.gz -C ~/.local/share/fonts/

# move jetbrains directory
mv ~/.local/share/fonts/Jet* ~/.local/share/fonts/$_gf

echo "Updating the font cache"
fc-cache -f > /dev/null

# clean up, but only the .tar.gz, the user may need the folder
rm -f $_gf.tar.gz

echo "Done."