Skip to content

Instantly share code, notes, and snippets.

@bergpb
Last active October 25, 2024 19:12
Show Gist options
  • Select an option

  • Save bergpb/cf8d32ed7eead92d7e31c8668cdd326f to your computer and use it in GitHub Desktop.

Select an option

Save bergpb/cf8d32ed7eead92d7e31c8668cdd326f to your computer and use it in GitHub Desktop.

Revisions

  1. bergpb revised this gist Oct 25, 2024. 1 changed file with 7 additions and 3 deletions.
    10 changes: 7 additions & 3 deletions install_termux_tools.sh
    Original file line number Diff line number Diff line change
    @@ -4,7 +4,11 @@ GITHUB_URL=https://github.com
    NF_REPO=ryanoasis/nerd-fonts
    NF_VERSION=v3.2.1
    NF_NAME=FiraCode
    TMP_FONT_FOLDER=tmp_font_folder
    TMP_FONT_FOLDER=$HOME/tmp_font_folder

    echo "Make sure to keep closer to the device, a few manual steps may be necessary!!!"

    sleep 10

    # Initial repository configuration
    termux-change-repo
    @@ -23,8 +27,8 @@ wget $GITHUB_URL/$NF_REPO/releases/download/$NF_VERSION/$NF_NAME.zip \
    -O $TMP_FONT_FOLDER/$NF_NAME.zip

    unzip $TMP_FONT_FOLDER/$NF_NAME.zip -d temp_font_folder
    mv $TMP_FONT_FOLDER/FiraCodeNerdFont-Regular.ttf ~/.termux/font.ttf
    mv $TMP_FONT_FOLDER/FiraCodeNerdFont-Regular.ttf $HOME/.termux/font.ttf

    termux-reload-settings

    rm -rf temp_font_folder
    rm -rf $TMP_FONT_FOLDER
  2. bergpb created this gist Oct 25, 2024.
    30 changes: 30 additions & 0 deletions install_termux_tools.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,30 @@
    #!/bin/bash

    GITHUB_URL=https://github.com
    NF_REPO=ryanoasis/nerd-fonts
    NF_VERSION=v3.2.1
    NF_NAME=FiraCode
    TMP_FONT_FOLDER=tmp_font_folder

    # Initial repository configuration
    termux-change-repo
    dpkg --configure -a
    pkg upgrade

    # Install common packages
    pkg install wget\
    vim\
    openssh

    # Download FiraCode font and configure it
    mkdir $TMP_FONT_FOLDER

    wget $GITHUB_URL/$NF_REPO/releases/download/$NF_VERSION/$NF_NAME.zip \
    -O $TMP_FONT_FOLDER/$NF_NAME.zip

    unzip $TMP_FONT_FOLDER/$NF_NAME.zip -d temp_font_folder
    mv $TMP_FONT_FOLDER/FiraCodeNerdFont-Regular.ttf ~/.termux/font.ttf

    termux-reload-settings

    rm -rf temp_font_folder