Skip to content

Instantly share code, notes, and snippets.

@Johnnie88
Last active May 7, 2025 04:31
Show Gist options
  • Save Johnnie88/9988a9daf703e05b37314da143ec8c29 to your computer and use it in GitHub Desktop.
Save Johnnie88/9988a9daf703e05b37314da143ec8c29 to your computer and use it in GitHub Desktop.
Get and Install JetBrainsMono
#!/bin/bash
repo="https://github.com/ryanoasis/nerd-fonts/releases/download/v3.4.0/"
file="JetBrainsMono.zip"
font_name="JetBrainsMono"
sudo rm -rf $font_name
sudo rm -rf $file
echo "Get JetBrains Mono Fonts"
curl -fsSL ${repo}${file} -o ./$file
sudo apt-get install -y unzip
sudo chmod +x $file
mkdir $font_name
sudo unzip ./$file -d ./$font_name
sudo apt-get install -y tree
declare -a ttf_files=( $( tree ./$font_name | grep .ttf) )
echo "files to be copy:"
echo "${ttf_files[*]}"
files_full_path='$(pwd)"${}'
echo "copy fonts to the shared folder"
sudo cp -R $(pwd)/$font_name/* /usr/local/share/fonts
sudo cp -R $(pwd)/$font_name/* /usr/share/fonts
echo "Fonts installed successfully"
sleep 4
fc-cache -f -v
echo "Restarting the terminal"
exec bash
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment